uint32_t volatile *reg;
gpioPullupMode_t mode;
} const input_pins[] = {
-#ifdef HOB_REV2
- { RB_BTN0 , &RB_BTN0_IO , gpioPullupMode_PullDown },
- { RB_BTN1 , &RB_BTN1_IO , gpioPullupMode_PullDown },
- { RB_BTN2 , &RB_BTN2_IO , gpioPullupMode_PullDown },
- { RB_BTN3 , &RB_BTN3_IO , gpioPullupMode_PullDown },
- { RB_BTN4 , &RB_BTN4_IO , gpioPullupMode_PullDown },
- { RB_HB0 , &RB_HB0_IO , gpioPullupMode_PullDown },
- { RB_HB1 , &RB_HB1_IO , gpioPullupMode_PullDown },
- { RB_PWR_CHRG, &RB_PWR_CHRG_IO, gpioPullupMode_PullDown }
-#else
{ RB_BTN0 , &RB_BTN0_IO , gpioPullupMode_PullUp },
{ RB_BTN1 , &RB_BTN1_IO , gpioPullupMode_PullUp },
{ RB_BTN2 , &RB_BTN2_IO , gpioPullupMode_PullUp },
{ RB_HB0 , &RB_HB0_IO , gpioPullupMode_PullUp },
{ RB_HB1 , &RB_HB1_IO , gpioPullupMode_PullUp },
{ RB_PWR_CHRG, &RB_PWR_CHRG_IO, gpioPullupMode_PullUp }
-#endif
};
for(int i = 0; i < ARRAY_SIZE(input_pins); ++i) {
// größer werden: Parameter aus main_menu empfangen und merken.
uint8_t first_visible = 0;
char const *const menu[] = {
- "Vanity-Screen",
+ "Titelbild",
"Super Hackio",
"Fahrplan",
"USB-Modus"
f_mount(0, &fs);
#ifdef USBONLY
+ if(badge_input_raw() & BADGE_EVENT_KEY_LEFT) {
+ gpioSetValue(HOB_PORT(HOB_LED_LEFT), HOB_PIN(HOB_LED_LEFT) , 1);
+ }
+ if(badge_input_raw() & BADGE_EVENT_KEY_RIGHT) {
+ gpioSetValue(HOB_PORT(HOB_LED_RIGHT), HOB_PIN(HOB_LED_RIGHT) , 1);
+ }
+
for(;;) usbmode();
#else
if(badge_input_raw() & BADGE_EVENT_KEY_DOWN) {
}
badge_event_start();
+ badge_vanity_show();
main_menu();
#endif