summaryrefslogtreecommitdiff
path: root/fw/fe310/phone/test.c
diff options
context:
space:
mode:
Diffstat (limited to 'fw/fe310/phone/test.c')
-rw-r--r--fw/fe310/phone/test.c23
1 files changed, 11 insertions, 12 deletions
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);
}