The China Seismo-Electromagnetic Satellite (CSES) space mission-also known as Limadou in Italian-is a scientific collaboration between China and Italy that aims to investigate the structure and dynamics of the iono/magnetosphere, and in particular to study the possible correlation of perturbations to the occurrence of high-magnitude seismic events. The Chinese satellite houses the Italian high-energy particle detector (HEPD), an apparatus composed of a silicon tracker and a calorimeter system, which detects electrons and protons in the energy ranges 3-100 and 30-200 MeV, respectively. The satellite was launched on February 2, 2018; after a commissioning phase dedicated to the setting of an optimal configuration, HEPD is fully operational since July 28, 2018. After a general overview of the CSES-Limadou mission, this article presents the structure of the HEPD apparatus and describes the design and implementation of the software for the embedded computer system that is responsible for HEPD management. The onboard software runs on the digital signal processors of two electronic boards (CPU and data acquisition), monitors system status, handles instrument data acquisition, performs periodic calibration of the subdetectors, performs