I found the problem.
The bootloader in this 328P does not support 115200 bps for programming.
This is the correct command for the bootloader I have:
avrdude -v -c arduino -p ATMEGA328P -P /dev/ttyAMA0 -b 57600 -U flash:w:/root/FirmWares/MyEmonPi_NewBoard_2022.ino.eightanaloginputs.hex
Later I will try to update the bootloader to the newer version, but it seems that I have to use the ICSP pins with an external programmer (e.g. a nano) to do that.
Cheers.