Commit Graph

7325 Commits

Author SHA1 Message Date
Ibrahim Abdelkader
3946a19cd2
Merge pull request #2840 from openmv/stm32n6_sleep_enable
stm32: Disable clock gating during sleep for STM32N6 peripherals
2025-09-16 19:30:20 +03:00
iabdalkader
01113ebee9 stm32: Disable clock gating during sleep for STM32N6 peripherals
Remove individual peripheral sleep clock enable/disable calls and instead
enable all AHB/APB peripheral clocks during sleep mode. This is needed
because MicroPython doesn't manage peripheral sleep clocks individually.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-16 18:20:38 +02:00
Ibrahim Abdelkader
28f0ad2d7d
Merge pull request #2832 from openmv/dependabot/github_actions/softprops/action-gh-release-2.3.3
build(deps): bump softprops/action-gh-release from 2.2.2 to 2.3.3
2025-09-16 18:23:40 +03:00
Ibrahim Abdelkader
e60750b5cc
Merge pull request #2838 from openmv/revert_lock_fix
Some checks failed
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Has been cancelled
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / code-size-report (push) Has been cancelled
🔥 Firmware Build / stable-release (push) Has been cancelled
🔥 Firmware Build / development-release (push) Has been cancelled
Revert "common/mutex: Clear tid when releasing mutex"
2025-09-13 12:22:27 +03:00
iabdalkader
1b59e95162 Revert "common/mutex: Clear tid when releasing mutex"
This reverts commit bb52288561.

