The LWD-NMR instruments are limited by the telemetry bandwidth and logging timing requirements, so the echo T2 spectrum inversion function must be implemented at downhole logging instruments. Firstly, the inversion problem of T2 spectrum is converted to a non-negative least squares problem and solved by the accelerated projective gradient descent (APGD) algorithm. Secondly, the distributed structure is used in FPGA design to shorten the time for the APGD algorithm. Finally, a software cooling method based on a multi-core structure and periodic thermal management technology is deployed. Therefore, the inversion algorithm of echo T2 spectrum deployed on FPGA not only meets the requirements of real-time inversion calculation but also reduces the temperature effectively by means of software cooling. It provides a useful reference for the research of the downhole data processing technology of LWD.