Basic driver support

This commit is contained in:
Indu Prakash
2022-12-23 06:49:48 -06:00
parent 517521d167
commit 6ac38d3bf7
10 changed files with 189 additions and 107 deletions

View File

@ -809,7 +809,7 @@ int http_fn_index(http_request_t* request) {
hprintf255(request, "<h5 style='color:red'>You are in safe mode (AP mode) because full reboot failed %i times. ",
Main_GetLastRebootBootFailures());
hprintf255(request, "Pins, relays, etc are disabled.</h5>");
}
// for normal page loads, show the rest of the HTML
if (!http_getArg(request->url, "state", tmpA, sizeof(tmpA))) {
@ -1425,7 +1425,7 @@ int http_fn_uart_tool(http_request_t* request) {
poststr(request, "<h4>UART Tool</h4>");
if (http_getArg(request->url, "data", tmpA, sizeof(tmpA))) {
#ifndef OBK_DISABLE_ALL_DRIVERS
#ifdef TUYA_SUPPORT
byte results[128];
hprintf255(request, "<h3>Sent %s!</h3>", tmpA);
@ -1801,7 +1801,7 @@ int http_tasmota_json_power(http_request_t* request) {
int lastRelayState;
bool bRelayIndexingStartsWithZero;
int relayIndexingOffset;
int temperature;
int temperature;
int dimmer;
bRelayIndexingStartsWithZero = CHANNEL_HasChannelPinWithRoleOrRole(0, IOR_Relay, IOR_Relay_n);
@ -1847,7 +1847,7 @@ int http_tasmota_json_power(http_request_t* request) {
// it looks like they include C and W in color
if (LED_IsLedDriverChipRunning() || numPWMs == 5) {
hprintf255(request, "\"Color\":\"%i,%i,%i,%i,%i\",",
hprintf255(request, "\"Color\":\"%i,%i,%i,%i,%i\",",
(int)rgbcw[0], (int)rgbcw[1], (int)rgbcw[2], (int)rgbcw[3], (int)rgbcw[4]);
}
else {
@ -1966,7 +1966,7 @@ int http_tasmota_json_status_SNS(http_request_t* request) {
return 0;
}
#if defined(PLATFORM_W600) || defined (PLATFORM_W800)
#ifndef BASIC_DRIVER_SUPPORT
unsigned int NTP_GetCurrentTime() {
return 0;
}
@ -2522,7 +2522,7 @@ const char* g_obk_flagNames[] = {
"error",
"error",
"error",
};
};
int http_fn_cfg_generic(http_request_t* request) {
int i;
char tmpA[64];