backUp before hal firmware update
parent
1f9130adde
commit
b28818536a
|
@ -6,7 +6,7 @@
|
|||
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser"/>
|
||||
<provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="1913951426039961877" id="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="MCU ARM GCC Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="-834964856988592126" id="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="MCU ARM GCC Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||
</provider>
|
||||
|
@ -18,7 +18,7 @@
|
|||
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser"/>
|
||||
<provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="1913951426039961877" id="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="MCU ARM GCC Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="-834964856988592126" id="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" keep-relative-paths="false" name="MCU ARM GCC Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||
</provider>
|
||||
|
|
|
@ -211,15 +211,15 @@ void StartDefaultTask(void *argument)
|
|||
HAL_GPIO_WritePin(USB2_FS_ENUM_CTL_GPIO_Port,USB2_FS_ENUM_CTL_Pin, GPIO_PIN_SET);
|
||||
Beep(50);
|
||||
|
||||
osDelay(100);
|
||||
osDelay(100);
|
||||
printf("\nCore initial successfully\n");
|
||||
printf("---------------------------------------------\n");
|
||||
printf("Copyright (c) Powered by www.autolabor.com.cn\n");
|
||||
osDelay(100);
|
||||
printf("BIOS SW Version: V0.9, build: %s, %s\n",__DATE__ ,__TIME__ );
|
||||
printf("BIOS SW Version: V0.9.1, build: %s, %s\n",__DATE__ ,__TIME__ );
|
||||
printf("HAL Version: %lu \n", HAL_GetHalVersion());
|
||||
printf("Revision ID: %lu \n", HAL_GetREVID());
|
||||
printf("Device ID: %lu \n", HAL_GetDEVID());
|
||||
osDelay(100);
|
||||
printf("Chip UID: %lu%lu%lu \n", HAL_GetUIDw0(),HAL_GetUIDw1(),HAL_GetUIDw2);
|
||||
printf("----------------------------------------------\n");
|
||||
|
||||
|
@ -529,6 +529,11 @@ void StartPowerMonitTask(void *argument)
|
|||
// printf("bkp_bat: %f \n",NaviKit.pmb.bkp_bat_div8);
|
||||
// printf("main_pwr: %f \n",NaviKit.pmb.main_pwr_div16);
|
||||
|
||||
if(NaviKit.pmb.rails.main_pwr < 19)
|
||||
{
|
||||
Beep(50);
|
||||
}
|
||||
|
||||
}
|
||||
/* USER CODE END StartPowerMonitTask */
|
||||
}
|
||||
|
@ -552,17 +557,16 @@ void StartUartQueueTask(void *argument)
|
|||
/* Infinite loop */
|
||||
for(;;)
|
||||
{
|
||||
osDelay(1);
|
||||
osDelay(2);
|
||||
count = osMessageQueueGetCount(uartQueueHandle);
|
||||
if(count){
|
||||
for(uint32_t i=0;i<count;i++){
|
||||
osMessageQueueGet(uartQueueHandle,&temp[i],0,10);
|
||||
uint32_t space = osMessageQueueGetSpace(uartQueueHandle);
|
||||
}
|
||||
// taskENTER_CRITICAL();
|
||||
taskENTER_CRITICAL();
|
||||
while(HAL_UART_GetState(&huart1) == HAL_UART_STATE_BUSY_TX){}
|
||||
HAL_UART_Transmit(&huart1,(uint8_t *)&temp,count,0xffff);
|
||||
// taskEXIT_CRITICAL();
|
||||
taskEXIT_CRITICAL();
|
||||
}
|
||||
}
|
||||
/* USER CODE END StartUartQueueTask */
|
||||
|
@ -586,15 +590,13 @@ PUTCHAR_PROTOTYPE
|
|||
// HAL_UART_Transmit(&huart1,(uint8_t *)&ch,1,0xffff);
|
||||
|
||||
//queue space check before enqueue
|
||||
uint32_t space = osMessageQueueGetSpace(uartQueueHandle);
|
||||
if(space){
|
||||
if(osMessageQueueGetSpace(uartQueueHandle)){
|
||||
osMessageQueuePut(uartQueueHandle,(uint8_t*)&ch,0,10);
|
||||
space = osMessageQueueGetSpace(uartQueueHandle);
|
||||
}
|
||||
else{
|
||||
// uint8_t front[1];//trash
|
||||
// osMessageQueueGet(uartQueueHandle,front,0,10);
|
||||
// osMessageQueuePut(uartQueueHandle,(uint8_t *)&ch,0,100);
|
||||
uint8_t front[1];//trash
|
||||
osMessageQueueGet(uartQueueHandle,front,0,10);
|
||||
osMessageQueuePut(uartQueueHandle,(uint8_t *)&ch,0,100);
|
||||
}
|
||||
return ch;
|
||||
}
|
||||
|
|
|
@ -99,7 +99,7 @@ int main(void)
|
|||
MX_GPIO_Init();
|
||||
MX_DMA_Init();
|
||||
MX_I2C1_Init();
|
||||
MX_IWDG_Init();
|
||||
// MX_IWDG_Init();
|
||||
MX_UART4_Init();
|
||||
MX_ADC1_Init();
|
||||
MX_USART1_UART_Init();
|
||||
|
|
|
@ -34,7 +34,7 @@ void HAL_ADC_ConvCpltCallback(ADC_HandleTypeDef* hadc)
|
|||
// NaviKit.pmb.rails.main_pwr = (float)((NaviKit.pmb.rails.adc[5]*16.0) / 1241.21);
|
||||
|
||||
|
||||
float adc_17_voltage = 1.2 / NaviKit.pmb.rails.adc[1];
|
||||
float adc_17_voltage = 1.2 / NaviKit.pmb.rails.adc[1];//reference voltage
|
||||
|
||||
NaviKit.pmb.rails.out_24v = (float)(adc_17_voltage * NaviKit.pmb.rails.adc[2] * 16);
|
||||
NaviKit.pmb.rails.out_5v = (float)(adc_17_voltage * NaviKit.pmb.rails.adc[3] * 8);
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
<intAttribute key="com.st.stm32cube.ide.mcu.debug.launch.formatVersion" value="2"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.ip_address_local" value="localhost"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.loadList" value="{"fItems":[{"fIsFromMainTab":true,"fPath":"Debug\\NaviKit_stm32.elf","fProjectName":"NaviKit_stm32","fPerformBuild":true,"fDownload":true,"fLoadSymbols":true}]}"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.override_start_address_mode" value="default"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.remoteCommand" value="target remote"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.startServer" value="true"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.startuptab.exception.divby0" value="true"/>
|
||||
|
@ -17,6 +18,7 @@
|
|||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_trace_hclk" value="16000000"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.swv_wait_for_sync" value="true"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.useRemoteTarget" value="true"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.launch.vector_table" value=""/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.launch.verify_flash_download" value="true"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.openocd.DBG_DEVICE_SHAREABLE_ALLOWED" value="false"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.openocd.DBG_INTERFACE" value="Swd"/>
|
||||
|
@ -46,6 +48,8 @@
|
|||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.stlink_check_serial_number" value="false"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.stlink_txt_serial_number" value=""/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.watchdog_config" value="enable"/>
|
||||
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlinkrestart_configurations" value="{"fItems":[{"fDisplayName":"Reset","fIsSuppressible":false,"fResetAttribute":"Reset","fResetStrategies":[{"fDisplayName":"Reset","fLaunchAttribute":"monitor reset","fGdbCommands":["monitor reset"],"fCmdOptions":[]},{"fDisplayName":"None","fLaunchAttribute":"no_reset","fGdbCommands":[],"fCmdOptions":[]}],"fGdbCommandGroup":{"name":"Additional commands","commands":[]}}]}"/>
|
||||
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.swv.swv_wait_for_sync" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doHalt" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.doReset" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.initCommands" value=""/>
|
||||
|
@ -58,7 +62,7 @@
|
|||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
|
||||
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="${TOOLCHAIN_PATH}/arm-none-eabi-gdb"/>
|
||||
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="arm-none-eabi-gdb"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.NON_STOP" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
|
||||
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
|
||||
|
@ -76,6 +80,8 @@
|
|||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
|
||||
<listEntry value="4"/>
|
||||
</listAttribute>
|
||||
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList context="reserved-for-future-use"/> "/>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_id" value="org.eclipse.cdt.debug.core.sourceLocator"/>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_memento" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <sourceLookupDirector> <sourceContainers duplicates="false"> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;default/&gt;&#13;&#10;" typeId="org.eclipse.debug.core.containerType.default"/> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;mapping backend_enabled=&quot;true&quot; name=&quot;Found Mappings&quot;&gt;&#13;&#10;&lt;mapEntry memento=&quot;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot; standalone=&amp;quot;no&amp;quot;?&amp;gt;&amp;#13;&amp;#10;&amp;lt;mapEntry backendPath=&amp;quot;E:/source/NaviKit_stm32/Debug/../Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM3/&amp;quot; localPath=&amp;quot;E:\source\STM32CubeIDE\NaviKit_stm32\Middlewares\Third_Party\FreeRTOS\Source\portable\GCC\ARM_CM3\&amp;quot;/&amp;gt;&amp;#13;&amp;#10;&quot;/&gt;&#13;&#10;&lt;mapEntry memento=&quot;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot; standalone=&amp;quot;no&amp;quot;?&amp;gt;&amp;#13;&amp;#10;&amp;lt;mapEntry backendPath=&amp;quot;E:/source/NaviKit_stm32/Debug/../Core/Startup/&amp;quot; localPath=&amp;quot;E:\source\STM32CubeIDE\NaviKit_stm32\Core\Startup\&amp;quot;/&amp;gt;&amp;#13;&amp;#10;&quot;/&gt;&#13;&#10;&lt;/mapping&gt;&#13;&#10;" typeId="org.eclipse.cdt.debug.core.containerType.mapping"/> </sourceContainers> </sourceLookupDirector> "/>
|
||||
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList context="reserved-for-future-use"> <gdbmemoryBlockExpression address="536936416" label="0x2000ffe0"/> <gdbmemoryBlockExpression address="536876872" label="0x20001748"/> <gdbmemoryBlockExpression address="136314880" label="0x08200000"/> </memoryBlockExpressionList> "/>
|
||||
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
|
||||
</launchConfiguration>
|
||||
|
|
Loading…
Reference in New Issue