I want to run some algorithm and generate data from that algorithm and transmit that data to another raspberry pi. In this process, i want to calculate energy. Like, how much energy did that pi consumed from processing the algorithm to transmit the data.
Is there any mathematical equation or software techniques or hardware techniques which can help me to calculate consumed energy by raspberry pi?
Thanks in advance.