From 69ed847740e3efb5c5ff6319629c93d236150959 Mon Sep 17 00:00:00 2001 From: Uros Majstorovic Date: Fri, 23 Sep 2022 20:08:02 +0200 Subject: i2s driver fixed; added uart programming; --- fw/fe310/phone/test.c | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) (limited to 'fw/fe310/phone/test.c') diff --git a/fw/fe310/phone/test.c b/fw/fe310/phone/test.c index df3871e..72f575f 100644 --- a/fw/fe310/phone/test.c +++ b/fw/fe310/phone/test.c @@ -28,6 +28,17 @@ static int reg_write(uint8_t reg, uint8_t data) { return eos_i2c_write8(BQ25895_ADDR, reg, &data, 1); } +int test_app(EVEWindow *window, EVEViewStack *stack) { + EVEFormSpec spec[] = { + APP_SPACERW(1,1), + }; + EVEPage *page = eve_form_create(window, stack, spec, APP_SPEC_SIZE(spec), test_uievt, test_close); + if (page == NULL) return EVE_ERR_NOMEM; + app_status_set_msg("TEST!"); + + return EVE_OK; +} + int test_uievt(EVEPage *page, uint16_t evt, void *param) { int ret = 0; @@ -36,7 +47,6 @@ int test_uievt(EVEPage *page, uint16_t evt, void *param) { uint8_t data = 0; int rv, i; - printf("PAGE TOUCH\n"); printf("BQ25895:\n"); for (i=0; i<0x15; i++) { rv = reg_read(i, &data); @@ -54,17 +64,6 @@ int test_uievt(EVEPage *page, uint16_t evt, void *param) { return ret; } -int test_app(EVEWindow *window, EVEViewStack *stack) { - EVEFormSpec spec[] = { - APP_SPACERW(1,1), - }; - EVEPage *page = eve_form_create(window, stack, spec, APP_SPEC_SIZE(spec), test_uievt, test_close); - if (page == NULL) return EVE_ERR_NOMEM; - app_status_set_msg("TEST!"); - - return EVE_OK; -} - void test_close(EVEPage *page) { eve_form_destroy(page); } -- cgit v1.2.3