Are the traces resulting from the capturing considered power traces or voltage? I want to calculate the energy consumption. What I did was I treated the traces as voltage traces^2 divided it by 0.22(shunt resistance I assumed) then I got the area under the graph. Is that correct? I am using UFO Board and CWLITE Standalone.
The calibration that one would do with say an oscilloscope.
In side-channel attacks we only really care about relative differences in measurements; we don’t care about absolute measurements. That’s why CW isn’t meant to be used that way.
Very roughly yes/maybe, but not really. Google “AC coupling vs DC coupling” to learn more. ChipWhisperer’s measurements are best considered dimensionless.
If you want to measure power/current/power properly, then there are tools for this purpose, for example https://www.joulescope.com/ (no affiliation).
When analyzing power traces using AC coupling, can I compare the energy calculated for different codes to determine which one consumes more power? Additionally, can I consider traces with the highest values as the areas of the code that consume the most power?
To a certain degree yes. Just be aware that ChipWhisperer does not measure the actual absolute power consumption. But you can certainly use it to see the effect of different opcodes and operands, as this blog post does: side channels: power analysis | Gianluca Pacchiella