Event though this fixes a deadlock in the new protocol, it
actually breaks fair locking as one side could lock multiple
times in a row.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-13 10:52:00 +02:00
Ibrahim Abdelkader
085f282e4b
Merge pull request #2837 from openmv/fix_jlink_output
Some checks are pending
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Waiting to run
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / code-size-report (push) Blocked by required conditions
🔥 Firmware Build / stable-release (push) Blocked by required conditions
🔥 Firmware Build / development-release (push) Blocked by required conditions
Makefile: Suppress J-Link GDB server output
2025-09-12 19:16:46 +03:00
Ibrahim Abdelkader
ce4922c1bc
Merge pull request #2836 from openmv/fix_mutex_tid
common/mutex: Clear tid when releasing mutex
2025-09-12 19:16:38 +03:00
iabdalkader
bcb20f45ac Makefile: Suppress J-Link GDB server output
Redirect J-Link GDB server stdout and stderr to /dev/null to prevent
its output from mixing with GDB output in the terminal.
2025-09-12 18:06:40 +02:00
iabdalkader
bb52288561 common/mutex: Clear tid when releasing mutex
Clear the thread ID to 0 when unlocking the mutex to prevent deadlock.
If the thread holding never reacquire it, other threads would be
permanently blocked with a stale thread ID.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-12 18:00:32 +02:00
Ibrahim Abdelkader
4f40ae487e
Merge pull request #2835 from kwagyeman/kwabena/genx320_pag7936
Some checks are pending
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Waiting to run
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / code-size-report (push) Blocked by required conditions
🔥 Firmware Build / stable-release (push) Blocked by required conditions
🔥 Firmware Build / development-release (push) Blocked by required conditions
drivers/sensors: Add aux flag to genx320 driver.
2025-09-12 11:14:47 +03:00
Kwabena W. Agyeman
050d750afd drivers/sensors: Add aux flag to genx320 driver. 2025-09-11 19:54:19 -07:00
Ibrahim Abdelkader
9937b9cc1e
Merge pull request #2834 from openmv/makefile-debug-improvements
Some checks are pending
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Waiting to run
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / code-size-report (push) Blocked by required conditions
🔥 Firmware Build / stable-release (push) Blocked by required conditions
🔥 Firmware Build / development-release (push) Blocked by required conditions
Makefile: Integrate GDB debugging into jlink target
2025-09-12 00:13:42 +03:00
Ibrahim Abdelkader
8b19717c21
Merge pull request #2821 from openmv/add_crc_hal
common: Add CRC HAL with hardware acceleration support.
2025-09-12 00:13:13 +03:00
iabdalkader
a4ce426308 Makefile: Integrate GDB debugging into jlink target
Combines JLink server startup and GDB launch into a single command.
Uses setsid to isolate JLink server from terminal signals, allowing
Ctrl+C to work normally in GDB without terminating the debug server.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 23:08:14 +02:00
iabdalkader
616ce71b96 ports/stm32: Implement hardware accelerated CRC.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 22:08:58 +02:00
iabdalkader
1dd9b33acc ports/alif: Implement hardware accelerated CRC.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 22:08:58 +02:00
iabdalkader
facd715c12 common: Add CRC HAL.
CRC-16 support.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 22:08:58 +02:00
Ibrahim Abdelkader
384c3e734d
Merge pull request #2833 from openmv/add_raw_stream_ctrl
lib/imlib: Add an embedded frame header in the streaming buffer.
2025-09-11 22:57:17 +03:00
iabdalkader
1308129fdb lib/imlib: Enable raw streaming control at runtime.
Not for use with USBDBG.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 21:43:16 +02:00
iabdalkader
be25f116ab common: Skip embedded framebuffer header.
Not used for USBDBG.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 18:10:58 +02:00
iabdalkader
22981bdb61 lib/imlib: Add an embedded frame header in the streaming buffer.
Embed framebuffer header before frame data in streaming protocol to
enable protocol channels to read header+data from contiguous memory
with zero-copy operations. Header contains width, height, pixformat
and compressed size.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-11 18:09:24 +02:00
dependabot[bot]
51e87a4e40
build(deps): bump softprops/action-gh-release from 2.2.2 to 2.3.3
Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release) from 2.2.2 to 2.3.3.
- [Release notes](https://github.com/softprops/action-gh-release/releases)
- [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md)
- [Commits](da05d55257...6cbd405e2c)

---
updated-dependencies:
- dependency-name: softprops/action-gh-release
  dependency-version: 2.3.3
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-08 15:06:18 +00:00
Ibrahim Abdelkader
23808f81cf
Merge pull request #2827 from openmv/fix_update_preview
Some checks failed
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Has been cancelled
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / code-size-report (push) Has been cancelled
🔥 Firmware Build / stable-release (push) Has been cancelled
🔥 Firmware Build / development-release (push) Has been cancelled
lib/imlib: Remove test loop.
2025-09-02 19:59:22 +03:00
iabdalkader
f177d221e9 lib/imlib: Remove test loop.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 18:54:38 +02:00
Ibrahim Abdelkader
30a62c2c05
Merge pull request #2826 from openmv/refactor_jpegbuffer
lib/imlib: Use framebuffer_t for main and streaming buffers.
2025-09-02 17:16:59 +03:00
iabdalkader
cd2a4d4f95 drivers: Update framebuffer API.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 16:05:55 +02:00
iabdalkader
b1f81f7cdd common: Update framebuffer API.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 16:05:55 +02:00
iabdalkader
fbc8d14cda modules: Update framebuffer API.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 16:05:55 +02:00
iabdalkader
66c8e7e8d5 ports/all: Update framebuffer API.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 16:05:55 +02:00
iabdalkader
4d69dd396c boards/all: Rename JPEG buffer linker script variables.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 16:05:52 +02:00
iabdalkader
d05d5f1d3c lib/imlib: Use framebuffer_t for main and streaming buffers.
Removes separate jpegbuffer_t and consolidates streaming/preview
functionality into the main framebuffer_t structure.

Main changes:
- Remove jpegbuffer_t structure and global jpegbuffer variable
- Add streaming fields (enabled, quality, lock, raw_w, raw_h) to framebuffer_t
- Replace framebuffer_update_jpeg_buffer() with framebuffer_update_preview()

API improvements:
- Rename framebuffer_init_image() -> framebuffer_to_image()
- Rename framebuffer_init_from_image() -> framebuffer_from_image()
- Add framebuffer_set_enabled() and framebuffer_set_preview() utilities
- Remove accessor macros, use direct field access (kept framebuffer_get_buffer_size)
- Update framebuffer_init() to accept enabled parameter
- Add configurable raw preview dimensions per framebuffer

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 15:52:17 +02:00
iabdalkader
4c2c59d0e5 lib/imlib: Remove old framebuffer macros.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-09-02 13:41:30 +02:00
Ibrahim Abdelkader
bc39969581
Merge pull request #2801 from kwagyeman/kwabena/post_processing_speed_up
Some checks failed
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Has been cancelled
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / code-size-report (push) Has been cancelled
🔥 Firmware Build / stable-release (push) Has been cancelled
🔥 Firmware Build / development-release (push) Has been cancelled
scripts/libraries: Post-processing speedup.
2025-08-31 16:05:25 +03:00
Ibrahim Abdelkader
0e124a215d
Merge pull request #2825 from openmv/update_profiler
Some checks are pending
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Waiting to run
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / code-size-report (push) Blocked by required conditions
🔥 Firmware Build / stable-release (push) Blocked by required conditions
🔥 Firmware Build / development-release (push) Blocked by required conditions
common/profiler: Add get_size function.
2025-08-30 22:34:50 +03:00
iabdalkader
49f330f2dc common/profiler: Add get_size function.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-30 21:15:38 +02:00
Ibrahim Abdelkader
67a014ebdc
Merge pull request #2822 from kwagyeman/kwabena/fix_usb_crash
Some checks failed
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Has been cancelled
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Has been cancelled
🔥 Firmware Build / code-size-report (push) Has been cancelled
🔥 Firmware Build / stable-release (push) Has been cancelled
🔥 Firmware Build / development-release (push) Has been cancelled
common/usbdbg: Flush data from unsupported commands.
2025-08-25 12:59:07 +03:00
Kwabena W. Agyeman
657c9a6325 common/usbdbg: Flush data from unsupported commands.
The removal of unused USB commands that are still sent by the IDE
causes tinyusb boards to crash on connect currently. Flushing the
excess received bytes for unknown commands solves this issue.
2025-08-24 21:34:02 -07:00
Kwabena W. Agyeman
e64877bbea scripts/libraries: Quantize threshold instead of dequantizing scores.
Compare a quantized threshold against the scores to save having to
dequantized all the scores which takes a significant amount of time
the more classes there are in the score array output.
2025-08-24 15:22:52 -07:00
Kwabena W. Agyeman
8e72debf11 scripts/examples: Update fomo example to use the new post-processor. 2025-08-24 15:22:52 -07:00
Kwabena W. Agyeman
de7a761d3b scipts/libraries: Update fomo post-processor to use numpy vectors. 2025-08-24 15:22:51 -07:00
Kwabena W. Agyeman
84e6ee6507 modules/py_ml: Return tensor references for post-processors.
Converting the output tensors into floats for the prost-processors
causes memory exhaustion when models become very large. Additionally,
it wastes processing time converting values which may not be used. By
moving the conversion step into the post-processors we avoid this issue.

If no callback is passed for post-processing the converted output to
a floating point ndarray is returned still.
2025-08-24 14:43:24 -07:00
Kwabena W. Agyeman
7cbf85cd1c modules/py_ml: Fix py_ml_dtype_size typo. 2025-08-24 14:42:56 -07:00
Ibrahim Abdelkader
0dbb5c8aa7
Merge pull request #2816 from openmv/profiling_on_steroids
Some checks are pending
🔥 Firmware Build / build-firmware (0, ARDUINO_GIGA) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_33_BLE_SENSE) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NANO_RP2040_CONNECT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_NICLA_VISION) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, ARDUINO_PORTENTA_H7) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, DOCKER) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV2) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV4P) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMVPT) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_AE3) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / build-firmware (0, OPENMV_RT1060) (push) Waiting to run
🔥 Firmware Build / build-firmware (1, OPENMV_N6) (push) Waiting to run
🔥 Firmware Build / code-size-report (push) Blocked by required conditions
🔥 Firmware Build / stable-release (push) Blocked by required conditions
🔥 Firmware Build / development-release (push) Blocked by required conditions
common: Add code profiler.
2025-08-24 20:13:33 +03:00
iabdalkader
d4ce288ae2 workflow: Add firmware target to test profiling.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 17:17:46 +02:00
iabdalkader
d057f85f0b tools/pyopenmv: Support profiling data and elf symbols.
- Support new commands to read profiling data.
- Support rendering profiling data (ticks, cycles and event counters).
- Support loading symbol table from elf to map addresses to symbols.
- Support running scripts via command line args.

