bdk: util: replace strtol/atoi w/ custom versions
To get rid of reentrancy baggage (which is not needed) and save binary space
This commit is contained in:
1 parent
d08fac5a08
commit
8bbe403e41
3 files changed
+97
No files matched your search
@@ -29,6 +29,7 @@ u8 btn_read()
|
||||
res |= BTN_VOL_DOWN;
|
||||
if (!gpio_read(GPIO_PORT_X, GPIO_PIN_6))
|
||||
res |= BTN_VOL_UP;
|
||||
// HOAG can use the GPIO. Icosa/Iowa/AULA cannot. Traces are there but they miss a resistor.
|
||||
if (i2c_recv_byte(I2C_5, MAX77620_I2C_ADDR, MAX77620_REG_ONOFFSTAT) & MAX77620_ONOFFSTAT_EN0)
|
||||
res |= BTN_POWER;
|
||||
return res;
|
||||
|
||||
Reference in new issue
Block a user