#ifndef __MAIN_H #define __MAIN_H #define VER_HIGH_VALUE 1 #define VER_LOW_VALUE 1 #define BATTERY_LOW_LEVEL 23 #define IES200_1ST_MAC 0x44 #define IES200_2ST_MAC 0x33 #define IES200_3ST_MAC 0xC0 #define BUTTON_NONE 0 #define BUTTON_EMG 1 #define BUTTON_TEST 2 #define BUTTON_REG 3 #define BUTTON_ALIVE 5 #define BUZZER_NONE 0 #define BUZZER_EMG 1 #define BUZZER_TEST 2 #define BUZZER_REG 3 #define BUZZER_BOOT_LOADER 4 #define BUZZER_POWER_ON 5 #define COMMAND_LENGTH 17 #define COMMAND_TYPE 0x74 #define COMMAND_EMG 0x01 #define COMMAND_TEST 0x02 #define COMMAND_ALIVE 0x04 #define COMMAND_REG 0x03 #define RUN_TIME_LIMIT 10000 //10sec //#define SLEEP_WDT_LIMIT 4000000000 // 4000000000/1000 = 4000000sec 4000000/60/60/24/ = 46days //#define SLEEP_WDT_LIMIT 1*60*60*1000+1*60*1000 // 2*60*60*1000/1000 = 6Hour void advertising_start(void); extern uint8_t advertising_flag; #endif