feat: enhance weight handling and display feedback in API and NFC modules
This commit is contained in:
1 parent
741a7d9262
commit
9875e85e31
5 files changed
+48
-8
No files matched your search
@@ -254,6 +254,19 @@ void oledShowWeight(uint16_t weight) {
|
||||
display.display();
|
||||
}
|
||||
|
||||
void oledShowRemainingWeight(uint16_t remainingWeight) {
|
||||
oledcleardata();
|
||||
display.setTextSize(1);
|
||||
display.setCursor(oled_center_h("Weight sent, rest:"), OLED_DATA_START + 4);
|
||||
display.print("Weight sent, rest:");
|
||||
|
||||
display.setTextSize(3);
|
||||
String weightStr = String(remainingWeight) + " g";
|
||||
display.setCursor(oled_center_h(weightStr), OLED_DATA_START + 22);
|
||||
display.print(weightStr);
|
||||
display.display();
|
||||
}
|
||||
|
||||
void oledShowConnectionError(const char* error, const String& ip) {
|
||||
oledcleardata();
|
||||
display.setTextSize(1);
|
||||
|
||||
Reference in new issue
Block a user