summaryrefslogtreecommitdiff
path: root/fw/fe310/test/cam.c
diff options
context:
space:
mode:
authorUros Majstorovic <majstor@majstor.org>2021-11-25 01:59:07 +0100
committerUros Majstorovic <majstor@majstor.org>2021-11-25 01:59:07 +0100
commit6a31936e80ae2743376dcbf9d39cd92461c4deca (patch)
treef6dedd2cbf3aee9bb8135c7a4ff874c066a6d072 /fw/fe310/test/cam.c
parentc44897fda572cf8837b4535a6d1aaad4605c14af (diff)
i2s init/start/running fixed; i2c start returns error if i2s is running
Diffstat (limited to 'fw/fe310/test/cam.c')
-rw-r--r--fw/fe310/test/cam.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fw/fe310/test/cam.c b/fw/fe310/test/cam.c
index caab2cc..3162b40 100644
--- a/fw/fe310/test/cam.c
+++ b/fw/fe310/test/cam.c
@@ -139,9 +139,9 @@ void app_cam(EVEWindow *window, EVEViewStack *stack) {
eve_gpio_set(EVE_GPIO_CAM, 1);
eos_time_sleep(100);
- eos_i2c_start(100000);
- rv = eos_ov2640_init();
+ rv = eos_i2c_start(100000);
+ if (!rv) rv = eos_ov2640_init();
if (!rv) rv = eos_ov2640_set_pixfmt(PIXFORMAT_JPEG);
if (!rv) rv = eos_ov2640_set_framesize(FRAMESIZE_VGA);
eos_i2c_stop();