New keys:
p - Cycle through available profiling data (events, counters).
m - Toggle profiling mode (inclusive/exclusive).
r - Reset profiler.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 17:17:40 +02:00
iabdalkader
927a2c7b54 lib/tflm: Add manual profiling instrumentation.
Use OMV_PROFILER_ENTER/EXIT macros to manually instrument the TensorFlow
Lite inference function instead of automatic -finstrument-functions to
avoid C++ linking issues with operator delete and atomics.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 16:57:15 +02:00
iabdalkader
872735212f common: Support reading profiling data via USB debug.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 16:57:11 +02:00
iabdalkader
e5cdccc72e common: Introduce profiling support.
This adds a simple code profiler that leverages both SysTick and
the Performance Monitoring Unit (PMU) available on Armv8.1-M cores.
SysTick provides a simple high-resolution timer source, while the PMU
offers a cycle counter and multiple configurable event counters that
can track low-level performance metrics such as cache misses, pipeline
stalls, etc... See the Armv8.1-M Performance Monitoring User Guide
for additional details.

Function-level instrumentation is enabled using -finstrument-functions
on select files to automatically record statistics on entry/exit.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 16:57:06 +02:00
iabdalkader
cf7b84d682 ports/all: Remove old profiling macros.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
2025-08-24 14:40:02 +02:00
Ibrahim Abdelkader
e6d693cabf
Merge pull request #2820 from openmv/refactor_usbdbg
common: Refactor TinyUSB debug interface implementation.
2025-08-24 12:24:32 +03:00