neutron-gamma detection technology is widely used in nuclear physics, high-energy physics, radiation medicine, and other fields. A NaIL scintillator coupled with a silicon photomultiplier (SiPM) can form a neutron-gamma detector with excellent discrimination, small size, and low cost. However, the performances of a NaIL scintillator and SiPM are affected by temperature, which leads to a shift in energy spectrum and deterioration in neutron-gamma discrimination. Most of the current studies have used digitizers to store data and analyze detector energy spectrum and waveform characteristics offline to eliminate temperature dependence. In this study, a small neutron-gamma detector was constructed using NaIL scintillators, SiPM, and circuits developed in the laboratory. Online calibration of the ARM processor eliminates the temperature dependence of the detector's energy spectrum and neutron-gamma discrimination. Automatic energy spectrum stabilization and good neutron-gamma discrimination were achieved in a wide temperature range. The test results show that the peak shift of the 137Cs 662 keV full-energy peak of the detector is reduced from 5.3% to 0.4% at 0–50°C. After the online correction of the temperature feedback PSD parameters, the figure of merit at 45°C is 40% higher than that before the correction, and the detector's figure of merit at 0–50°C is maintained above 3.4.