forked from xiaozhi/xiaozhi-esp32
add zhengchen_boards_wifi(征辰科技) (#635)
* add zhengchen_boards_wifi * add zhengchen_boards_wifi1
This commit is contained in:
@@ -30,6 +30,10 @@ int Axp2101::GetBatteryLevel() {
|
||||
return ReadReg(0xA4);
|
||||
}
|
||||
|
||||
float Axp2101::GetTemperature() {
|
||||
return ReadReg(0xA5);
|
||||
}
|
||||
|
||||
void Axp2101::PowerOff() {
|
||||
uint8_t value = ReadReg(0x10);
|
||||
value = value | 0x01;
|
||||
|
||||
@@ -10,6 +10,7 @@ public:
|
||||
bool IsDischarging();
|
||||
bool IsChargingDone();
|
||||
int GetBatteryLevel();
|
||||
float GetTemperature();
|
||||
void PowerOff();
|
||||
|
||||
private:
|
||||
|
||||
@@ -48,6 +48,10 @@ bool Board::GetBatteryLevel(int &level, bool& charging, bool& discharging) {
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Board::GetTemperature(float& esp32temp){
|
||||
return false;
|
||||
}
|
||||
|
||||
Display* Board::GetDisplay() {
|
||||
static NoDisplay display;
|
||||
return &display;
|
||||
|
||||
@@ -37,6 +37,7 @@ public:
|
||||
virtual Backlight* GetBacklight() { return nullptr; }
|
||||
virtual Led* GetLed();
|
||||
virtual AudioCodec* GetAudioCodec() = 0;
|
||||
virtual bool GetTemperature(float& esp32temp);
|
||||
virtual Display* GetDisplay();
|
||||
virtual Http* CreateHttp() = 0;
|
||||
virtual WebSocket* CreateWebSocket() = 0;
|
||||
|
||||
Reference in New Issue
Block a user