add set kbd backlight via i2c example in picocalc_helloworld

This commit is contained in:
cuu
2025-04-27 15:32:55 +08:00
parent f2fa13099c
commit 111319e22d
3 changed files with 48 additions and 0 deletions

View File

@@ -16,7 +16,10 @@
void init_i2c_kbd();
int read_i2c_kbd();
int read_battery();
int set_kbd_backlight(uint8_t);
#define bitRead(value, bit) (((value) >> (bit)) & 0x01)
#define bitClear(value, bit) ((value) &= ~(1 << (bit)))
#define bitSet(value, bit) ((value) |= (1 << (bit)))
#endif