🤖Have you ever tried Chat.M5Stack.com before asking??😎

Subcategories

  • 53 Topics
    243 Posts
    greenleafG
    TL;DR: The factory certificate in slot 10 is in a compressed format that AWS IoT rejects. You need to generate a new properly-formatted certificate. Full working example here: https://github.com/scarolan/grafana-core2aws-iot The Problem Everyone Hits If you've tried to use the Core2 for AWS with its built-in ATECC608 secure element, you've probably hit this error when registering the certificate: CertificateValidationException: The certificate could not be parsed You're not crazy. The factory certificate in slot 10 is stored in Microchip's compressed format with: Empty issuer/subject fields Invalid dates (Aug 28, 2005) Missing X.509 structure AWS IoT's register-certificate-without-ca API rejects it outright. The Solution Generate a new properly-formatted certificate that still uses the locked private key in slot 0 (so you maintain hardware security): 1. Clone the Working Example git clone https://github.com/scarolan/grafana-core2aws-iot cd grafana-core2aws-iot/extras/generate_cert 2. Flash the Certificate Generator pio run -t upload --upload-port COM3 pio device monitor --port COM3 --baud 115200 3. Save the Certificate Copy the certificate output (including -----BEGIN CERTIFICATE----- lines) to a file. 4. Register with AWS IoT aws iot register-certificate-without-ca \ --certificate-pem file://device_new.pem \ --status ACTIVE \ --region us-east-1 Then attach your policy and thing as usual. 5. Use in Your Firmware Update secrets.h with the new certificate and you're done! Why This Works The certificate generator: Reads the public key from slot 0 (the private key never leaves the chip) Creates a proper X.509 certificate with valid dates and subject fields Signs it using the locked private key (signing happens inside the ATECC608) Returns a properly-formatted certificate AWS IoT accepts Hardware security is maintained - the private key in slot 0 is never exposed, it's just used differently. Complete Documentation I've documented the full solution with explanations of what's happening: ATECC608 Architecture - How the secure element works, slot configuration, lock mechanism Certificate Solution - Why the factory cert fails and how to fix it Full Working Example - Complete vibration monitoring IoT demo with AWS IoT Core + Timestream Why M5Stack Doesn't Document This The compressed certificate format is a Microchip design decision (saves space on the chip). It's meant to work with: Microchip's Trust Platform provisioning tools Their specific certificate reconstruction libraries Microchip-managed certificate authorities It was never designed to work directly with third-party services like AWS IoT without special handling. M5Stack provides a complex registration helper (registration_helper.py) that reconstructs the certificate with special manifest-based APIs, but it's 800+ lines of Python with tons of dependencies. The approach above is much simpler - just generate a new cert and register it normally. Tested and Working This solution is running in production on my demo device: MQTTS publishing to AWS IoT Core every 5 seconds Data flowing to Amazon Timestream Hardware-backed authentication with ATECC608 Zero issues with certificate validation Hope This Saves Someone's Week I fought with this for a week a couple years ago and gave up in frustration. Revisited it recently and finally cracked it. Hopefully this saves others the same pain! Questions/issues? Comment here or open an issue on GitHub. Repository: https://github.com/scarolan/grafana-core2aws-iot Hardware: M5Stack Core2 for AWS Libraries: ArduinoECCX08, ArduinoBearSSL, M5Unified Tested: PlatformIO, Arduino framework on ESP32
  • 89 Topics
    337 Posts
    ShawnHymelS
    @felmue That helps a lot, thank you!
  • 65 Topics
    228 Posts
    H
    Has anyone installed firmware and upon starting gets stuck in a menu selection loop where the highlight selection continues to scroll?
  • M5Stack's little brother. Discuss M5 Stick hardware and software related issues here

    403 Topics
    2k Posts
    M
    Does anyone's built-in IR receiver work?
  • 18 Topics
    71 Posts
    P
    I just got the M5GO Kit, and I'm trying to make a Voice Assistant. For some reasons, the Demo of the kit made me think that accessing the microphone is easy. But, after hours of finding, it seems that there is no library or support for the kit to record audio. Does anyone have any resource regarding this?
  • 27 Topics
    114 Posts
    M
    Problem: Der Schrittmotor funktioniert nur korrekt in der Z-Achse bei normalen (langsamen) Drehgeschwindigkeiten. Beim Versuch, die X- und Y-Achsen zu verwenden, funktioniert der Motor nur, wenn ich die Vorschubgeschwindigkeiten auf das 10-fache oder höher erhöhe. Wenn ich versuche, die Adresse auf 0x71 zu ändern, wird das Modul nicht erkannt.
  • 50 Topics
    133 Posts
    Y
    @samantha_martin Hola Samantha. El M5StickC Plus (SKU:K016-P) utiliza el chip ESP32-PICO-D4, que integra Bluetooth LE. Para reducir la latencia en la transmisión HID, puedes probar las siguientes acciones: Optimizar la frecuencia de envío de datos: En las librerías ESP32-BLE-Keyboard o BleGamepad, ajusta el intervalo de notificación BLE a un valor más bajo (por ejemplo, 10-20 ms). Algunas librerías permiten configurar esto al inicializar el dispositivo HID. Minimizar el código en el loop(): Asegúrate de que no haya delays innecesarios ni tareas bloqueantes (como impresiones Serial) que ralenticen la detección de botones y el envío de comandos. Configurar el modo BLE de bajo consumo: Aunque el ESP32-PICO-D4 es eficiente, verifica que no se encuentre en modos de suspensión prolongada. Asegúrate de que el dispositivo BLE esté configurado para enviar notificaciones inmediatamente al detectar una pulsación. Actualizar el firmware del ESP32: Usa la última versión del core ESP32 en Arduino IDE, ya que a menudo incluyen optimizaciones en el stack BLE. Verificar la configuración de Android: En el menú de configuración de Bluetooth de tu teléfono, desactiva opciones como "Ahorro de batería" para el dispositivo M5StickC Plus, ya que pueden restringir la frecuencia de actualizaciones HID. https://chat.m5stack.com/
  • For Topics related to the Core 2

    335 Topics
    1k Posts
    easytargetE
    @skyflyer said in External 1S LIPO on M5Core2 BUS PIN1 and PIN30?: I tried to find information about it, and want to confirm that it is OK to connect the external Lipo battery to pins 1 and 30 on the "BUS expansion port"? And that the battery will be charged when connected to the external USB power? If you look at the schematic you will see that pin30 on the bus and VBAT (on the lipo connector) are the same. So yes, you can replace the internal battery with an external one with the same voltage! @skyflyer said in External 1S LIPO on M5Core2 BUS PIN1 and PIN30?: And I don't need to remove the internal 500mAh battery, since they would be connected in parallel anyhow? Do not simply put rechargeable batteries in parallel. Disconnect the internal one. You can have batteries in parallel but.. at a minimum you need some diodes to prevent them back-charging each other, have a look online where there is a lot of info about this.
  • M5Dial: Factory Demo

    7
    0 Votes
    7 Posts
    8k Views
    S
    Hello @jsgagnon, after I got the info from @ajb2k3 and @felmue I am happy and I used the link. Thank you for asking.
  • Programming CoreInk with UiFlow

    5
    0 Votes
    5 Posts
    4k Views
    W
    @ajb2k3 thanks vor the tip, i just skiing und will try is next week! Thanks!!!
  • my ESP32 PSRAM Timer Camera not working.

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • M5Dial: terrible user experience for beginner to get started

    4
    1
    0 Votes
    4 Posts
    4k Views
    robskiR
    Just received my M5Dial few days ago...late christmas gift to myself... there are 2 easyloader projects available, also if you look in to arduino examples (with latest M5 board manager) there are few built in simple projects too, I've used uiflow2 burner to load firmware which went in it no problem, then loaded some arduino examples ok, then suddenly uiflow2 lost ability to connect, m5burnerv3 couldn't connect too, finally managed to use uiflow2 burner again with back button press to load latest firmware alpha29, bizarre as previous uiflow2 burner loading alpha28 didn't required back button press at all. M5Dial makes very interesting device. Journey started. Check X (twitter) for #M5dial tweets - there is one example showing space station tracker and some doing earth rotations/moon phases...earth rotation one looks like its 3d display...
  • M5paper USB mode

    4
    0 Votes
    4 Posts
    4k Views
    ajb2k3A
    @alwa123 Yes, you use M5Burner to Upload the latest UIFlow Firmware to the M5Paper, Open Thonny, set the port to the M5Paper, Se mode to Micropython generic and then connect. Once connected you will need to hit CTRL+C or another combination that will be show in the shell to interrupt the running program and get access to the REPL command.
  • CoreS3 with 7 external buttons

    9
    0 Votes
    9 Posts
    7k Views
    Z
    I'll look into it as that's something I'd like to do, thanks!
  • CoreS3 microphones examples

    1
    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • M5Dial.h and Arduino Serial monitor

    2
    0 Votes
    2 Posts
    2k Views
    C
    my solution USB CDC on Boot must be Enabled
  • M5 CoreInk FactoryTest : how this example is supposed to work

    2
    0 Votes
    2 Posts
    2k Views
    felmueF
    Hello @laflaf3d I could be wrong, but I think that part of the code is meant to test the Groove port. So I must assume that in the M5Stack factory something with I2C address 0x76 is connected to the Groove port during testing. Your options are to either ignore that part of the code - it should run even with nothing connected to the Groove port or connect any I2C sensor and modify the code to match its I2C address etc. Thanks Felix
  • Cardputer & Sensors

    5
    0 Votes
    5 Posts
    6k Views
    B
    Thanks for the replies everyone.
  • M5Paper touchscreen wakeup on GPIO 36 constantly triggering

    3
    2
    0 Votes
    3 Posts
    3k Views
    S
    Thanks, both, for these posts. I was able to resolve my issue with deep sleep by following your suggestions. I have created an issue in the M5 Unified issue tracker to solve this same bug in their M5.Power.deepSleep() implementation: https://github.com/m5stack/M5Unified/issues/91
  • Core S3 with ENV3 sensor bug?

    10
    0 Votes
    10 Posts
    9k Views
    felmueF
    Hello @stefan-h I've tried the similar code as above with an M5CoreS3 and ENV III unit as well and it worked fine for me. I suggest you try the latest available UIFlow2 firmware version which is UIFlow2.0.0. alpah-28 at the time of this post. Thanks Felix
  • Sleep / low power on Paper V1.1 without clearing the display on Wake?

    core
    8
    0 Votes
    8 Posts
    8k Views
    S
    @ajb2k3 thanks so much for that insight. Do you have an implementation of HV write mode for the Paper display in a different platform (UIflow etc)? Don't worry if not, because it seems that existing shutdown() is able to retain images according to @felmue's example.
  • M5Paper text

    23
    0 Votes
    23 Posts
    74k Views
    ScheduleDisplayS
    Hello, I Got the GFX font header file (by converting the Roboto.ttf file). Loaded the font file using canvas.setFreeFont(&Roboto_Medium50pt7b) and then display the text using canvas.printf(textString.c_str());. It is working fine and display the text properly but when I am giving some special characters äöü then they are not appearing on M5stack paper. Can someone please guide me what I am doing wrong? Am I missing something? Thanks The link to my question can be found here
  • How to install M5Burner

    2
    0 Votes
    2 Posts
    2k Views
    ajb2k3A
    @ivka on what?
  • CoreInk screen driver specs

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • This topic is deleted!

    1
    0 Votes
    1 Posts
    2 Views
    No one has replied
  • M5Paper EPD power consumption

    54
    1 Votes
    54 Posts
    257k Views
    L
    The E-Ink Paper Display (EPD) on the M5Paper consumes power even when the screen is idle due to its underlying technology. E-Ink displays are different from traditional LCD or OLED screens in that they only consume power when the content on the screen is changed. Once an image or text is displayed on an E-Ink screen, it doesn't require any power to maintain that state. However, changing the content on the screen, such as refreshing to display a new image or text, does consume power. In your case, when the EPD power is disabled, the display is essentially turned off, and it consumes very little to no power because it's not actively refreshing the content. When you enable the EPD power and the display is idle, it's likely in a state where it's ready to receive new content and is therefore consuming some power in anticipation of a refresh. The power consumption you're observing is not necessarily a sign of a defective unit but rather a characteristic of E-Ink displays. If you want to optimize power consumption further for your low-power application, you might consider: Reducing Refresh Rate: Minimize the frequency of screen refreshes. E-Ink displays are typically used in applications where the content doesn't change frequently. You can adjust the refresh rate to be as infrequent as possible to save power. Full Screen Updates: Instead of partial screen updates, use full screen updates when you need to change the content. Partial updates can be more power-intensive. Deep Sleep: Continue using the deep sleep mode of the ESP32 when the screen is idle. This will significantly reduce overall power consumption. Optimize Code: Make sure your code is efficiently managing the display and other peripherals. Ensure that you are properly putting the ESP32 into deep sleep mode when it's not actively needed. Hardware Modifications: Depending on your specific use case, you might consider hardware modifications to further reduce power consumption. This could involve custom power management circuitry or using different power supplies.
  • 0 Votes
    2 Posts
    3k Views
    G
    Hi @arzaman, Sorry to answer with a question, but I just want to check I've understood. You want to accommodate the 5V supply into this sensor and associated 5V? logic output from it down to the 3V3 input of StickC, Core2, etc? A couple of thoughts: #1 StickC has a 3V pin out on the end opposite Groove port, so I guess you could go from the head end of the StickC to sensor (reduce all to 3V3). #2 Copy the voltage divider circuit a lot of the M5Stack sensors use (they are quite cheap, so you could even use one as a donor and solder your sensor on to it). https://docs.m5stack.com/en/unit/dual_button #3 I've a feeling Seeed, DFRobot, Waveshare do a mini board to do such a thing, but probably equivalent to donor M5Stack part. If you used the M5Stack Mini Dual Button Unit as a donor/connection board. I suppose you could have two inputs, pin 32 and pin 33, hide the pull up resistors, etc. Or the Proto units, perhaps an easier solder at home proposition. Q) If it "can be powered from data line. Power supply range is 3.0V to 5.5V", would 5V power issue go away anyway? https://shop.pimoroni.com/products/temperature-probe-ds18b20-arduino-compatible-adapter?variant=39365415829587 (NB Alt schemtic for circuit)
  • CoreInk Multifunction Button not working

    1
    1
    0 Votes
    1 Posts
    2k Views
    No one has replied