Commit Graph

3634 Commits

Author SHA1 Message Date
Kwabena W. Agyeman
591bf1ce2d lib/libtf: Add model operator order hash support. 2024-02-25 12:19:41 -08:00
Kwabena W. Agyeman
3705652b23 imlib: Update min/max usage to clamp and sat. 2024-02-24 13:46:04 -08:00
Ibrahim Abdelkader
47da5ec07c
Merge pull request #2145 from kwagyeman/kwabena/optimize_math_ops
imlib: Optimize math ops.
2024-02-23 09:25:28 +02:00
Kwabena W. Agyeman
a1b484f378 imlib: Optimize math ops. 2024-02-22 12:21:10 -08:00
Kwabena W. Agyeman
e1aeef49fa imlib: Optimize binary ops. 2024-02-19 21:30:03 -08:00
Ibrahim Abdelkader
7084effc7f
Merge pull request #2139 from kwagyeman/kwabena/optimize_invert
modules/py_image: Optimize invert and negate.
2024-02-18 11:21:07 +02:00
Kwabena W. Agyeman
5b993fa765 imlib/jpege: Fix jpeg timing code. 2024-02-17 23:20:48 -08:00
Ibrahim Abdelkader
9b8e39c608
Merge pull request #2156 from kwagyeman/kwabena/update_lib_tf_again
lib/libtf: Fixed missing tensorflow operators crash.
2024-02-18 09:13:49 +02:00
Ibrahim Abdelkader
c0ee9a967f
Merge pull request #2068 from kwagyeman/kwabena/add_user_spi_display_control
modules/py_display: Add user SPI LCD register control.
2024-02-18 00:39:25 +02:00
Kwabena W. Agyeman
bee933d9d2 lib/libtf: Fixed missing tensorflow operators crash. 2024-02-17 14:32:10 -08:00
Kwabena W. Agyeman
59fea5bc52 imlib/jpege: Improve jpeg YUV422/420 UV sub-sampling speed. 2024-02-16 16:51:12 -08:00
Kwabena W. Agyeman
4fe7fb63b9 imlib: Remove mul(). 2024-02-16 11:49:19 -08:00
Kwabena W. Agyeman
179888f233 modules: Add controller and bus write support to spi display. 2024-02-15 13:45:42 -08:00
Kwabena W. Agyeman
7d1f378a08 modules: Change dsi read/write to generic bus read/write. 2024-02-15 13:43:03 -08:00
iabdalkader
694e783f14 boards/ARDUINO_GIGA: Enable GC2145 driver. 2024-02-15 21:06:19 +01:00
Ibrahim Abdelkader
17412e544c
Merge pull request #2151 from openmv/ov5640_gc2145_fix
misc: Support using GC2145 and OV5640 at the same time.
2024-02-15 22:05:33 +02:00
Ibrahim Abdelkader
3f1b71cb48
Merge pull request #2147 from kwagyeman/kwabena/remove_cartoon
imlib: Remove cartoon() method.
2024-02-15 22:02:33 +02:00
iabdalkader
a62d606467 misc: Support using GC2145 and OV5640 at the same time.
Both sensors have the same I2C address, so can't be enabled at the
same time. This patch tries to read a byte-sized address first,
if GC2145 chip id is not read back, then it retries reading wide
address. I tested this with RT1060 and H7 and I can detect the OV5640
fine.
2024-02-15 21:01:47 +01:00
Kwabena W. Agyeman
c017cde2bb ports/stm32: Move instances to init functions. 2024-02-14 17:02:29 -08:00
Kwabena W. Agyeman
567cc08281 ports/stm32: Fix setting freq to zero bug. 2024-02-14 16:57:43 -08:00
Kwabena W. Agyeman
c5cf3cf498 ports/stm32: Fix xclk duty cycle to 50%. 2024-02-14 16:53:57 -08:00
Ibrahim Abdelkader
78c7d1aa43
Merge pull request #2140 from kwagyeman/kwabena/remove_slow_stuff
modules/py_image: Remove div() method.
2024-02-14 09:39:17 +02:00
Ibrahim Abdelkader
82b61a8553
Merge pull request #2138 from kwagyeman/kwabena/move_ksize_helper
imlib: Add ksize helper.
2024-02-14 09:37:58 +02:00
Kwabena W. Agyeman
055a468b83 imlib: Remove cartoon() method. 2024-02-12 20:27:41 -08:00
Kwabena W. Agyeman
31847bdac7 imlib: Simplify binary mask and zero code. 2024-02-12 18:19:31 -08:00
Ibrahim Abdelkader
32b7075bc6
Merge pull request #2141 from openmv/sensor_utils_reconfigure
ports/all: Add a sensor function to reconfigure hardware if/when needed.
2024-02-12 22:30:19 +02:00
Ibrahim Abdelkader
afe7087b5e
Merge pull request #2123 from kwagyeman/kwabena/enable_edma
ports/mimxrt: Enable edma memcpy.
2024-02-12 22:30:01 +02:00
Kwabena W. Agyeman
63edb776c3 ports/mimxrt: Enable edma memcpy. 2024-02-12 12:05:24 -08:00
iabdalkader
ebc4c6c831 ports/all: Add a sensor function to reconfigure hardware if/when needed.
sensor_dcmi_config function was called every time the pixel format changed,
and typically reconfigured the capture interface. This originated from the
stm32 port, which required reconfiguring the DCMI if the pixel format changed.
However, most ports only require configuring the capture interface once
during initialization (for example nrf, rp2 and mimxrt ports).
The new sensor_config function is called after a setting that may require
reconfiguring the hardware changes, such as such as window size, frame size,
or pixel format. The exact setting that has changed is passed to the function,
allowing ports to decide whether to do a full reconfiguration of the hardware,
or just ignore it based on the changed setting.
2024-02-12 18:32:36 +01:00
Ibrahim Abdelkader
262eb98e43
Merge pull request #2133 from kwagyeman/kwabena/tensor_flow_update_2_2024
modules/py_tf: Refactor regression() code to handle arrays correctly.
2024-02-11 21:37:05 +02:00
Kwabena W. Agyeman
84cca7c6ca modules/py_image: Optimize invert and negate. 2024-02-10 11:54:26 -08:00
Kwabena W. Agyeman
7c932602e2 modules/py_image: Remove div() method. 2024-02-10 11:49:17 -08:00
Kwabena W. Agyeman
70ea77c044 imlib: Add ksize helper. 2024-02-10 11:24:57 -08:00
Kwabena W. Agyeman
61ec9006bb hal/sensor_utils: Allow DMA memcpy fallback to CPU. 2024-02-10 10:42:30 -08:00
Kwabena W. Agyeman
7c6105e54c ports/mimxrt: Use hardware byteswap support. 2024-02-10 10:31:52 -08:00
Kwabena W. Agyeman
c5ec576c11 modules/py_tf: Refactor regression() code to handle arrays correctly. 2024-02-09 11:43:37 -08:00
iabdalkader
b69f9306d4 boards/NICLA_VISION: Reduce flash usage. 2024-02-09 16:50:16 +02:00
iabdalkader
602530c5fd imlib: Add config options for find_features. 2024-02-09 16:08:12 +02:00
iabdalkader
1b58433320 imlib: Refactor collections linked list.
- Remove unused linked list functions.
- Remove iterator functions and replace them with a list_for_each macro.
Note the smaller iterator functions may Not have been inlined because
we -fno-inline-small-functions is used.
- Replace iterator_get which used memcpy, with a cast.
- Add list_insert and list_remove functions.
2024-02-07 13:25:00 +02:00
Ibrahim Abdelkader
3803e7d5fa
Merge pull request #2131 from openmv/refactor_boardconfig
misc: Refactor board config files.
2024-02-06 21:23:40 +02:00
iabdalkader
bc5222df03 misc: Refactor board config files.
- Rename options more consistently.
- Add OMV prefix to every config option.
- Replace the ST-specific DCMI prefix with CSI.
- Remove the clock source defined in every header to a common enum.
- Remove obsolete board config options.
2024-02-06 21:20:56 +02:00
Ibrahim Abdelkader
4d22163733
Merge pull request #2082 from kwagyeman/kwabena/pure_termal_example_update
scripts/examples: Add working Pure Thermal OpenMV example.
2024-02-04 11:38:13 +02:00
Ibrahim Abdelkader
bd3aa0494e
Merge pull request #2089 from kwagyeman/kwabena/fix_yuv_shift
ports: Add yuv shift to match bayer shift.
2024-02-04 11:37:29 +02:00
iabdalkader
e7087367e3 misc: Add custom board reset function. 2024-02-04 11:07:24 +02:00
Kwabena W. Agyeman
b57864ea11 scripts/examples: Add working Pure Thermal OpenMV example. 2024-02-03 12:06:04 -08:00
iabdalkader
725dcdd5cf boards/all: Enable OMA_ENABLE_DMA_MEMCPY for boards that support it. 2024-02-03 09:07:06 +02:00
iabdalkader
345b80358d ports/all: Refactor frame buffer line copying code. 2024-02-03 09:07:02 +02:00
Ibrahim Abdelkader
27161405b4
Merge pull request #2129 from openmv/nrf_sensor_format
misc: Code formatting.
2024-02-03 09:03:47 +02:00
iabdalkader
ae54a50663 misc: Code formatting. 2024-02-03 09:01:04 +02:00
iabdalkader
db65ab81d8 ports/all: Refactor frame rate control. 2024-02-03 08:59:52 +02:00
Ibrahim Abdelkader
f1f1bd1258
Merge pull request #2126 from openmv/update_micropython_fork
micropython: Update fork to fix shared TinyUSB HS config.
2024-02-02 10:37:21 +02:00
iabdalkader
759b4e05d8 micropython: Update fork to fix shared TinyUSB HS config. 2024-02-02 10:31:58 +02:00
Kwabena W. Agyeman
9b0dc3458a common/sensor: Add comments about bayer patterns. 2024-02-01 18:12:17 -08:00
Kwabena W. Agyeman
b5d9bbca30 ports: Move first_line and drop_frame to sensor.c. 2024-02-01 17:57:25 -08:00
Kwabena W. Agyeman
018f2eaed1 ports: Move copy_transposed_line to sensor.h. 2024-02-01 17:40:23 -08:00
iabdalkader
cec66374fb ports/stm32: Scan devices once per scan.
This saves boot time and also fixes an issue with some image
sensors.
2024-01-31 22:15:24 +02:00
iabdalkader
d04209e083 hal/omv_i2c: Update I2C flags. 2024-01-31 17:25:14 +02:00
Kwabena W. Agyeman
7a33d891b2 modules/py_fir: Fix mlx data root pointer. 2024-01-30 22:30:32 -08:00
Ibrahim Abdelkader
fce8e44989
Merge pull request #2098 from xue-singtown/master
imlib/draw: Add anti aliasing in draw_line.
2024-01-30 20:49:44 +02:00
xue-singtown
25f760991e imlib/draw: Add anti aliasing in draw_line. 2024-01-30 17:39:42 +08:00
Ibrahim Abdelkader
a3be7d6fa8
Merge pull request #2088 from kwagyeman/kwabena/fix_bayer
ports: Fix sensor bayer image with cropping and transpose.
2024-01-27 11:16:59 +02:00
Ibrahim Abdelkader
b792c592b2
Merge pull request #2117 from bitbank2/master
imlib/jpegd: Fix jpeg decode for non-multiple of 8.
2024-01-26 20:16:49 +02:00
Laurence Bank
19d1b11eef imlib/jpegd: Fix jpeg decode for non-multiple of 8. 2024-01-26 18:08:47 +00:00
Ibrahim Abdelkader
0afc4c6574
Merge pull request #2116 from openmv/sensor_abort_args
ports/all: Allow sensor_abort() to be called from different contexts.
2024-01-26 19:47:32 +02:00
iabdalkader
d478f19326 ports/all: Allow sensor_abort() to be called from different contexts.
This patch removes the duplicated `sensor_abort()` logic in the stm32 and mimxrt ports.
This is done by adding a `flush_fifo` argument, which controls the flush operation, and
a `in_irq` argument , which indicates whether `sensor_abort()` is called from within an
IRQ context or not.
2024-01-26 19:42:48 +02:00
iabdalkader
955c8ae42e micropython: Update Arduino boards pins. 2024-01-26 10:37:42 +02:00
iabdalkader
9999e0a9ea imlib: Combine framebuffer reset and flush.
To simplify the API, a single function is now used to flush old
frames only, or reset and drop all frames.
2024-01-26 09:05:45 +02:00
Ibrahim Abdelkader
609a882c68
Merge pull request #2114 from kwagyeman/kwabena/fix_comment
ports: Fix sensor abstraction layer comment.
2024-01-26 08:40:19 +02:00
Kwabena W. Agyeman
91250fba30 ports: Fix sensor abstraction layer comment. 2024-01-25 12:56:15 -08:00
Kwabena W. Agyeman
78a0d03ab3 port/mimxrt: Add sensor.JPEG support. 2024-01-24 18:44:56 -08:00
Kwabena W. Agyeman
01c2a8417c boards/OPENMV_RT1060: Update line buffer size to handle max image resolution. 2024-01-24 18:44:56 -08:00
Kwabena W. Agyeman
1f4bbd32a1 boards/OPENMV_RT1060: Update framebuffer size to maximum. 2024-01-24 18:44:56 -08:00
Kwabena W. Agyeman
6d640d8a9a ports/mimxrt: Fix mimxrt sensor.set_windowing(). 2024-01-24 18:44:56 -08:00
Kwabena W. Agyeman
391c1752f6 ports/mimxrt: Add frame_callback support. 2024-01-24 16:58:11 -08:00
Kwabena W. Agyeman
b4a57ffca2 ports/mimxrt: Add set_framerate support. 2024-01-24 16:58:11 -08:00
Ibrahim Abdelkader
baa8a4ee58
Merge pull request #2113 from kwagyeman/kwabena/fix_gamma_bug
modules/py_image: Fix bug with gamma arguments.
2024-01-24 20:57:06 +02:00
Kwabena W. Agyeman
64a02db1c7 micropython: Add back IMXRT CAN Driver. 2024-01-24 10:13:24 -08:00
Kwabena W. Agyeman
8540d44aa2 modules/py_image: Fix bug with gamma arguments. 2024-01-24 10:11:33 -08:00
Kwabena W. Agyeman
ab7f4323fa sensors/paj6100: Fix driver for RT1062. 2024-01-23 17:20:34 -08:00
Kwabena W. Agyeman
29076f597e board/OPENMV_RT1060: Enable ISP Ops. 2024-01-23 12:31:03 -08:00
Kwabena W. Agyeman
49dc731344 boards/OPENMV_RT1060: Enable ulab. 2024-01-22 21:48:33 -08:00
Kwabena W. Agyeman
11c1862345 micropython: Fix deepsleep on mimxrt1062. 2024-01-22 14:34:41 -08:00
iabdalkader
f42fa85873 ports/all: Remove custom pendsv prototypes. 2024-01-20 10:18:47 +02:00
iabdalkader
8da2436c05 ports/all: Refactor PendSV code.
All ports use common PendSV code now, with port-specific
PendSV entries defined in pendsv.h files.
2024-01-20 10:02:56 +02:00
Kwabena W. Agyeman
3b263c3a68 boards: Enable OV5640 Autofocus firmware and add example. 2024-01-19 16:21:04 -08:00
iabdalkader
eec8640d7e misc: Use LD wrap for redirecting serial data to TinyUSB debug code.
Prior to this update, each port had to be patched to call TinyUSB
debugging function. Now these wrappers will call the port's functions
if debugging is not enabled.
2024-01-19 18:09:49 +02:00
iabdalkader
801cb29d6c misc: Update to Arm GNU Toolchain 13.2.rel1. 2024-01-17 10:47:09 +02:00
iabdalkader
8c574f3c9b micropython: Disable GC scanning of BSS.
We no longer need this, since all global pointers are now referenced by
root pointers.
2024-01-17 09:58:53 +02:00
Kwabena W. Agyeman
1f15790cb1 imlib/fmath: Fix compiling fast_expf. 2024-01-17 09:46:36 +02:00
Kwabena W. Agyeman
b3ce9d6302 imlib/qrcode: Fix new GCC compile issues. 2024-01-17 09:29:18 +02:00
Kwabena W. Agyeman
b09dbbdd47 imlib/filter: Fix offset argument being truncated. 2024-01-17 09:29:18 +02:00
iabdalkader
1601f8f029 misc: Fix errors triggered by disabling specific features. 2024-01-17 09:17:15 +02:00
Ibrahim Abdelkader
d0d234568d
Merge pull request #2094 from openmv/cmsis_update
ports/all: Update to CMSIS version 5.9.0.
2024-01-16 19:56:26 +02:00
iabdalkader
78b9daf2d6 boards/all: Add CMSIS_MCU_H board config option. 2024-01-16 19:20:14 +02:00
iabdalkader
9ac8540ed3 ports/all: Update code to support new CMSIS. 2024-01-16 19:20:09 +02:00
iabdalkader
9f56943cf3 hal/CMSIS: Update to CMSIS v5.9.0. 2024-01-16 17:48:43 +02:00
Ibrahim Abdelkader
5c6b34becb
Merge pull request #2093 from kwagyeman/kwabena/error_jpg_size
ports/stm32: Error on jpeg geometry mismatch.
2024-01-15 20:31:34 +02:00
Kwabena W. Agyeman
333fb2b5fe ports/stm32: Error on jpeg geometry mismatch. 2024-01-14 23:30:22 -08:00
Kwabena W. Agyeman
b101c58811 hal/cmsis: Move cmsis gcc extensions to new file. 2024-01-14 11:41:01 -08:00
Kwabena W. Agyeman
00500ccdef modules/sensor: Disable transpose for YUV422 images. 2024-01-12 18:51:27 -08:00