m5stack / Core2-for-AWS-IoT-Kit

Accompanying code for use with AWS IoT Kit content. Works with PlatformIO and ESP-IDF v4.2.
https://m5stack.com/collections/m5-core/products/m5stack-core2-esp32-iot-development-kit-for-aws-iot-edukit
MIT License
127 stars 66 forks source link

aws_iot: failed! could not load cert from ATECC608 #50

Closed synapticscrd closed 3 years ago

synapticscrd commented 3 years ago

Hi there,

Having some weird issue's and hope you can help ... sometimes my Core2 is registering and I am getting the tutorials completed, but I keep getting this type of error BELOW. Honestly this worked a couple of days ago, I moved onto the next tutorial and had issues so started again, I also seem to have issues erasing the flash, I am running from a Oracle VM running Ubuntu, wondered if this may cause me problems? the only other thing I can think is my WiFi has problems for some reason.

BTW the certificate is in the IoT core, is active, the client is registered and has a policy, tried clearing these two

␛[0;32mI (4735) Blinky: Connecting to AWS IoT Core...␛[0m ␛[0;31mE (4785) aws_iot: failed! could not load cert from ATECC608, tng_get_device_cert_def returned e1␛[0m ␛[0;31mE (4785) aws_iot: failed! mbedtls_x509_crt_parse returned -0xffffff1f while parsing device cert␛[0m ␛[0;31mE (4795) Blinky: Error(-20) connecting to xxx-ats.iot.eu-west-1.amazonaws.com:8883␛[0m ␛[0;32mI (5925) aws_iot: Attempting to use device certificate from ATECC608␛[0m

rashedtalukder commented 3 years ago

Hi @synapticscrd,

Since this looks more like a support discussion and not a code bug or feature request, I've copied your question to: https://github.com/aws-samples/aws-iot-edukit-tutorials/discussions/25

Please try some of the suggestions there and let me know if they work for you.