Hello!
I'm taking some performance metrics for encrypting data on my nRF52840 device and I was wondering if you might be able to help me. The goal is to see how long and how much power it takes to encrypt 2048 bytes of data via AES CBC 256 using the mbed TLS backend. While observing my device, I've also been using a development board and the provided AES example from Nordic as a reference (by using a 2048 char message instead of 64 chars). I was successfully able to time how long it takes with a 128-bit key and a 256-bit key:
Example | 128-bit key | ~3.0ms |
Example | 256-biit key | ~4.67ms |
My device | 128-bit key | ~7.5ms |
My device | 128-bit key | ~8.7ms |
Could you confirm my observations for the Nordic example are close to what's expected?
Then, I moved on to power profiling my device to see how the average current would change. As a baseline measurement, my device consumes ~500uA. Then I enabled encryption with a 128-bit key and saw current jumped up to ~980uA. I would expect the current to rise even more when I enable encryption with a 256-bit key, but I'm still seeing roughly the same average current as before! Am I doing something wrong or is it expected for current to be about the same in this context?
I'm using nrf5 SDK version 16.0.0