From 85f9826ebed0226fa9fc325d5c58e978dd3d5f3a Mon Sep 17 00:00:00 2001 From: RavenSystem Date: Thu, 11 Jan 2024 11:21:08 +0100 Subject: [PATCH] Home Accessory Architect v12.10.3 Merlin --- HAA/HAA_Installer/main/Makefile | 3 +-- HAA/HAA_Installer/main/header.h | 2 +- HAA/HAA_Main/main/Makefile | 3 +-- HAA/HAA_Main/main/header.h | 4 ++-- HAA/HAA_Main/main/main.c | 18 +++++++++--------- sdk/esp-open-rtos-rsf/lwip/include/lwipopts.h | 2 +- .../lwip/lwip/src/core/ipv4/dhcp.c | 8 +------- 7 files changed, 16 insertions(+), 24 deletions(-) diff --git a/HAA/HAA_Installer/main/Makefile b/HAA/HAA_Installer/main/Makefile index 966ed1e0..55ea8b12 100644 --- a/HAA/HAA_Installer/main/Makefile +++ b/HAA/HAA_Installer/main/Makefile @@ -93,7 +93,6 @@ EXTRA_CFLAGS += -DDNS_TABLE_SIZE=4 EXTRA_CFLAGS += -DDNS_MAX_SERVERS=2 EXTRA_CFLAGS += -DDNS_MAX_RETRIES=2 EXTRA_CFLAGS += -DDHCP_DOES_ARP_CHECK=0 -EXTRA_CFLAGS += -DLWIP_DHCP_AGGRESSIVE #EXTRA_CFLAGS += -DCHECKSUM_CHECK_UDP=0 EXTRA_CFLAGS += -DDHCP_SERVER_MAX_LEASES=2 @@ -103,7 +102,7 @@ EXTRA_CFLAGS += -DWIFI_PARAM_SAVE=0 EXTRA_CFLAGS += -DconfigMAX_TASK_NAME_LEN=7 EXTRA_CFLAGS += -DconfigCHECK_FOR_STACK_OVERFLOW=2 EXTRA_CFLAGS += -DconfigMINIMAL_STACK_SIZE=256 -EXTRA_CFLAGS += -DconfigTIMER_TASK_PRIORITY=\(configMAX_PRIORITIES-3\) +EXTRA_CFLAGS += -DconfigTIMER_TASK_PRIORITY=\(tskIDLE_PRIORITY+5\) EXTRA_CFLAGS += -DconfigTIMER_QUEUE_LENGTH=10 EXTRA_CFLAGS += -DconfigTIMER_TASK_STACK_DEPTH=600 diff --git a/HAA/HAA_Installer/main/header.h b/HAA/HAA_Installer/main/header.h index e4001193..9386a807 100644 --- a/HAA/HAA_Installer/main/header.h +++ b/HAA/HAA_Installer/main/header.h @@ -11,6 +11,6 @@ #include "../../common/common_headers.h" #define INSTALLER_BETA_REVISION "" // Format: "b01" -#define INSTALLER_VERSION "7.8.1"INSTALLER_BETA_REVISION +#define INSTALLER_VERSION "7.8.2"INSTALLER_BETA_REVISION #endif // __HAA_OTA_HEADER_H__ diff --git a/HAA/HAA_Main/main/Makefile b/HAA/HAA_Main/main/Makefile index b96610c8..c3bf7f70 100644 --- a/HAA/HAA_Main/main/Makefile +++ b/HAA/HAA_Main/main/Makefile @@ -68,7 +68,6 @@ EXTRA_CFLAGS += -DLWIP_RAW=1 EXTRA_CFLAGS += -DARP_TABLE_SIZE=10 EXTRA_CFLAGS += -DDNS_MAX_RETRIES=2 EXTRA_CFLAGS += -DDHCP_DOES_ARP_CHECK=0 -EXTRA_CFLAGS += -DLWIP_DHCP_AGGRESSIVE EXTRA_CFLAGS += -DLWIP_DHCP_RANDOMIZE_COARSE_TIME_SECS=10 EXTRA_CFLAGS += -DDEFAULT_RAW_RECVMBOX_SIZE=5 EXTRA_CFLAGS += -DMEMP_NUM_NETCONN=16 @@ -85,7 +84,7 @@ EXTRA_CFLAGS += -DWIFI_PARAM_SAVE=0 EXTRA_CFLAGS += -DconfigMAX_TASK_NAME_LEN=7 EXTRA_CFLAGS += -DconfigCHECK_FOR_STACK_OVERFLOW=2 EXTRA_CFLAGS += -DconfigMINIMAL_STACK_SIZE=256 -EXTRA_CFLAGS += -DconfigTIMER_TASK_PRIORITY=\(configMAX_PRIORITIES-3\) +EXTRA_CFLAGS += -DconfigTIMER_TASK_PRIORITY=\(tskIDLE_PRIORITY+5\) EXTRA_CFLAGS += -DconfigTIMER_QUEUE_LENGTH=15 EXTRA_CFLAGS += -DconfigTIMER_TASK_STACK_DEPTH=736 diff --git a/HAA/HAA_Main/main/header.h b/HAA/HAA_Main/main/header.h index acdeda70..3099c0e9 100644 --- a/HAA/HAA_Main/main/header.h +++ b/HAA/HAA_Main/main/header.h @@ -11,7 +11,7 @@ #include "../../common/common_headers.h" // Version -#define HAA_FIRMWARE_VERSION "12.10.2" +#define HAA_FIRMWARE_VERSION "12.10.3" #define HAA_FIRMWARE_BETA_REVISION "" // Format: "b01" #define HAA_FIRMWARE_CODENAME "Merlin" @@ -771,7 +771,7 @@ #define SETUP_MODE_ACTIVATE_COUNT "z" #define SETUP_MODE_DEFAULT_ACTIVATE_COUNT (8) #define SETUP_MODE_TOGGLE_TIME_MS (1050) -#define CUSTOM_HAA_COMMAND "bl" +#define CUSTOM_HAA_COMMAND "dt" #define HAA_SETUP_ACCESSORY_SET "s" #define IRRF_CAPTURE_BUFFER_SIZE (2048) diff --git a/HAA/HAA_Main/main/main.c b/HAA/HAA_Main/main/main.c index b40e4e35..fbc70386 100644 --- a/HAA/HAA_Main/main/main.c +++ b/HAA/HAA_Main/main/main.c @@ -11466,15 +11466,7 @@ void normal_mode_init() { GARAGE_DOOR_HAS_F5 = 1; if (diginput_register(cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_5), garage_door_sensor, ch_group, GARAGE_DOOR_CLOSING)) { - initial_sensor = GARAGE_DOOR_OPENED; - } - } - - if (cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_4) != NULL) { - GARAGE_DOOR_HAS_F4 = 1; - - if (diginput_register(cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_4), garage_door_sensor, ch_group, GARAGE_DOOR_OPENING)) { - initial_sensor = GARAGE_DOOR_OPENED; + initial_sensor = GARAGE_DOOR_CLOSED; } } @@ -11486,6 +11478,14 @@ void normal_mode_init() { } } + if (cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_4) != NULL) { + GARAGE_DOOR_HAS_F4 = 1; + + if (diginput_register(cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_4), garage_door_sensor, ch_group, GARAGE_DOOR_OPENING)) { + initial_sensor = GARAGE_DOOR_OPENED; + } + } + if (cJSON_rsf_GetObjectItemCaseSensitive(json_context, FIXED_BUTTONS_ARRAY_2) != NULL) { GARAGE_DOOR_HAS_F2 = 1; diff --git a/sdk/esp-open-rtos-rsf/lwip/include/lwipopts.h b/sdk/esp-open-rtos-rsf/lwip/include/lwipopts.h index e5981f7b..57c6f051 100644 --- a/sdk/esp-open-rtos-rsf/lwip/include/lwipopts.h +++ b/sdk/esp-open-rtos-rsf/lwip/include/lwipopts.h @@ -582,7 +582,7 @@ void sys_unlock_tcpip_core(void); * The priority value itself is platform-dependent, but is passed to * sys_thread_new() when the thread is created. */ -#define TCPIP_THREAD_PRIO (configMAX_PRIORITIES-7) +#define TCPIP_THREAD_PRIO (configMAX_PRIORITIES-5) /** * TCPIP_MBOX_SIZE: The mailbox size for the tcpip thread messages diff --git a/sdk/esp-open-rtos-rsf/lwip/lwip/src/core/ipv4/dhcp.c b/sdk/esp-open-rtos-rsf/lwip/lwip/src/core/ipv4/dhcp.c index 26da21e0..80d9f1cb 100644 --- a/sdk/esp-open-rtos-rsf/lwip/lwip/src/core/ipv4/dhcp.c +++ b/sdk/esp-open-rtos-rsf/lwip/lwip/src/core/ipv4/dhcp.c @@ -92,12 +92,6 @@ #define LWIP_HOOK_DHCP_PARSE_OPTION(netif, dhcp, state, msg, msg_type, option, len, pbuf, offset) do { LWIP_UNUSED_ARG(msg); } while(0) #endif -#ifdef LWIP_DHCP_AGGRESSIVE -#define LWIP_DHCP_RETRY_TIMEOUT (500) -#else -#define LWIP_DHCP_RETRY_TIMEOUT (1000) -#endif /* LWIP_DHCP_AGGRESSIVE */ - /** DHCP_CREATE_RAND_XID: if this is set to 1, the xid is created using * LWIP_RAND() (this overrides DHCP_GLOBAL_XID) */ @@ -1056,7 +1050,7 @@ dhcp_discover(struct netif *netif) autoip_start(netif); } #endif /* LWIP_DHCP_AUTOIP_COOP */ - msecs = (u16_t)((dhcp->tries < 6 ? 1 << dhcp->tries : 60) * LWIP_DHCP_RETRY_TIMEOUT); + msecs = (u16_t)((dhcp->tries < 6 ? 1 << dhcp->tries : 60) * 1000); dhcp->request_timeout = dhcp_calculated_fine_time(msecs); LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | LWIP_DBG_STATE, ("dhcp_discover(): set request timeout %"U16_F" msecs\n", msecs)); return result;