Added VNC@moononournation

This commit is contained in:
lewishe
2023-08-08 11:42:32 +08:00
parent daf84a0036
commit f35b2c444a
12 changed files with 54961 additions and 1 deletions
+25
View File
@@ -0,0 +1,25 @@
/*******************************************************************************
* Keyboard libraries:
* https://github.com/Xinyuan-LilyGO/T-Deck/tree/master/examples/Keyboard_T_Deck_Master
******************************************************************************/
#include "TDECK_PINS.h"
#include <Wire.h>
void keyboard_init() {
// Check keyboard
Wire.requestFrom(TDECK_KEYBOARD_ADDR, 1);
if (Wire.read() == -1) {
Serial.println("LILYGO Keyboad not online!");
}
}
char keyboard_get_key() {
// Read key value from esp32c3
Wire.requestFrom(TDECK_KEYBOARD_ADDR, 1);
if (Wire.available() > 0) {
return Wire.read();
} else {
return 0;
}
}