|
@@ -15,7 +15,11 @@
|
|
#include "commands_api.h"
|
|
#include "commands_api.h"
|
|
#include "common_config.h"
|
|
#include "common_config.h"
|
|
#include "gpio.h"
|
|
#include "gpio.h"
|
|
|
|
+#if defined HARDWARE_BT6702
|
|
#include "board_bt6702.h"
|
|
#include "board_bt6702.h"
|
|
|
|
+#elif defined HARDWARE_BT6706
|
|
|
|
+#include "board_bt6706.h"
|
|
|
|
+#endif
|
|
#include "buttons.h"
|
|
#include "buttons.h"
|
|
#include "led.h"
|
|
#include "led.h"
|
|
#include "netconf.h"
|
|
#include "netconf.h"
|
|
@@ -99,7 +103,7 @@ void Test_DRY(void)
|
|
|
|
|
|
inputState = get_state_din_outs(DIN1);
|
|
inputState = get_state_din_outs(DIN1);
|
|
|
|
|
|
- set_state_douts(DOUT1, 1);
|
|
|
|
|
|
+ set_state_douts(DOUT1, 0);
|
|
|
|
|
|
vTaskDelay(10);
|
|
vTaskDelay(10);
|
|
|
|
|
|
@@ -109,7 +113,7 @@ void Test_DRY(void)
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
|
|
|
|
- set_state_douts(DOUT1, 0);
|
|
|
|
|
|
+ set_state_douts(DOUT1, 1);
|
|
|
|
|
|
vTaskDelay(10);
|
|
vTaskDelay(10);
|
|
|
|
|
|
@@ -121,17 +125,41 @@ void Test_DRY(void)
|
|
|
|
|
|
inputState = get_state_din_outs(DIN1);
|
|
inputState = get_state_din_outs(DIN1);
|
|
|
|
|
|
|
|
+ set_state_douts(DOUT2, 0);
|
|
|
|
+
|
|
|
|
+ vTaskDelay(10);
|
|
|
|
+
|
|
|
|
+ if (get_state_din_outs(DIN1) == inputState) {
|
|
|
|
+ printf("DRY FAIL\r\n");
|
|
|
|
+ TEST_SetTest(TEST_WAIT);
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+
|
|
set_state_douts(DOUT2, 1);
|
|
set_state_douts(DOUT2, 1);
|
|
|
|
|
|
vTaskDelay(10);
|
|
vTaskDelay(10);
|
|
|
|
|
|
|
|
+ if (get_state_din_outs(DIN1) != inputState) {
|
|
|
|
+ printf("DRY FAIL\r\n");
|
|
|
|
+ TEST_SetTest(TEST_WAIT);
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ vTaskDelay(10);
|
|
|
|
+#ifdef HARDWARE_BT6706
|
|
|
|
+ inputState = get_state_din_outs(DIN1);
|
|
|
|
+
|
|
|
|
+ set_state_douts(DOUT3, 0);
|
|
|
|
+
|
|
|
|
+ vTaskDelay(10);
|
|
|
|
+
|
|
if (get_state_din_outs(DIN1) == inputState) {
|
|
if (get_state_din_outs(DIN1) == inputState) {
|
|
printf("DRY FAIL\r\n");
|
|
printf("DRY FAIL\r\n");
|
|
TEST_SetTest(TEST_WAIT);
|
|
TEST_SetTest(TEST_WAIT);
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
|
|
|
|
- set_state_douts(DOUT2, 0);
|
|
|
|
|
|
+ set_state_douts(DOUT3, 1);
|
|
|
|
|
|
vTaskDelay(10);
|
|
vTaskDelay(10);
|
|
|
|
|
|
@@ -142,6 +170,7 @@ void Test_DRY(void)
|
|
}
|
|
}
|
|
|
|
|
|
vTaskDelay(10);
|
|
vTaskDelay(10);
|
|
|
|
+#endif
|
|
|
|
|
|
printf("DRY OK\r\n");
|
|
printf("DRY OK\r\n");
|
|
TEST_SetTest(TEST_WAIT);
|
|
TEST_SetTest(TEST_WAIT);
|
|
@@ -278,6 +307,7 @@ void Test_Ethernet(void)
|
|
if (ethernetInit == false)
|
|
if (ethernetInit == false)
|
|
{
|
|
{
|
|
ethernetInit = true;
|
|
ethernetInit = true;
|
|
|
|
+ COM_SetMAC();
|
|
ETH_BSP_Config();
|
|
ETH_BSP_Config();
|
|
LwIP_Init();
|
|
LwIP_Init();
|
|
sys_thread_new("HTTP", vTaskTcpServer, NULL, 4*configMINIMAL_STACK_SIZE, tskIDLE_PRIORITY);
|
|
sys_thread_new("HTTP", vTaskTcpServer, NULL, 4*configMINIMAL_STACK_SIZE, tskIDLE_PRIORITY);
|