修改休眠逻辑,现在是假休眠MCU并没有进入休眠现在有8ma的底电流
| | |
| | | I (include\drivers\mk_io.h)(0x680D9C68)
|
| | | F (.\sn74hc595.h)(0x680D9C68)()
|
| | | F (.\mk_4G.h)(0x680D9C68)()
|
| | | F (.\include\drivers\PCA9555.c)(0x680D9C68)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/drivers -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/pca9555.o -MD)
|
| | | F (.\include\drivers\PCA9555.c)(0x6810734D)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/drivers -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/pca9555.o -MD)
|
| | | I (include\drivers\PCA9555.h)(0x680D9C68)
|
| | | I (include\board\board.h)(0x680D9C68)
|
| | | I (include\drivers\mk_common.h)(0x680D9C68)
|
| | |
| | | I (D:\keil\ARM\ARMCLANG\include\stdarg.h)(0x5DDFFD72)
|
| | | I (include\drivers\mk_gpio.h)(0x680D9C68)
|
| | | I (include\drivers\Usart.h)(0x680D9C68)
|
| | | F (.\include\main\main.c)(0x680F5539)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/board -I ../keil -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/main.o -MD)
|
| | | F (.\include\main\main.c)(0x68107D3A)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/board -I ../keil -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/main.o -MD)
|
| | | I (include\drivers\mk_trace.h)(0x680D9C68)
|
| | | I (include\drivers\mk_common.h)(0x680D9C68)
|
| | | I (D:\keil\ARM\ARMCLANG\include\stddef.h)(0x5DDFFD72)
|
| | |
| | | I (include\drivers\PCA9555.h)(0x680D9C68)
|
| | | I (include\drivers\WS2812.h)(0x680D9C68)
|
| | | I (include\drivers\DBG.h)(0x680D9C68)
|
| | | F (.\include\src\TCPClient.c)(0x680D9C68)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/board -I ../keil -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/tcpclient.o -MD)
|
| | | F (.\include\src\TCPClient.c)(0x681076F3)(-xc -std=c99 --target=arm-arm-none-eabi -mcpu=cortex-m0 -c
-fno-rtti -funsigned-char
-D__MICROLIB -gdwarf-3 -O3 -ffunction-sections -w -I ./include/board -I ../keil -I .. -I ./include/board -I ./include/CMSIS/Include -I ./include/components/algo/inc -I ./include/components/crc -I ./include/components/libc -I ./include/components/wsf/include -I ./include/components/wsf/include/platform -I ./include/devices/MK800X/Include -I ./include/drivers -I ./include/components/hido/Include -I ./include/components/internet/inc -I ./include/components/hal -I ../keil -I ./include/src -I ./include/components/internet/src -Wno-declaration-after-statement -Wno-double-promotion -Wno-extra-semi-stmt -Wno-gnu-zero-variadic-macro-arguments -Wno-padded -Wno-unused-parameter
-I./RTE/_MK8000_Release
-ID:/keil/pack/MKSEMI/MK800X_DFP/1.0.3/Device/Include
-ID:/keil/ARM/CMSIS/Include
-D__UVISION_VERSION="530" -D_RTE_ -DUWB_EN -DSTD_LIBC
-o ./objects/tcpclient.o -MD)
|
| | | I (include\src\TCPClient.h)(0x680D9C68)
|
| | | I (include\components\hido\Include\HIDO_TYpeDef.h)(0x680D9C68)
|
| | | I (include\components\internet\inc\Socket.h)(0x680D9C68)
|
| | |
| | | PCA9555_Set_One_Value_Config(AIR780E_ENBALE,0);//é
ç½®4Gä¾çµ |
| | | PCA9555_Set_One_Value_Output(AIR780E_ENBALE,1);//æå¼4G |
| | | |
| | | PCA9555_Set_One_Value_Config(MAIN_RI,0);//é
ç½®4Gå¤éå¼è为è¾å
¥ |
| | | PCA9555_Set_One_Value_Output(MAIN_RI,1); |
| | | // PCA9555_Set_One_Value_Config(MAIN_RI,0);//é
ç½®4Gå¤éå¼è为è¾å
¥ |
| | | // PCA9555_Set_One_Value_Output(MAIN_RI,1); |
| | | // PCA9555_Set_One_Value_Config(SOS_ENBALE,1);//设置SOSæé®è¾å
¥ |
| | | |
| | | PCA9555_Set_One_Value_Config(WAKE_UP,1); |
| | | PCA9555_Set_One_Value_Config(TTS_ENABLE,0);//é
ç½®ttsä¾çµ |
| | | // PCA9555_Set_One_Value_Config(TTS_ENABLE,0);//é
ç½®ttsä¾çµ |
| | | // PCA9555_Set_One_Value_Output(PWR_ON,0);//æä½ |
| | | //PCA9555_readdata_from_output_register(PCA9555_DEVICE_ADDR,pca9555writedata_input); |
| | | //PCA9555_Set_One_Value_Output(AIR780E_ENBALE,0); |
| | |
| | | } |
| | | |
| | | extern float nomove_count; |
| | | extern uint8_t deep_sleep_falg; |
| | | |
| | | void move_handler() |
| | | { |
| | | nomove_count=0; |
| | | |
| | | nomove_count=0; |
| | | if(deep_sleep_falg==0) |
| | | { |
| | | deep_sleep_falg=1; |
| | | // sleep_timer_start(); |
| | | NVIC_SystemReset(); |
| | | } |
| | | } |
| | | uint8_t test11,test21,test31,test41,test51; |
| | | void check_input_change(void) |
| | |
| | | if(WAKE_UP_POSITION&gpio_state) |
| | | { |
| | | //ç§»å¨ |
| | | move_handler(); |
| | | nomove_count=0; |
| | | if(deep_sleep_falg==0) |
| | | { |
| | | deep_sleep_falg=1; |
| | | NVIC_SystemReset(); |
| | | sys_reset(0); |
| | | } |
| | | // |
| | | test51++; |
| | | } |
| | | // if(!(MAIN_RI_POSITION&gpio_state)) |
| | |
| | | //#define DEBUG_MODE |
| | | extern int simple_main(void); |
| | | extern int temp_main(void); |
| | | void boot_deinit(void); |
| | | #define TEST_UART_POLL_MODE 0 |
| | | #define TEST_UART_INTERUPT_MODE 1 |
| | | #define TEST_UART_DMA_MODE 2 |
| | |
| | | { |
| | | uart_receive(UART_ID1,m_EUART_DMA_RXBuf,EUART_RX_BUF_SIZE,uart_receive_callback); |
| | | } |
| | | uint8_t deep_sleep_falg=1; |
| | | void mcu_deep_sleep(void) |
| | | { |
| | | uint32_t lock; |
| | | trace_flush(); |
| | | lock = int_lock(); |
| | | // LOG_INFO(TRACE_MODULE_APP, "è¿å
¥æ·±åº¦ä¼ç \r\n"); |
| | | // uint32_t lock; |
| | | // trace_flush(); |
| | | // lock = int_lock(); |
| | | //// LOG_INFO(TRACE_MODULE_APP, "è¿å
¥æ·±åº¦ä¼ç \r\n"); |
| | | // gps_air780_power_change(0,0);//å
³égpsï¼4G |
| | | deep_sleep_falg=0; |
| | | PCA9555_Set_One_Value_Output(LED_POWER,0);//è¾åºä½çµå¹³å
³éLED |
| | | PCA9555_Set_One_Value_Output(GPS_POWER,0);//å
³égpsï¼4G |
| | | PCA9555_Set_One_Value_Config(MAIN_RI,0);//é
ç½®4Gå¤éå¼è为è¾å
¥ |
| | | // PCA9555_Set_One_Value_Output(MAIN_RI,1); |
| | | boot_deinit(); |
| | | CloseUWB(); |
| | | PCA9555_Set_One_Value_Output(AIR780E_ENBALE,0);//å
³égpsï¼4G |
| | | sleep_timer_stop(); |
| | | //adc_close(); |
| | | power_enter_power_down_mode(1); |
| | | // LOG_INFO(TRACE_MODULE_APP, "ä»ä¼ç åºæ¥\r\n"); |
| | | sys_reset(0); |
| | | int_unlock(lock); |
| | | |
| | | // sleep_timer_stop(); |
| | | // //adc_close(); |
| | | // power_enter_power_down_mode(1); |
| | | // delay_us(200000); |
| | | |
| | | // sys_reset(0); |
| | | //// LOG_INFO(TRACE_MODULE_APP, "ä»ä¼ç åºæ¥\r\n"); |
| | | // int_unlock(lock); |
| | | } |
| | | static void adc_callback(void *data, uint32_t number) |
| | | { |
| | |
| | | g_com_map[CNT_RESTART]=0; |
| | | save_com_map_to_flash(); |
| | | NVIC_SystemReset(); |
| | | LOG_INFO(TRACE_MODULE_APP,"1111"); |
| | | |
| | | } |
| | | } |
| | | else |
| | |
| | | } |
| | | } |
| | | NVIC_SystemReset(); |
| | | LOG_INFO(TRACE_MODULE_APP,"2222"); |
| | | input5vflag=1; |
| | | } |
| | | else |
| | |
| | | { |
| | | g_com_map[CNT_RESTART]=0; |
| | | NVIC_SystemReset(); |
| | | LOG_INFO(TRACE_MODULE_APP,"3333"); |
| | | |
| | | } |
| | | if(g_com_map[MAP_SIGN_INDEX]!=0x55AA||g_com_map[COM_INTERVAL]==0) |
| | | { |
| | | NVIC_SystemReset(); |
| | | LOG_INFO(TRACE_MODULE_APP,"4444"); |
| | | } |
| | | HIDO_TimerPoll(); |
| | | if(ledonflag==1) |
| | |
| | | // UART0 TX/RX |
| | | io_pin_mux_set(IO_PIN_5, IO_FUNC0); |
| | | io_pin_mux_set(IO_PIN_6, IO_FUNC0); |
| | | gpio_pin_set_dir(IO_PIN_5 , GPIO_DIR_OUT, 0); |
| | | gpio_pin_set_dir(IO_PIN_6 , GPIO_DIR_OUT, 0); |
| | | // UART1 RX/TX |
| | | io_pin_mux_set(IO_PIN_10, IO_FUNC0); |
| | | io_pin_mux_set(IO_PIN_9, IO_FUNC0); |
| | | |
| | | uart_close(UART_ID1);//è§£ç»åæ¥ä¸²å£1 |
| | | uart_close(UART_ID0);//è§£ç»åæ¥ä¸²å£0 |
| | | } |
| | |
| | | char str[17]= {"AT+IPR=9600;&W\r\n"}; |
| | | void AIR780E_Reset(void) |
| | | { |
| | | PCA9555_Set_One_Value_Output(AIR780E_ENBALE,0);//å
³é4G |
| | | delay_ms(1500); |
| | | PCA9555_Set_One_Value_Output(AIR780E_ENBALE,1);//æå¼4G |
| | | delay_ms(3000); |
| | | // PCA9555_Set_One_Value_Output(AIR780E_ENBALE,0);//å
³é4G |
| | | // delay_ms(1500); |
| | | // PCA9555_Set_One_Value_Output(AIR780E_ENBALE,1);//æå¼4G |
| | | // delay_ms(3000); |
| | | // Uart_ReConfigBaudRate(UART_ID_4G,115200); |
| | | // uart_send(UART_ID0, str,17, NULL); |
| | | // Uart_ReConfigBaudRate(UART_ID_4G,9600); |
| | |
| | | <Name></Name> |
| | | </SetRegEntry> |
| | | </TargetDriverDllRegistry> |
| | | <Breakpoint/> |
| | | <Breakpoint> |
| | | <Bp> |
| | | <Number>0</Number> |
| | | <Type>0</Type> |
| | | <LineNumber>659</LineNumber> |
| | | <EnabledFlag>1</EnabledFlag> |
| | | <Address>59804</Address> |
| | | <ByteObject>0</ByteObject> |
| | | <HtxType>0</HtxType> |
| | | <ManyObjects>0</ManyObjects> |
| | | <SizeOfObject>0</SizeOfObject> |
| | | <BreakByAccess>0</BreakByAccess> |
| | | <BreakIfRCount>1</BreakIfRCount> |
| | | <Filename><1>.\include\main\main.c</Filename> |
| | | <ExecCommand></ExecCommand> |
| | | <Expression>\\uwb_simple_example\include/main/main.c\659</Expression> |
| | | </Bp> |
| | | </Breakpoint> |
| | | <WatchWindow1> |
| | | <Ww> |
| | | <count>0</count> |
| | |
| | | <WinNumber>2</WinNumber> |
| | | <ItemText>dev_id</ItemText> |
| | | </Ww> |
| | | <Ww> |
| | | <count>11</count> |
| | | <WinNumber>2</WinNumber> |
| | | <ItemText>nomove_count</ItemText> |
| | | </Ww> |
| | | <Ww> |
| | | <count>12</count> |
| | | <WinNumber>2</WinNumber> |
| | | <ItemText>deep_sleep_falg</ItemText> |
| | | </Ww> |
| | | </WatchWindow2> |
| | | <MemoryWindow1> |
| | | <Mm> |