#include #include #include #include #include #include #include #include #include #include #include #include #include #include "app/app.h" #include "wifi.h" #include "cell.h" #include "phone.h" #include "modem.h" #include "timer.h" #include "test.h" static const uint32_t touch_matrix[6] = {0xf7ac,0x440,0x3e704,0xfffff718,0x108a3,0xfff76d42}; static int home_page(EVEWindow *window, EVEViewStack *stack) { EVEFormSpec spec[] = { { .widget.type = EVE_WIDGET_TYPE_PAGE, .widget.g.w = APP_SCREEN_W, .widget.tspec.page.title = "WiFi", .widget.tspec.page.constructor = wifi_app, }, { .widget.type = EVE_WIDGET_TYPE_PAGE, .widget.g.w = APP_SCREEN_W, .widget.tspec.page.title = "Modem", .widget.tspec.page.constructor = modem_app, }, { .widget.type = EVE_WIDGET_TYPE_PAGE, .widget.g.w = APP_SCREEN_W, .widget.tspec.page.title = "Phone", .widget.tspec.page.constructor = phone_app, }, { .widget.type = EVE_WIDGET_TYPE_PAGE, .widget.g.w = APP_SCREEN_W, .widget.tspec.page.title = "Timer", .widget.tspec.page.constructor = timer_app, }, { .widget.type = EVE_WIDGET_TYPE_PAGE, .widget.g.w = APP_SCREEN_W, .widget.tspec.page.title = "Test", .widget.tspec.page.constructor = test_app, }, }; EVEPage *page = eve_form_create(window, stack, spec, APP_SPEC_SIZE(spec), NULL, NULL); if (page == NULL) return EVE_ERR_NOMEM; return EVE_OK; } void mem_print(void); #include int main() { uint8_t wakeup_cause; wakeup_cause = eos_init(); // eos_run_once(); eos_eve_set_tmatrix(touch_matrix); printf("FREQ:%lu\n", PRCI_get_cpu_freq()); printf("\nREADY.\n"); mem_print(); eos_gt911_cfg_print(); wifi_init(); cell_init(); phone_init(); app_init(home_page, 0x20); eos_run(wakeup_cause); eos_evtq_loop(); }