1. 16 Aug, 2024 3 commits
    • Alessandro Gatti's avatar
      esp32/mphalport: Print debug strings even before the GIL is ready. · 0b75e180
      Alessandro Gatti authored
      If verbose debugging is enabled there is some stdout output happening
      before the GIL is ready (for example, GC initialisation), and the code
      assumed that no string printing occurred before the interpreter was fully
      initialised.  Printing long strings would operate without holding the GIL,
      which would crash if string output would happen too early in the startup
      process.
      
      This commit addresses that issue, making sure verbose debugging output will
      work even before the interpreter is fully initialised (as if it is not yet
      ready there's no GIL to take care of).
      
      Also, the threshold that would indicate whether a string is "long" (and
      thus requiring a GIL release/lock operation) or not was hardcoded to 20
      bytes.  This commit makes that configurable, maintaining 20 bytes as a
      default.
      
      Fixes issue #15408.
      Signed-off-by: default avatarAlessandro Gatti <a.gatti@frob.it>
      0b75e180
    • Matt Trentini's avatar
      esp32/boards: Remove BLE from list of features for ESP32-S2. · 09207885
      Matt Trentini authored
      Fixes issue #15618.
      Signed-off-by: default avatarMatt Trentini <matt.trentini@gmail.com>
      09207885
    • Angus Gratton's avatar
      esp32: Restore ESP32-C3 brownout detector settings to IDF defaults. · e71a324c
      Angus Gratton authored
      Commit a66bd7a4 added the
      ESP32_GENERIC_C3_USB board (now merged with ESP32_GENERIC_C3) and changed
      the brownout detector from the default level 7 (~2.51V) to level 4
      (~2.92V).
      
      Raising the level again seems to fix random BOD resets on some of the
      cheaper ESP32-C3 dev boards (that likely skimp on power supply
      capacitance).
      
      Specifically, this change prevents random resets running multi_bluetooth
      tests on ESP32-C3 "SuperMini" board.
      
      Also removed from the LOLIN_C3_MINI board as it seems this config is a copy
      of the generic one.
      
      This work was funded through GitHub Sponsors.
      Signed-off-by: default avatarAngus Gratton <angus@redyak.com.au>
      e71a324c
  2. 14 Aug, 2024 14 commits
  3. 13 Aug, 2024 2 commits
  4. 12 Aug, 2024 2 commits
  5. 08 Aug, 2024 8 commits
  6. 07 Aug, 2024 10 commits
  7. 02 Aug, 2024 1 commit
    • Phil Howard's avatar
      rp2/rp2_pio: Make PIO IRQ handlers have lazy initialisation. · ad3552ae
      Phil Howard authored
      This change has no impact on vanilla MicroPython builds, but is intended to
      avoid RP2's PIO implementation from trampling PIO usage in USER_C_MODULES.
      
      This is consistent with PIOs tracking of used state machines and managed
      programs, and makes working with PIO in USER_C_MODULES much less of an
      uphill battle.
      
      Since PIO deinit runs before gc_sweep_all it's impossible to work around
      this wrinkle otherwise.  A module finalizer does not get the opportunity to
      put the PIOs back into a state which wont crash rp2_pio_deinit.
      
      Changes are:
      - init: Avoid exclusive handlers being added to all PIOs and add them only
        when needed.
      - deinit: Only remove handlers we have set.
      - rp2_pio_irq: Add the exlusive handler if needed.
      - rp2_state_machine_irq: Add the exclusive handler if needed.
      Signed-off-by: default avatarPhil Howard <phil@gadgetoid.com>
      ad3552ae