Page 1 of 1

Coprocessor0Disabled (rsr.exccause = 32) thrown when executing "lsi f0,a1,96" leading to errors in esp-cryptoauthlib

Posted: Wed Nov 09, 2022 9:21 pm
by QlifeDeveloper
Using a JTAG debugger I observe that a UserException is thrown when I try to single step over the "lsi f0,a1,96" instruction.
The rsr.exccause reports 32, equal to Coprocessor0Disabled exception.

The symptom in the system is that after haing executed the code comprising the "lsi f0,a1,96" instruction any communication using HTTPS endpoints will at some point fail with following error message:
"./components/esp-cryptoauthlib/cryptoauthlib/lib/calib/calib_execution.c:379:f0:atreceive - failed"

Does anybody know what I need to do in order to use floating point on the ESP32?
Thanks in advance!

Re: Coprocessor0Disabled (rsr.exccause = 32) thrown when executing "lsi f0,a1,96" leading to errors in esp-cryptoauthlib

Posted: Fri Nov 11, 2022 3:48 am
by ESP_Sprite
That is likely normal: rather than context-switching out the FPU registers on each task swap, freeRTOS disables the coprocessor. It then uses the Coprocessor0Disabled exception to notice another (or the same) task uses the FPU, and swaps in the FPU registers and re-enables it. I don't think that exception has anything to do with the issue you're trying to debug.