Skip to content

Commit 494bc27

Browse files
committed
loader/boards/arduino_giga_r1_m7: Update board files.
- Enable video subsystem, DCMI and sensors. - Switch to GC2145 sensor. Signed-off-by: iabdalkader <[email protected]>
1 parent c351fad commit 494bc27

File tree

2 files changed

+16
-11
lines changed

2 files changed

+16
-11
lines changed

Diff for: loader/boards/arduino_giga_r1_m7.conf

+6-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,11 @@ CONFIG_PWM=y
1919
CONFIG_DMA=y
2020
CONFIG_MEMC=y
2121

22-
#CONFIG_VIDEO=y
22+
CONFIG_VIDEO=y
2323
CONFIG_VIDEO_STM32_DCMI=y
2424
CONFIG_VIDEO_BUFFER_POOL_NUM_MAX=1
25-
CONFIG_VIDEO_BUFFER_POOL_SZ_MAX=160000
25+
CONFIG_VIDEO_BUFFER_POOL_SZ_MAX=160000
26+
CONFIG_VIDEO_BUFFER_POOL_ALIGN=32
27+
CONFIG_VIDEO_LOG_LEVEL_DBG=y
28+
29+
CONFIG_VIDEO_GC2145=y

Diff for: loader/boards/arduino_giga_r1_m7.overlay

+10-9
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@
2929

3030
&i2c4 {
3131
status = "okay";
32-
ov7670: ov7670@21 {
33-
compatible = "ovti,ov7670";
34-
reg = <0x21>;
32+
gc2145: gc2145@3c {
33+
compatible = "galaxycore,gc2145";
34+
reg = <0x3c>;
3535
reset-gpios = <&gpiod 4 GPIO_ACTIVE_LOW>;
3636
pwdn-gpios = <&gpioa 1 GPIO_ACTIVE_LOW>;
3737

3838
port {
39-
ov7670_ep_out: endpoint {
39+
gc2145_ep_out: endpoint {
4040
remote-endpoint = <&dcmi_ep_in>;
4141
};
4242
};
@@ -76,7 +76,7 @@
7676
compatible = "pwm-clock";
7777
clock-frequency = <0>;
7878
#clock-cells = <1>;
79-
pwms = <&cam_clock_pwm 3 PWM_HZ(6000000) PWM_POLARITY_NORMAL>;
79+
pwms = <&cam_clock_pwm 3 PWM_HZ(12000000) PWM_POLARITY_NORMAL>;
8080
};
8181
};
8282

@@ -90,7 +90,7 @@
9090

9191
&dcmi {
9292
status = "okay";
93-
sensor = <&ov7670>;
93+
sensor = <&gc2145>;
9494
/* ext-sdram = <&sdram1>; */
9595
pinctrl-0 = <&dcmi_hsync_ph8 &dcmi_pixclk_pa6 &dcmi_vsync_pi5
9696
&dcmi_d0_ph9 &dcmi_d1_ph10 &dcmi_d2_ph11 &dcmi_d3_pg11
@@ -102,12 +102,12 @@
102102
pixelclk-active = <0>;
103103
capture-rate = <1>;
104104
dmas = <&dma1 0 75 (STM32_DMA_PERIPH_TO_MEMORY | STM32_DMA_PERIPH_NO_INC |
105-
STM32_DMA_MEM_INC | STM32_DMA_PERIPH_8BITS | STM32_DMA_MEM_32BITS |
105+
STM32_DMA_MEM_INC | STM32_DMA_PERIPH_32BITS | STM32_DMA_MEM_32BITS |
106106
STM32_DMA_PRIORITY_HIGH) STM32_DMA_FIFO_1_4>;
107107

108108
port {
109109
dcmi_ep_in: endpoint {
110-
remote-endpoint = <&ov7670_ep_out>;
110+
remote-endpoint = <&gc2145_ep_out>;
111111
};
112112
};
113113
};
@@ -264,6 +264,7 @@
264264
/{
265265
chosen {
266266
zephyr,camera = &dcmi;
267+
/* zephyr,console = &cdc_acm_uart0; */
267268
};
268269

269270
/* used to overcome problems with _C analog pins */
@@ -450,7 +451,7 @@
450451
cdc-acm = <&cdc_acm_uart0>;
451452
i2cs = <&i2c2>, <&i2c4>, <&i2c1>;
452453
spis = <&spi1>, <&spi5>;
453-
pwms = <&cam_clock_pwm 3 PWM_HZ(6000000) PWM_POLARITY_NORMAL>;
454+
pwms = <&cam_clock_pwm 3 PWM_HZ(12000000) PWM_POLARITY_NORMAL>;
454455

455456
io-channels = <&adc1 4>,
456457
<&adc1 8>,

0 commit comments

Comments
 (0)