canbus adding filters

This commit is contained in:
2022-01-20 12:39:41 +01:00
parent 852f344c7f
commit fd665a9d94
16 changed files with 768 additions and 326 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
Debug/** Debug/**
Debug/ Debug/
build/
/Release/ /Release/

View File

@ -6,7 +6,7 @@
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/> <provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" 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 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="557024645362649502" 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 &quot;${INPUTS}&quot;" prefer-non-shared="true"> <provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="-54795925002487172" 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 &quot;${INPUTS}&quot;" prefer-non-shared="true">
<language-scope id="org.eclipse.cdt.core.gcc"/> <language-scope id="org.eclipse.cdt.core.gcc"/>
<language-scope id="org.eclipse.cdt.core.g++"/> <language-scope id="org.eclipse.cdt.core.g++"/>
</provider> </provider>
@ -18,7 +18,7 @@
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/> <provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" 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 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="557024645362649502" 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 &quot;${INPUTS}&quot;" prefer-non-shared="true"> <provider class="com.st.stm32cube.ide.mcu.toolchain.armnone.setup.CrossBuiltinSpecsDetector" console="false" env-hash="-54795925002487172" 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 &quot;${INPUTS}&quot;" prefer-non-shared="true">
<language-scope id="org.eclipse.cdt.core.gcc"/> <language-scope id="org.eclipse.cdt.core.gcc"/>
<language-scope id="org.eclipse.cdt.core.g++"/> <language-scope id="org.eclipse.cdt.core.g++"/>
</provider> </provider>

View File

@ -1,5 +1,5 @@
2F62501ED4689FB349E356AB974DBE57=3C8163665DC52502E88D788B0CED9B35 2F62501ED4689FB349E356AB974DBE57=E4D6F48A5E072BF280AE61DC22F0EFF9
66BE74F758C12D739921AEA421D593D3=4 66BE74F758C12D739921AEA421D593D3=4
8DF89ED150041C4CBC7CB9A9CAA90856=3C8163665DC52502E88D788B0CED9B35 8DF89ED150041C4CBC7CB9A9CAA90856=E4D6F48A5E072BF280AE61DC22F0EFF9
DC22A860405A8BF2F2C095E5B6529F12=3C6A73657F8CAB85FF62A66955B31FC6 DC22A860405A8BF2F2C095E5B6529F12=F216BE080F2C17807F72AFE2348FF317
eclipse.preferences.version=1 eclipse.preferences.version=1

24
.vscode/c_cpp_properties.json vendored Normal file
View File

@ -0,0 +1,24 @@
{
"configurations": [
{
"name": "STM32",
"includePath": [
"Core",
"Core/Application",
"Core/Drivers",
"Core/Inc",
"Core/Toolbox",
"Drivers/CMSIS/Device/ST/STM32L4xx/Include",
"Drivers/CMSIS/Include",
"Drivers/STM32L4xx_HAL_Driver/Inc",
"Drivers/STM32L4xx_HAL_Driver/Inc/Legacy",
"Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2",
"Middlewares/Third_Party/FreeRTOS/Source/include",
"Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM4F"
],
"defines": [],
"compilerPath": "/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/arm-none-eabi-gcc/10.3.1-2.3.1/.content/bin/arm-none-eabi-gcc"
}
],
"version": 4
}

18
.vscode/launch.json vendored Normal file
View File

@ -0,0 +1,18 @@
{
"configurations": [
{
"showDevDebugOutput": true,
"cwd": "${workspaceRoot}",
"executable": "./build/.elf",
"name": "Debug STM32",
"request": "launch",
"type": "cortex-debug",
"servertype": "openocd",
"preLaunchTask": "Build STM",
"device": "stlink",
"configFiles": [
"openocd.cfg"
]
}
]
}

View File

@ -1,5 +1,8 @@
{ {
"C_Cpp.errorSquiggles": "Disabled", "C_Cpp.errorSquiggles": "Disabled",
"cortex-debug.armToolchainPath": "/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/arm-none-eabi-gcc/10.3.1-2.3.1/.content/bin", "cortex-debug.armToolchainPath": "/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/arm-none-eabi-gcc/10.3.1-2.3.1/.content/bin",
"cortex-debug.openocdPath": "/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/openocd/0.11.0-2.1/.content/bin/openocd" "cortex-debug.openocdPath": "/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/openocd/0.11.0-2.1/.content/bin/openocd",
"files.associations": {
"peco_peltiercontroller.h": "c"
}
} }

50
.vscode/tasks.json vendored Normal file
View File

@ -0,0 +1,50 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "Build STM",
"type": "process",
"command": "${command:stm32-for-vscode.build}",
"options": {
"cwd": "${workspaceRoot}"
},
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [
"$gcc"
]
},
{
"label": "Build Clean STM",
"type": "process",
"command": "${command:stm32-for-vscode.cleanBuild}",
"options": {
"cwd": "${workspaceRoot}"
},
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [
"$gcc"
]
},
{
"label": "Flash STM",
"type": "process",
"command": "${command:stm32-for-vscode.flash}",
"options": {
"cwd": "${workspaceRoot}"
},
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": [
"$gcc"
]
}
]
}

View File

@ -57,17 +57,17 @@
// Description: Definition of local constants (visible by this module only). // Description: Definition of local constants (visible by this module only).
//================================================================================================= //=================================================================================================
#define SLOW_TEXT (U32)0x83767987
#define FAST_TEXT (U32)0x46415354
#define MSG_QUEUE_SIZE 8 #define MSG_QUEUE_SIZE 8
#define EVENT_NEW_MESSAGE ((U32)(1<<0)) #define EVENT_NEW_MESSAGE ((U32)(1<<0))
#define EVENT_TIMER_UPDATE ((U32)(1<<1)) #define EVENT_TIMER_UPDATE ((U32)(1<<1))
#define EVENT_FLAGS_ALL ( EVENT_NEW_MESSAGE | EVENT_TIMER_UPDATE ) #define EVENT_FLAGS_ALL ( EVENT_NEW_MESSAGE | EVENT_TIMER_UPDATE )
#define MESSAGE_TYPE_READ 0
#define MESSAGE_TYPE_WRITE 1
#define MESSAGE_TYPE_COMMAND 2
//================================================================================================= //=================================================================================================
// Section: MACROS // Section: MACROS
// Description: Definition of local macros (visible by this module only). // Description: Definition of local macros (visible by this module only).
@ -107,13 +107,8 @@ LOCAL osThreadId_t m_pstThreadID = NULL;
LOCAL osMessageQueueId_t m_pstCANRxMsgQueueID = NULL; LOCAL osMessageQueueId_t m_pstCANRxMsgQueueID = NULL;
LOCAL osEventFlagsId_t m_pstEventID = NULL; LOCAL osEventFlagsId_t m_pstEventID = NULL;
LOCAL osTimerId_t m_pstUpdateTimer = NULL; LOCAL osTimerId_t m_pstUpdateTimer = NULL;
LOCAL U32 m_u32DataCnt = 0;
//================================================================================================= //=================================================================================================
// Section: LOCAL CONSTANTS // Section: LOCAL CONSTANTS
// Description: Definition of local constants (visible by this module only). // Description: Definition of local constants (visible by this module only).
@ -230,15 +225,19 @@ PRIVATE VOID vTask( PVOID arg )
// TODO: implement new protocol // TODO: implement new protocol
CAND_Message stMessage; CAND_Message stMessage;
osMessageQueueGet( m_pstCANRxMsgQueueID, &stMessage, NULL, 0 ); osMessageQueueGet( m_pstCANRxMsgQueueID, &stMessage, NULL, 0 );
U8 u8Register = stMessage.au8Data[0];
U8 u8Typ = stMessage.au8Data[1];
U32 u32Data = *(PU32)&stMessage.au8Data[2];
if( stMessage.u8Id == 0x12 ){ if( u8Register == 0x12 ){
S16 s16Voltage = stMessage.au8Data[0] << 8; S16 s16Voltage = stMessage.au8Data[0] << 8;
s16Voltage |= stMessage.au8Data[1]; s16Voltage |= stMessage.au8Data[1];
VARH_vSetVariableDataFloat( VARH_eControlVoltage, (FLOAT)s16Voltage / 1000 ); VARH_vSetVariableDataFloat( VARH_eControlVoltage, (FLOAT)s16Voltage / 1000 );
} else if( stMessage.u8Id == 0x13 ){ } else if( u8Register == 0x13 ){
S16 SupplyVoltage24V = (S16) ( VARH_flGetVariableData( VARH_eSupply_U ) * 1000 ); S16 SupplyVoltage24V = (S16) ( VARH_flGetVariableData( VARH_eSupply_U ) * 1000 );
S16 SupplyCurrent24V = (S16) ( VARH_flGetVariableData( VARH_eSupply_I ) * 1000 ); S16 SupplyCurrent24V = (S16) ( VARH_flGetVariableData( VARH_eSupply_I ) * 1000 );
@ -256,7 +255,7 @@ PRIVATE VOID vTask( PVOID arg )
CAND_boSendMessage( 0x14, 8, au8Buffer ); CAND_boSendMessage( 0x14, 8, au8Buffer );
} else if( stMessage.u8Id == 0x15 ){ } else if( u8Register == 0x15 ){
S16 Cold = (S16) ( VARH_flGetVariableData( VARH_eTemp_C ) * 100 ); S16 Cold = (S16) ( VARH_flGetVariableData( VARH_eTemp_C ) * 100 );
S16 Hot = (S16) ( VARH_flGetVariableData( VARH_eTemp_H ) * 100 ); S16 Hot = (S16) ( VARH_flGetVariableData( VARH_eTemp_H ) * 100 );
@ -268,11 +267,11 @@ PRIVATE VOID vTask( PVOID arg )
CAND_boSendMessage( 0x16, 4, au8Buffer ); CAND_boSendMessage( 0x16, 4, au8Buffer );
} else if( stMessage.u8Id == 0x17 ){ } else if( u8Register == 0x17 ){
PECO_Enable( TRUE ); PECO_Enable( TRUE );
} else if( stMessage.u8Id == 0x18 ){ } else if( u8Register == 0x18 ){
PECO_Enable( FALSE ); PECO_Enable( FALSE );

View File

@ -342,7 +342,7 @@ U8 VARH_uGetVariableFlags( U8 u8Variable )
VOID VARH_vSetVariableToInitData( U8 u8Variable ) VOID VARH_vSetVariableToInitData( U8 u8Variable )
{ {
osMutexAcquire( m_pstMutexID, osWaitForever ); // aquire mutex osMutexAcquire( m_pstMutexID, osWaitForever ); // aquire mutex
VARH_vSetVariableDataFromSystem( u8Variable, m_astVarInfo[u8Variable].uInitData ); vSetVariableDataFromSystem( u8Variable, m_astVarInfo[u8Variable].uInitData );
osMutexRelease( m_pstMutexID ); // release mutex osMutexRelease( m_pstMutexID ); // release mutex
} }

View File

@ -139,9 +139,9 @@ BOOL ANPO_boInitializeModule( VOID )
BOOL ANPO_boSetVoltage( FLOAT Voltage ){ BOOL ANPO_boSetVoltage( FLOAT Voltage ){
BOOL boOK = TRUE; BOOL boOK = TRUE;
U32 RawData = u32ConvertVoltagetoRaw( Voltage ); U32 u32RawData = u32ConvertVoltagetoRaw( Voltage );
boOK &= HAL_DAC_SetValue( &hdac1, DAC_CHANNEL_1, DAC_ALIGN_12B_R, RawDatab ); boOK &= HAL_DAC_SetValue( &hdac1, DAC_CHANNEL_1, DAC_ALIGN_12B_R, u32RawData );
return( boOK ); return( boOK );
} }

View File

@ -7,7 +7,7 @@
//------------------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------------------
// //
// Project: Peltier Controller V2 // Project: Peltier Controller V2
// Author: Noah Piqu<EFBFBD> (noah.pique@psi.ch) // Author: Noah Piqué (noah.pique@psi.ch)
// //
//------------------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------------------
// //
@ -36,6 +36,9 @@
// Toolbox // Toolbox
#include "../Toolbox/UTIL_Utility.h" #include "../Toolbox/UTIL_Utility.h"
// Driver
#include "DIPO_DigitalPorts.h"
// include STM32 drivers // include STM32 drivers
#include "stm32l4xx_hal.h" #include "stm32l4xx_hal.h"
@ -46,7 +49,11 @@
// Description: Definition of local constants (visible by this module only). // Description: Definition of local constants (visible by this module only).
//================================================================================================= //=================================================================================================
#define CAND_SHIFT 0x0 // Shift address space (0-3)
#define CAND_BOARD_GROUP 0x03 // Board group (0-127 / 0x00-0x7F)
#define CAND_PRIVATE 1
#define CAND_PUBLIC 0
//================================================================================================= //=================================================================================================
// Section: MACROS // Section: MACROS
@ -61,14 +68,10 @@
//================================================================================================= //=================================================================================================
//================================================================================================= //=================================================================================================
// Section: STRUCTURES // Section: STRUCTURES
// Description: Definition of local Structures (visible by this module only). // Description: Definition of local Structures (visible by this module only).
//================================================================================================= //=================================================================================================
//================================================================================================= //=================================================================================================
@ -77,6 +80,19 @@
//================================================================================================= //=================================================================================================
CAND_pfnRxCallback m_pfnRxCallback = NULL; CAND_pfnRxCallback m_pfnRxCallback = NULL;
CAN_FilterTypeDef stFilter = {
(CAND_SHIFT<<6)|(CAND_PUBLIC<<5)|(CAND_BOARD_GROUP<<1), // FilterIdHigh
0x00, // FilterIdLow
(CAND_SHIFT<<6)|(CAND_PRIVATE<<5)|(CAND_BOARD_GROUP<<1), // FilterMaskIdHigh
0x00, // FilterMaskIdLow
CAN_FILTER_FIFO0, // FilterFIFOAssignment
0x00, // FilterBank
CAN_FILTERMODE_IDLIST, // FilterMode
CAN_FILTERSCALE_32BIT, // FilterScale
CAN_FILTER_ENABLE, // FilterActivation
0x00 // SlaveStartFilterBank
};
//================================================================================================= //=================================================================================================
// Section: LOCAL CONSTANTS // Section: LOCAL CONSTANTS
// Description: Definition of local constants (visible by this module only). // Description: Definition of local constants (visible by this module only).
@ -117,6 +133,17 @@ extern CAN_HandleTypeDef hcan1;
BOOL CAND_boInitializeModule( VOID ) BOOL CAND_boInitializeModule( VOID )
{ {
BOOL boOK = TRUE; BOOL boOK = TRUE;
U8 u8BoardId = 0x00;
u8BoardId |= DIPO_boGetInput(DIPO_eADR0) << 0;
u8BoardId |= DIPO_boGetInput(DIPO_eADR1) << 1;
u8BoardId |= DIPO_boGetInput(DIPO_eADR2) << 2;
//u8BoardId |= DIPO_boGetInput(DIPO_eADR0) << 3; // TODO: New HW
stFilter.FilterIdHigh |= u8BoardId >> 3;
stFilter.FilterIdLow |= u8BoardId << 5;
HAL_CAN_ConfigFilter(&hcan1, &stFilter);
boOK &= ( HAL_CAN_Start(&hcan1) == HAL_OK ) ? TRUE : FALSE; boOK &= ( HAL_CAN_Start(&hcan1) == HAL_OK ) ? TRUE : FALSE;
@ -161,7 +188,6 @@ BOOL CAND_boSendMessage( U8 u8Id, U8 u8Len, PU8 pu8Buffer ){
// Returns: none // Returns: none
//------------------------------------------------------------------------------------------------- //-------------------------------------------------------------------------------------------------
VOID CAND_vSetRxCallback( CAND_pfnRxCallback pfnRxCallback ){ VOID CAND_vSetRxCallback( CAND_pfnRxCallback pfnRxCallback ){
m_pfnRxCallback = pfnRxCallback; m_pfnRxCallback = pfnRxCallback;
} }
@ -188,7 +214,6 @@ void HAL_CAN_RxFifo0MsgPendingCallback( CAN_HandleTypeDef *hcan ){
CAND_Message stMessage; CAND_Message stMessage;
stMessage.u8Id = header.StdId;
stMessage.u8Len = header.DLC; stMessage.u8Len = header.DLC;
UTIL_vMemCopy( au8Data,stMessage.au8Data,stMessage.u8Len ); UTIL_vMemCopy( au8Data,stMessage.au8Data,stMessage.u8Len );

View File

@ -62,7 +62,6 @@ extern "C" {
//================================================================================================= //=================================================================================================
typedef struct { typedef struct {
U8 u8Id;
U8 au8Data[8]; U8 au8Data[8];
U8 u8Len; U8 u8Len;
} CAND_Message; } CAND_Message;

View File

@ -1,294 +1,293 @@
#MicroXplorer Configuration settings - do not modify #MicroXplorer Configuration settings - do not modify
ADC1.Channel-0\#ChannelRegularConversion=ADC_CHANNEL_6 ADC1.Channel-0\#ChannelRegularConversion=ADC_CHANNEL_6
ADC1.Channel-1\#ChannelRegularConversion=ADC_CHANNEL_16 ADC1.Channel-1\#ChannelRegularConversion=ADC_CHANNEL_16
ADC1.Channel-2\#ChannelRegularConversion=ADC_CHANNEL_7 ADC1.Channel-2\#ChannelRegularConversion=ADC_CHANNEL_7
ADC1.Channel-3\#ChannelRegularConversion=ADC_CHANNEL_15 ADC1.Channel-3\#ChannelRegularConversion=ADC_CHANNEL_15
ADC1.ContinuousConvMode=ENABLE ADC1.ContinuousConvMode=ENABLE
ADC1.DMAContinuousRequests=ENABLE ADC1.DMAContinuousRequests=ENABLE
ADC1.EOCSelection=ADC_EOC_SEQ_CONV ADC1.EOCSelection=ADC_EOC_SEQ_CONV
ADC1.IPParameters=Rank-0\#ChannelRegularConversion,Channel-0\#ChannelRegularConversion,SamplingTime-0\#ChannelRegularConversion,OffsetNumber-0\#ChannelRegularConversion,NbrOfConversionFlag,NbrOfConversion,ContinuousConvMode,DMAContinuousRequests,Rank-1\#ChannelRegularConversion,Channel-1\#ChannelRegularConversion,SamplingTime-1\#ChannelRegularConversion,OffsetNumber-1\#ChannelRegularConversion,Rank-2\#ChannelRegularConversion,Channel-2\#ChannelRegularConversion,SamplingTime-2\#ChannelRegularConversion,OffsetNumber-2\#ChannelRegularConversion,Rank-3\#ChannelRegularConversion,Channel-3\#ChannelRegularConversion,SamplingTime-3\#ChannelRegularConversion,OffsetNumber-3\#ChannelRegularConversion,EOCSelection,OversamplingMode,RightBitShift,Ratio,master ADC1.IPParameters=Rank-0\#ChannelRegularConversion,Channel-0\#ChannelRegularConversion,SamplingTime-0\#ChannelRegularConversion,OffsetNumber-0\#ChannelRegularConversion,NbrOfConversionFlag,NbrOfConversion,ContinuousConvMode,DMAContinuousRequests,Rank-1\#ChannelRegularConversion,Channel-1\#ChannelRegularConversion,SamplingTime-1\#ChannelRegularConversion,OffsetNumber-1\#ChannelRegularConversion,Rank-2\#ChannelRegularConversion,Channel-2\#ChannelRegularConversion,SamplingTime-2\#ChannelRegularConversion,OffsetNumber-2\#ChannelRegularConversion,Rank-3\#ChannelRegularConversion,Channel-3\#ChannelRegularConversion,SamplingTime-3\#ChannelRegularConversion,OffsetNumber-3\#ChannelRegularConversion,EOCSelection,OversamplingMode,RightBitShift,Ratio,master
ADC1.NbrOfConversion=4 ADC1.NbrOfConversion=4
ADC1.NbrOfConversionFlag=1 ADC1.NbrOfConversionFlag=1
ADC1.OffsetNumber-0\#ChannelRegularConversion=ADC_OFFSET_NONE ADC1.OffsetNumber-0\#ChannelRegularConversion=ADC_OFFSET_NONE
ADC1.OffsetNumber-1\#ChannelRegularConversion=ADC_OFFSET_NONE ADC1.OffsetNumber-1\#ChannelRegularConversion=ADC_OFFSET_NONE
ADC1.OffsetNumber-2\#ChannelRegularConversion=ADC_OFFSET_NONE ADC1.OffsetNumber-2\#ChannelRegularConversion=ADC_OFFSET_NONE
ADC1.OffsetNumber-3\#ChannelRegularConversion=ADC_OFFSET_NONE ADC1.OffsetNumber-3\#ChannelRegularConversion=ADC_OFFSET_NONE
ADC1.OversamplingMode=ENABLE ADC1.OversamplingMode=ENABLE
ADC1.Rank-0\#ChannelRegularConversion=1 ADC1.Rank-0\#ChannelRegularConversion=1
ADC1.Rank-1\#ChannelRegularConversion=2 ADC1.Rank-1\#ChannelRegularConversion=2
ADC1.Rank-2\#ChannelRegularConversion=3 ADC1.Rank-2\#ChannelRegularConversion=3
ADC1.Rank-3\#ChannelRegularConversion=4 ADC1.Rank-3\#ChannelRegularConversion=4
ADC1.Ratio=ADC_OVERSAMPLING_RATIO_256 ADC1.Ratio=ADC_OVERSAMPLING_RATIO_256
ADC1.RightBitShift=ADC_RIGHTBITSHIFT_4 ADC1.RightBitShift=ADC_RIGHTBITSHIFT_4
ADC1.SamplingTime-0\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5 ADC1.SamplingTime-0\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5
ADC1.SamplingTime-1\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5 ADC1.SamplingTime-1\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5
ADC1.SamplingTime-2\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5 ADC1.SamplingTime-2\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5
ADC1.SamplingTime-3\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5 ADC1.SamplingTime-3\#ChannelRegularConversion=ADC_SAMPLETIME_640CYCLES_5
ADC1.master=1 ADC1.master=1
CAN1.BS1=CAN_BS1_3TQ CAN1.BS1=CAN_BS1_3TQ
CAN1.CalculateBaudRate=1000000 CAN1.CalculateBaudRate=1000000
CAN1.CalculateTimeBit=1000.00 CAN1.CalculateTimeBit=1000
CAN1.CalculateTimeQuantum=200.0 CAN1.CalculateTimeQuantum=200.0
CAN1.IPParameters=CalculateTimeQuantum,CalculateTimeBit,CalculateBaudRate,BS1,Prescaler CAN1.IPParameters=CalculateTimeQuantum,CalculateTimeBit,CalculateBaudRate,BS1,Prescaler
CAN1.Prescaler=16 CAN1.Prescaler=16
Dma.ADC1.2.Direction=DMA_PERIPH_TO_MEMORY Dma.ADC1.2.Direction=DMA_PERIPH_TO_MEMORY
Dma.ADC1.2.Instance=DMA2_Channel3 Dma.ADC1.2.Instance=DMA2_Channel3
Dma.ADC1.2.MemDataAlignment=DMA_MDATAALIGN_HALFWORD Dma.ADC1.2.MemDataAlignment=DMA_MDATAALIGN_HALFWORD
Dma.ADC1.2.MemInc=DMA_MINC_ENABLE Dma.ADC1.2.MemInc=DMA_MINC_ENABLE
Dma.ADC1.2.Mode=DMA_CIRCULAR Dma.ADC1.2.Mode=DMA_CIRCULAR
Dma.ADC1.2.PeriphDataAlignment=DMA_PDATAALIGN_HALFWORD Dma.ADC1.2.PeriphDataAlignment=DMA_PDATAALIGN_HALFWORD
Dma.ADC1.2.PeriphInc=DMA_PINC_DISABLE Dma.ADC1.2.PeriphInc=DMA_PINC_DISABLE
Dma.ADC1.2.Priority=DMA_PRIORITY_HIGH Dma.ADC1.2.Priority=DMA_PRIORITY_HIGH
Dma.ADC1.2.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority Dma.ADC1.2.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority
Dma.Request0=SPI1_RX Dma.Request0=SPI1_RX
Dma.Request1=SPI1_TX Dma.Request1=SPI1_TX
Dma.Request2=ADC1 Dma.Request2=ADC1
Dma.RequestsNb=3 Dma.RequestsNb=3
Dma.SPI1_RX.0.Direction=DMA_PERIPH_TO_MEMORY Dma.SPI1_RX.0.Direction=DMA_PERIPH_TO_MEMORY
Dma.SPI1_RX.0.Instance=DMA1_Channel2 Dma.SPI1_RX.0.Instance=DMA1_Channel2
Dma.SPI1_RX.0.MemDataAlignment=DMA_MDATAALIGN_BYTE Dma.SPI1_RX.0.MemDataAlignment=DMA_MDATAALIGN_BYTE
Dma.SPI1_RX.0.MemInc=DMA_MINC_ENABLE Dma.SPI1_RX.0.MemInc=DMA_MINC_ENABLE
Dma.SPI1_RX.0.Mode=DMA_NORMAL Dma.SPI1_RX.0.Mode=DMA_NORMAL
Dma.SPI1_RX.0.PeriphDataAlignment=DMA_PDATAALIGN_BYTE Dma.SPI1_RX.0.PeriphDataAlignment=DMA_PDATAALIGN_BYTE
Dma.SPI1_RX.0.PeriphInc=DMA_PINC_DISABLE Dma.SPI1_RX.0.PeriphInc=DMA_PINC_DISABLE
Dma.SPI1_RX.0.Priority=DMA_PRIORITY_LOW Dma.SPI1_RX.0.Priority=DMA_PRIORITY_LOW
Dma.SPI1_RX.0.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority Dma.SPI1_RX.0.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority
Dma.SPI1_TX.1.Direction=DMA_MEMORY_TO_PERIPH Dma.SPI1_TX.1.Direction=DMA_MEMORY_TO_PERIPH
Dma.SPI1_TX.1.Instance=DMA1_Channel3 Dma.SPI1_TX.1.Instance=DMA1_Channel3
Dma.SPI1_TX.1.MemDataAlignment=DMA_MDATAALIGN_BYTE Dma.SPI1_TX.1.MemDataAlignment=DMA_MDATAALIGN_BYTE
Dma.SPI1_TX.1.MemInc=DMA_MINC_ENABLE Dma.SPI1_TX.1.MemInc=DMA_MINC_ENABLE
Dma.SPI1_TX.1.Mode=DMA_NORMAL Dma.SPI1_TX.1.Mode=DMA_NORMAL
Dma.SPI1_TX.1.PeriphDataAlignment=DMA_PDATAALIGN_BYTE Dma.SPI1_TX.1.PeriphDataAlignment=DMA_PDATAALIGN_BYTE
Dma.SPI1_TX.1.PeriphInc=DMA_PINC_DISABLE Dma.SPI1_TX.1.PeriphInc=DMA_PINC_DISABLE
Dma.SPI1_TX.1.Priority=DMA_PRIORITY_LOW Dma.SPI1_TX.1.Priority=DMA_PRIORITY_LOW
Dma.SPI1_TX.1.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority Dma.SPI1_TX.1.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority
FREERTOS.FootprintOK=true FREERTOS.FootprintOK=true
FREERTOS.IPParameters=Tasks01,FootprintOK,configTOTAL_HEAP_SIZE,configUSE_NEWLIB_REENTRANT FREERTOS.IPParameters=Tasks01,FootprintOK,configTOTAL_HEAP_SIZE,configUSE_NEWLIB_REENTRANT
FREERTOS.Tasks01=Default,24,128,vDefaultTask,Default,NULL,Dynamic,NULL,NULL FREERTOS.Tasks01=Default,24,128,vDefaultTask,Default,NULL,Dynamic,NULL,NULL
FREERTOS.configTOTAL_HEAP_SIZE=32768 FREERTOS.configTOTAL_HEAP_SIZE=32768
FREERTOS.configUSE_NEWLIB_REENTRANT=1 FREERTOS.configUSE_NEWLIB_REENTRANT=1
File.Version=6 File.Version=6
GPIO.groupedBy=Group By Peripherals GPIO.groupedBy=Group By Peripherals
KeepUserPlacement=false KeepUserPlacement=false
Mcu.Family=STM32L4 Mcu.Family=STM32L4
Mcu.IP0=ADC1 Mcu.IP0=ADC1
Mcu.IP1=CAN1 Mcu.IP1=CAN1
Mcu.IP2=DAC1 Mcu.IP2=DAC1
Mcu.IP3=DMA Mcu.IP3=DMA
Mcu.IP4=FREERTOS Mcu.IP4=FREERTOS
Mcu.IP5=NVIC Mcu.IP5=NVIC
Mcu.IP6=RCC Mcu.IP6=RCC
Mcu.IP7=SPI1 Mcu.IP7=SPI1
Mcu.IP8=SYS Mcu.IP8=SYS
Mcu.IPNb=9 Mcu.IPNb=9
Mcu.Name=STM32L432K(B-C)Ux Mcu.Name=STM32L432K(B-C)Ux
Mcu.Package=UFQFPN32 Mcu.Package=UFQFPN32
Mcu.Pin0=PA0 Mcu.Pin0=PA0
Mcu.Pin1=PA1 Mcu.Pin1=PA1
Mcu.Pin10=PA10 Mcu.Pin10=PA10
Mcu.Pin11=PA11 Mcu.Pin11=PA11
Mcu.Pin12=PA12 Mcu.Pin12=PA12
Mcu.Pin13=PA13 (JTMS-SWDIO) Mcu.Pin13=PA13 (JTMS-SWDIO)
Mcu.Pin14=PA14 (JTCK-SWCLK) Mcu.Pin14=PA14 (JTCK-SWCLK)
Mcu.Pin15=PA15 (JTDI) Mcu.Pin15=PA15 (JTDI)
Mcu.Pin16=PB3 (JTDO-TRACESWO) Mcu.Pin16=PB3 (JTDO-TRACESWO)
Mcu.Pin17=PB4 (NJTRST) Mcu.Pin17=PB4 (NJTRST)
Mcu.Pin18=PB5 Mcu.Pin18=PB5
Mcu.Pin19=PB6 Mcu.Pin19=PB6
Mcu.Pin2=PA2 Mcu.Pin2=PA2
Mcu.Pin20=PB7 Mcu.Pin20=PB7
Mcu.Pin21=VP_FREERTOS_VS_CMSIS_V2 Mcu.Pin21=VP_FREERTOS_VS_CMSIS_V2
Mcu.Pin22=VP_SYS_VS_Systick Mcu.Pin22=VP_SYS_VS_Systick
Mcu.Pin3=PA4 Mcu.Pin3=PA4
Mcu.Pin4=PA5 Mcu.Pin4=PA5
Mcu.Pin5=PA6 Mcu.Pin5=PA6
Mcu.Pin6=PA7 Mcu.Pin6=PA7
Mcu.Pin7=PB0 Mcu.Pin7=PB0
Mcu.Pin8=PB1 Mcu.Pin8=PB1
Mcu.Pin9=PA8 Mcu.Pin9=PA8
Mcu.PinsNb=23 Mcu.PinsNb=23
Mcu.ThirdPartyNb=0 Mcu.ThirdPartyNb=0
Mcu.UserConstants= Mcu.UserConstants=
Mcu.UserName=STM32L432KBUx Mcu.UserName=STM32L432KBUx
MxCube.Version=6.3.0 MxCube.Version=6.3.0
MxDb.Version=DB.6.0.30 MxDb.Version=DB.6.0.30
NVIC.ADC1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.ADC1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.BusFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.BusFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
NVIC.CAN1_RX0_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.CAN1_RX0_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.CAN1_RX1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.CAN1_RX1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.CAN1_SCE_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.CAN1_SCE_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.CAN1_TX_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.CAN1_TX_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.DMA1_Channel2_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true NVIC.DMA1_Channel2_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true
NVIC.DMA1_Channel3_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true NVIC.DMA1_Channel3_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true
NVIC.DMA2_Channel3_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true NVIC.DMA2_Channel3_IRQn=true\:5\:0\:false\:false\:true\:true\:false\:true
NVIC.DebugMonitor_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.DebugMonitor_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
NVIC.ForceEnableDMAVector=true NVIC.ForceEnableDMAVector=true
NVIC.HardFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.HardFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
NVIC.MemoryManagement_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.MemoryManagement_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
NVIC.NonMaskableInt_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.NonMaskableInt_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
NVIC.PendSV_IRQn=true\:15\:0\:false\:false\:false\:true\:false\:false NVIC.PendSV_IRQn=true\:15\:0\:false\:false\:false\:true\:false\:false
NVIC.PriorityGroup=NVIC_PRIORITYGROUP_4 NVIC.PriorityGroup=NVIC_PRIORITYGROUP_4
NVIC.SPI1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true NVIC.SPI1_IRQn=true\:5\:0\:false\:false\:true\:true\:true\:true
NVIC.SVCall_IRQn=true\:0\:0\:false\:false\:false\:false\:false\:false NVIC.SVCall_IRQn=true\:0\:0\:false\:false\:false\:false\:false\:false
NVIC.SavedPendsvIrqHandlerGenerated=false NVIC.SavedPendsvIrqHandlerGenerated=false
NVIC.SavedSvcallIrqHandlerGenerated=false NVIC.SavedSvcallIrqHandlerGenerated=false
NVIC.SavedSystickIrqHandlerGenerated=false NVIC.SavedSystickIrqHandlerGenerated=false
NVIC.SysTick_IRQn=true\:15\:0\:false\:false\:true\:true\:false\:true NVIC.SysTick_IRQn=true\:15\:0\:false\:false\:true\:true\:false\:true
NVIC.UsageFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false NVIC.UsageFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
PA0.Mode=HSE-External-Clock-Source-for-LittleOrca PA0.Mode=HSE-External-Clock-Source-for-LittleOrca
PA0.Signal=RCC_CK_IN PA0.Signal=RCC_CK_IN
PA1.Locked=true PA1.Locked=true
PA1.Signal=ADCx_IN6 PA1.Signal=ADCx_IN6
PA10.GPIOParameters=GPIO_Label PA10.GPIOParameters=GPIO_Label
PA10.GPIO_Label=LED PA10.GPIO_Label=LED
PA10.Locked=true PA10.Locked=true
PA10.Signal=GPIO_Output PA10.Signal=GPIO_Output
PA11.Mode=CAN_Activate PA11.Mode=CAN_Activate
PA11.Signal=CAN1_RX PA11.Signal=CAN1_RX
PA12.Mode=CAN_Activate PA12.Mode=CAN_Activate
PA12.Signal=CAN1_TX PA12.Signal=CAN1_TX
PA13\ (JTMS-SWDIO).Mode=Serial_Wire PA13\ (JTMS-SWDIO).Mode=Serial_Wire
PA13\ (JTMS-SWDIO).Signal=SYS_JTMS-SWDIO PA13\ (JTMS-SWDIO).Signal=SYS_JTMS-SWDIO
PA14\ (JTCK-SWCLK).Mode=Serial_Wire PA14\ (JTCK-SWCLK).Mode=Serial_Wire
PA14\ (JTCK-SWCLK).Signal=SYS_JTCK-SWCLK PA14\ (JTCK-SWCLK).Signal=SYS_JTCK-SWCLK
PA15\ (JTDI).GPIOParameters=GPIO_Label PA15\ (JTDI).GPIOParameters=GPIO_Label
PA15\ (JTDI).GPIO_Label=ADR0 PA15\ (JTDI).GPIO_Label=ADR0
PA15\ (JTDI).Locked=true PA15\ (JTDI).Locked=true
PA15\ (JTDI).Signal=GPIO_Input PA15\ (JTDI).Signal=GPIO_Input
PA2.Locked=true PA2.Locked=true
PA2.Signal=ADCx_IN7 PA2.Signal=ADCx_IN7
PA4.Locked=true PA4.Locked=true
PA4.Signal=COMP_DAC11_group PA4.Signal=COMP_DAC11_group
PA5.Mode=Full_Duplex_Master PA5.Mode=Full_Duplex_Master
PA5.Signal=SPI1_SCK PA5.Signal=SPI1_SCK
PA6.Mode=Full_Duplex_Master PA6.Mode=Full_Duplex_Master
PA6.Signal=SPI1_MISO PA6.Signal=SPI1_MISO
PA7.Mode=Full_Duplex_Master PA7.Mode=Full_Duplex_Master
PA7.Signal=SPI1_MOSI PA7.Signal=SPI1_MOSI
PA8.GPIOParameters=GPIO_Label PA8.GPIOParameters=GPIO_Label
PA8.GPIO_Label=EN PA8.GPIO_Label=EN
PA8.Locked=true PA8.Locked=true
PA8.Signal=GPIO_Output PA8.Signal=GPIO_Output
PB0.Locked=true PB0.Locked=true
PB0.Signal=ADCx_IN15 PB0.Signal=ADCx_IN15
PB1.Locked=true PB1.Locked=true
PB1.Signal=ADCx_IN16 PB1.Signal=ADCx_IN16
PB3\ (JTDO-TRACESWO).GPIOParameters=GPIO_Label PB3\ (JTDO-TRACESWO).GPIOParameters=GPIO_Label
PB3\ (JTDO-TRACESWO).GPIO_Label=ADR1 PB3\ (JTDO-TRACESWO).GPIO_Label=ADR1
PB3\ (JTDO-TRACESWO).Locked=true PB3\ (JTDO-TRACESWO).Locked=true
PB3\ (JTDO-TRACESWO).Signal=GPIO_Input PB3\ (JTDO-TRACESWO).Signal=GPIO_Input
PB4\ (NJTRST).GPIOParameters=GPIO_Label PB4\ (NJTRST).GPIOParameters=GPIO_Label
PB4\ (NJTRST).GPIO_Label=ADR2 PB4\ (NJTRST).GPIO_Label=ADR2
PB4\ (NJTRST).Locked=true PB4\ (NJTRST).Locked=true
PB4\ (NJTRST).Signal=GPIO_Input PB4\ (NJTRST).Signal=GPIO_Input
PB5.GPIOParameters=GPIO_Label PB5.GPIOParameters=GPIO_Label
PB5.GPIO_Label=CS1 PB5.GPIO_Label=CS1
PB5.Locked=true PB5.Locked=true
PB5.Signal=GPIO_Output PB5.Signal=GPIO_Output
PB6.GPIOParameters=GPIO_Label PB6.GPIOParameters=GPIO_Label
PB6.GPIO_Label=CS2 PB6.GPIO_Label=CS2
PB6.Locked=true PB6.Locked=true
PB6.Signal=GPIO_Output PB6.Signal=GPIO_Output
PB7.GPIOParameters=GPIO_Label PB7.GPIOParameters=GPIO_Label
PB7.GPIO_Label=PG PB7.GPIO_Label=PG
PB7.Locked=true PB7.Locked=true
PB7.Signal=GPIO_Input PB7.Signal=GPIO_Input
PinOutPanel.RotationAngle=0 PinOutPanel.RotationAngle=0
ProjectManager.AskForMigrate=true ProjectManager.AskForMigrate=true
ProjectManager.BackupPrevious=false ProjectManager.BackupPrevious=false
ProjectManager.CompilerOptimize=6 ProjectManager.CompilerOptimize=6
ProjectManager.ComputerToolchain=false ProjectManager.ComputerToolchain=false
ProjectManager.CoupleFile=false ProjectManager.CoupleFile=false
ProjectManager.CustomerFirmwarePackage= ProjectManager.CustomerFirmwarePackage=
ProjectManager.DefaultFWLocation=true ProjectManager.DefaultFWLocation=true
ProjectManager.DeletePrevious=true ProjectManager.DeletePrevious=true
ProjectManager.DeviceId=STM32L432KBUx ProjectManager.DeviceId=STM32L432KBUx
ProjectManager.FirmwarePackage=STM32Cube FW_L4 V1.17.0 ProjectManager.FirmwarePackage=STM32Cube FW_L4 V1.17.0
ProjectManager.FreePins=false ProjectManager.FreePins=false
ProjectManager.HalAssertFull=false ProjectManager.HalAssertFull=false
ProjectManager.HeapSize=0x200 ProjectManager.HeapSize=0x200
ProjectManager.KeepUserCode=true ProjectManager.KeepUserCode=true
ProjectManager.LastFirmware=false ProjectManager.LastFirmware=true
ProjectManager.LibraryCopy=1 ProjectManager.LibraryCopy=1
ProjectManager.MainLocation=Core/Src ProjectManager.MainLocation=Core/Src
ProjectManager.NoMain=false ProjectManager.NoMain=false
ProjectManager.PreviousToolchain=STM32CubeIDE ProjectManager.PreviousToolchain=STM32CubeIDE
ProjectManager.ProjectBuild=false ProjectManager.ProjectBuild=false
ProjectManager.ProjectFileName=PeltierControllerV3.ioc ProjectManager.ProjectFileName=PeltierControllerV3.ioc
ProjectManager.ProjectName=PeltierControllerV3 ProjectManager.ProjectName=PeltierControllerV3
ProjectManager.RegisterCallBack= ProjectManager.RegisterCallBack=
ProjectManager.StackSize=0x400 ProjectManager.StackSize=0x400
ProjectManager.TargetToolchain=STM32CubeIDE ProjectManager.TargetToolchain=STM32CubeIDE
ProjectManager.ToolChainLocation= ProjectManager.ToolChainLocation=
ProjectManager.UnderRoot=true ProjectManager.UnderRoot=true
ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-MX_DMA_Init-DMA-false-HAL-true,3-SystemClock_Config-RCC-false-HAL-false,4-MX_ADC1_Init-ADC1-false-HAL-true,5-MX_CAN1_Init-CAN1-false-HAL-true,6-MX_DAC1_Init-DAC1-false-HAL-true,7-MX_SPI1_Init-SPI1-false-HAL-true ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-MX_DMA_Init-DMA-false-HAL-true,3-SystemClock_Config-RCC-false-HAL-false,4-MX_ADC1_Init-ADC1-false-HAL-true,5-MX_CAN1_Init-CAN1-false-HAL-true,6-MX_DAC1_Init-DAC1-false-HAL-true,7-MX_SPI1_Init-SPI1-false-HAL-true
RCC.ADCCLockSelection=RCC_ADCCLKSOURCE_SYSCLK RCC.ADCCLockSelection=RCC_ADCCLKSOURCE_SYSCLK
RCC.ADCFreq_Value=80000000 RCC.ADCFreq_Value=80000000
RCC.AHBFreq_Value=80000000 RCC.AHBFreq_Value=80000000
RCC.APB1Freq_Value=80000000 RCC.APB1Freq_Value=80000000
RCC.APB1TimFreq_Value=80000000 RCC.APB1TimFreq_Value=80000000
RCC.APB2Freq_Value=80000000 RCC.APB2Freq_Value=80000000
RCC.APB2TimFreq_Value=80000000 RCC.APB2TimFreq_Value=80000000
RCC.CortexFreq_Value=80000000 RCC.CortexFreq_Value=80000000
RCC.FCLKCortexFreq_Value=80000000 RCC.FCLKCortexFreq_Value=80000000
RCC.FamilyName=M RCC.FamilyName=M
RCC.HCLKFreq_Value=80000000 RCC.HCLKFreq_Value=80000000
RCC.HSE_VALUE=40000000 RCC.HSE_VALUE=40000000
RCC.HSI48_VALUE=48000000 RCC.HSI48_VALUE=48000000
RCC.HSI_VALUE=16000000 RCC.HSI_VALUE=16000000
RCC.I2C1Freq_Value=80000000 RCC.I2C1Freq_Value=80000000
RCC.I2C3Freq_Value=80000000 RCC.I2C3Freq_Value=80000000
RCC.IPParameters=ADCCLockSelection,ADCFreq_Value,AHBFreq_Value,APB1Freq_Value,APB1TimFreq_Value,APB2Freq_Value,APB2TimFreq_Value,CortexFreq_Value,FCLKCortexFreq_Value,FamilyName,HCLKFreq_Value,HSE_VALUE,HSI48_VALUE,HSI_VALUE,I2C1Freq_Value,I2C3Freq_Value,LPTIM1Freq_Value,LPTIM2Freq_Value,LPUART1Freq_Value,LSCOPinFreq_Value,LSE_VALUE,LSI_VALUE,MCO1PinFreq_Value,MSI_VALUE,PLLM,PLLN,PLLPoutputFreq_Value,PLLQoutputFreq_Value,PLLRCLKFreq_Value,PLLSAI1PoutputFreq_Value,PLLSAI1QoutputFreq_Value,PLLSAI1RoutputFreq_Value,PLLSourceVirtual,PWRFreq_Value,RNGFreq_Value,SAI1Freq_Value,SWPMI1Freq_Value,SYSCLKFreq_VALUE,SYSCLKSource,USART1Freq_Value,USART2Freq_Value,USBFreq_Value,VCOInputFreq_Value,VCOOutputFreq_Value,VCOSAI1OutputFreq_Value RCC.IPParameters=ADCCLockSelection,ADCFreq_Value,AHBFreq_Value,APB1Freq_Value,APB1TimFreq_Value,APB2Freq_Value,APB2TimFreq_Value,CortexFreq_Value,FCLKCortexFreq_Value,FamilyName,HCLKFreq_Value,HSE_VALUE,HSI48_VALUE,HSI_VALUE,I2C1Freq_Value,I2C3Freq_Value,LPTIM1Freq_Value,LPTIM2Freq_Value,LPUART1Freq_Value,LSCOPinFreq_Value,LSE_VALUE,LSI_VALUE,MCO1PinFreq_Value,MSI_VALUE,PLLM,PLLN,PLLPoutputFreq_Value,PLLQoutputFreq_Value,PLLRCLKFreq_Value,PLLSAI1PoutputFreq_Value,PLLSAI1QoutputFreq_Value,PLLSAI1RoutputFreq_Value,PLLSourceVirtual,PWRFreq_Value,RNGFreq_Value,SAI1Freq_Value,SWPMI1Freq_Value,SYSCLKFreq_VALUE,SYSCLKSource,USART1Freq_Value,USART2Freq_Value,USBFreq_Value,VCOInputFreq_Value,VCOOutputFreq_Value,VCOSAI1OutputFreq_Value
RCC.LPTIM1Freq_Value=80000000 RCC.LPTIM1Freq_Value=80000000
RCC.LPTIM2Freq_Value=80000000 RCC.LPTIM2Freq_Value=80000000
RCC.LPUART1Freq_Value=80000000 RCC.LPUART1Freq_Value=80000000
RCC.LSCOPinFreq_Value=32000 RCC.LSCOPinFreq_Value=32000
RCC.LSE_VALUE=32768 RCC.LSE_VALUE=32768
RCC.LSI_VALUE=32000 RCC.LSI_VALUE=32000
RCC.MCO1PinFreq_Value=80000000 RCC.MCO1PinFreq_Value=80000000
RCC.MSI_VALUE=4000000 RCC.MSI_VALUE=4000000
RCC.PLLM=4 RCC.PLLM=4
RCC.PLLN=16 RCC.PLLN=16
RCC.PLLPoutputFreq_Value=22857142.85714286 RCC.PLLPoutputFreq_Value=22857142.85714286
RCC.PLLQoutputFreq_Value=80000000 RCC.PLLQoutputFreq_Value=80000000
RCC.PLLRCLKFreq_Value=80000000 RCC.PLLRCLKFreq_Value=80000000
RCC.PLLSAI1PoutputFreq_Value=11428571.42857143 RCC.PLLSAI1PoutputFreq_Value=11428571.42857143
RCC.PLLSAI1QoutputFreq_Value=40000000 RCC.PLLSAI1QoutputFreq_Value=40000000
RCC.PLLSAI1RoutputFreq_Value=40000000 RCC.PLLSAI1RoutputFreq_Value=40000000
RCC.PLLSourceVirtual=RCC_PLLSOURCE_HSE RCC.PLLSourceVirtual=RCC_PLLSOURCE_HSE
RCC.PWRFreq_Value=80000000 RCC.PWRFreq_Value=80000000
RCC.RNGFreq_Value=40000000 RCC.RNGFreq_Value=40000000
RCC.SAI1Freq_Value=11428571.42857143 RCC.SAI1Freq_Value=11428571.42857143
RCC.SWPMI1Freq_Value=80000000 RCC.SWPMI1Freq_Value=80000000
RCC.SYSCLKFreq_VALUE=80000000 RCC.SYSCLKFreq_VALUE=80000000
RCC.SYSCLKSource=RCC_SYSCLKSOURCE_PLLCLK RCC.SYSCLKSource=RCC_SYSCLKSOURCE_PLLCLK
RCC.USART1Freq_Value=80000000 RCC.USART1Freq_Value=80000000
RCC.USART2Freq_Value=80000000 RCC.USART2Freq_Value=80000000
RCC.USBFreq_Value=40000000 RCC.USBFreq_Value=40000000
RCC.VCOInputFreq_Value=10000000 RCC.VCOInputFreq_Value=10000000
RCC.VCOOutputFreq_Value=160000000 RCC.VCOOutputFreq_Value=160000000
RCC.VCOSAI1OutputFreq_Value=80000000 RCC.VCOSAI1OutputFreq_Value=80000000
SH.ADCx_IN15.0=ADC1_IN15,IN15-Single-Ended SH.ADCx_IN15.0=ADC1_IN15,IN15-Single-Ended
SH.ADCx_IN15.ConfNb=1 SH.ADCx_IN15.ConfNb=1
SH.ADCx_IN16.0=ADC1_IN16,IN16-Single-Ended SH.ADCx_IN16.0=ADC1_IN16,IN16-Single-Ended
SH.ADCx_IN16.ConfNb=1 SH.ADCx_IN16.ConfNb=1
SH.ADCx_IN6.0=ADC1_IN6,IN6-Single-Ended SH.ADCx_IN6.0=ADC1_IN6,IN6-Single-Ended
SH.ADCx_IN6.ConfNb=1 SH.ADCx_IN6.ConfNb=1
SH.ADCx_IN7.0=ADC1_IN7,IN7-Single-Ended SH.ADCx_IN7.0=ADC1_IN7,IN7-Single-Ended
SH.ADCx_IN7.ConfNb=1 SH.ADCx_IN7.ConfNb=1
SH.COMP_DAC11_group.0=DAC1_OUT1,DAC_OUT1 SH.COMP_DAC11_group.0=DAC1_OUT1,DAC_OUT1
SH.COMP_DAC11_group.ConfNb=1 SH.COMP_DAC11_group.ConfNb=1
SPI1.BaudRatePrescaler=SPI_BAUDRATEPRESCALER_128 SPI1.BaudRatePrescaler=SPI_BAUDRATEPRESCALER_128
SPI1.CLKPhase=SPI_PHASE_2EDGE SPI1.CLKPhase=SPI_PHASE_2EDGE
SPI1.CalculateBaudRate=625.0 KBits/s SPI1.CalculateBaudRate=625.0 KBits/s
SPI1.DataSize=SPI_DATASIZE_8BIT SPI1.DataSize=SPI_DATASIZE_8BIT
SPI1.Direction=SPI_DIRECTION_2LINES SPI1.Direction=SPI_DIRECTION_2LINES
SPI1.IPParameters=VirtualType,Mode,Direction,CalculateBaudRate,DataSize,BaudRatePrescaler,CLKPhase SPI1.IPParameters=VirtualType,Mode,Direction,CalculateBaudRate,DataSize,BaudRatePrescaler,CLKPhase
SPI1.Mode=SPI_MODE_MASTER SPI1.Mode=SPI_MODE_MASTER
SPI1.VirtualType=VM_MASTER SPI1.VirtualType=VM_MASTER
VP_FREERTOS_VS_CMSIS_V2.Mode=CMSIS_V2 VP_FREERTOS_VS_CMSIS_V2.Mode=CMSIS_V2
VP_FREERTOS_VS_CMSIS_V2.Signal=FREERTOS_VS_CMSIS_V2 VP_FREERTOS_VS_CMSIS_V2.Signal=FREERTOS_VS_CMSIS_V2
VP_SYS_VS_Systick.Mode=SysTick VP_SYS_VS_Systick.Mode=SysTick
VP_SYS_VS_Systick.Signal=SYS_VS_Systick VP_SYS_VS_Systick.Signal=SYS_VS_Systick
board=custom board=custom
isbadioc=false

View File

@ -0,0 +1,77 @@
# Configuration file for the STM32 for VSCode extension
# Arrays can be inputted in two ways. One is: [entry_1, entry_2, ..., entry_final]
# or by adding an indented list below the variable name e.g.:
# VARIABLE:
# - entry_1
# - entry_2
# The project name
target: TEC
# Can be C or C++
language: C
optimization: Og
# MCU settings
targetMCU: STM32L432KBUx
cpu:
fpu:
floatAbi:
ldscript: STM32L432KBUX_FLASH.ld # linker script
# Compiler definitions. The -D prefix for the compiler will be automatically added.
cDefinitions: []
cxxDefinitions: []
asDefinitions: []
# Compiler definition files. you can add a single files or an array of files for different definitions.
# The file is expected to have a definition each new line.
# This allows to include for example a .definition file which can be ignored in git and can contain
# This can be convenient for passing along secrets at compile time, or generating a file for per device setup.
cDefinitionsFile:
cxxDefinitionsFile:
asDefinitionsFile:
# Compiler flags
cFlags: []
cxxFlags: []
assemblyFlags:
- -specs=nosys.specs
# libraries to be included. The -l prefix to the library will be automatically added.
# Mind that non standard libraries should have a path to their respective directory.
libraries: []
libraryDirectories: []
# Files or folders that will be excluded from compilation.
# Glob patterns (https://www.wikiwand.com/en/Glob_(programming)) can be used.
# Do mind that double stars are reserved in yaml
# these should be escaped with a: \ or the name should be in double quotes e.g. "**.test.**"
excludes:
- "**_Template.*"
# Include directories (directories containing .h or .hpp files)
# If a CubeMX makefile is present it will automatically include the include directories from that makefile.
includeDirectories:
- Core/Inc/**
- Middlewares/**
- Drivers/STM32L4xx_HAL_Driver/Inc/**
- Drivers/CMSIS/**
# Files that should be included in the compilation.
# If a CubeMX makefile is present it will automatically include the c and cpp/cxx files from that makefile.
# Glob patterns (https://www.wikiwand.com/en/Glob_(programming)) can be used.
# Do mind that double stars are reserved in yaml
# these should be escaped with a: \ or the name should be in double quotes e.g. "HARDWARE_DRIVER*.c"
sourceFiles:
- Core/Src/**
- Drivers/STM32L4xx_HAL_Driver/Src/**
# When no makefile is present it will show a warning pop-up.
# However when compilation without the CubeMX Makefile is desired, this can be turned of.
suppressMakefileWarning: false

239
STM32Make.make Normal file
View File

@ -0,0 +1,239 @@
##########################################################################################################################
# File automatically-generated by STM32forVSCode
##########################################################################################################################
# ------------------------------------------------
# Generic Makefile (based on gcc)
#
# ChangeLog :
# 2017-02-10 - Several enhancements + project update mode
# 2015-07-22 - first version
# ------------------------------------------------
######################################
# target
######################################
TARGET = TEC
######################################
# building variables
######################################
# debug build?
DEBUG = 1
# optimization
OPT = -Og
#######################################
# paths
#######################################
# Build path
BUILD_DIR = build
######################################
# source
######################################
# C sources
C_SOURCES = \
Core/Src/freertos.c \
Core/Src/main.c \
Core/Src/stm32l4xx_hal_msp.c \
Core/Src/stm32l4xx_it.c \
Core/Src/syscalls.c \
Core/Src/sysmem.c \
Core/Src/system_stm32l4xx.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_adc.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_adc_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_can.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_cortex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dac.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dac_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dma.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dma_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_exti.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash_ramfunc.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_gpio.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_i2c.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_i2c_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_pwr.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_pwr_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rcc.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rcc_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_spi.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_spi_ex.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_tim.c \
Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_tim_ex.c
CPP_SOURCES = \
# ASM sources
ASM_SOURCES = \
#######################################
# binaries
#######################################
PREFIX = arm-none-eabi-
POSTFIX = "
# The gcc compiler bin path can be either defined in make command via GCC_PATH variable (> make GCC_PATH=xxx)
# either it can be added to the PATH environment variable.
GCC_PATH="/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/arm-none-eabi-gcc/10.3.1-2.3.1/.content/bin
ifdef GCC_PATH
CXX = $(GCC_PATH)/$(PREFIX)g++$(POSTFIX)
CC = $(GCC_PATH)/$(PREFIX)gcc$(POSTFIX)
AS = $(GCC_PATH)/$(PREFIX)gcc$(POSTFIX) -x assembler-with-cpp
CP = $(GCC_PATH)/$(PREFIX)objcopy$(POSTFIX)
SZ = $(GCC_PATH)/$(PREFIX)size$(POSTFIX)
else
CXX = $(PREFIX)g++
CC = $(PREFIX)gcc
AS = $(PREFIX)gcc -x assembler-with-cpp
CP = $(PREFIX)objcopy
SZ = $(PREFIX)size
endif
HEX = $(CP) -O ihex
BIN = $(CP) -O binary -S
#######################################
# CFLAGS
#######################################
# cpu
CPU =
# fpu
FPU =
# float-abi
FLOAT-ABI =
# mcu
MCU = $(CPU) -mthumb $(FPU) $(FLOAT-ABI)
# macros for gcc
# AS defines
AS_DEFS =
# C defines
C_DEFS = \
# AS includes
AS_INCLUDES = \
# C includes
C_INCLUDES = \
-ICore/Inc \
-IDrivers/CMSIS/Device/ST/STM32L4xx/Include \
-IDrivers/CMSIS/Include \
-IDrivers/STM32L4xx_HAL_Driver/Inc \
-IDrivers/STM32L4xx_HAL_Driver/Inc/Legacy \
-IMiddlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS_V2 \
-IMiddlewares/Third_Party/FreeRTOS/Source/include \
-IMiddlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM4F
# compile gcc flags
ASFLAGS = $(MCU) $(AS_DEFS) $(AS_INCLUDES) $(OPT) -Wall -fdata-sections -ffunction-sections
CFLAGS = $(MCU) $(C_DEFS) $(C_INCLUDES) $(OPT) -Wall -fdata-sections -ffunction-sections
ifeq ($(DEBUG), 1)
CFLAGS += -g -gdwarf-2
endif
# Add additional flags
CFLAGS +=
ASFLAGS += -specs=nosys.specs
CXXFLAGS =
CXXFLAGS += -feliminate-unused-debug-types
# Generate dependency information
CFLAGS += -MMD -MP -MF"$(@:%.o=%.d)"
#######################################
# LDFLAGS
#######################################
# link script
LDSCRIPT = STM32L432KBUX_FLASH.ld
# libraries
LIBS =
LIBDIR = \
# Additional LD Flags from config file
ADDITIONALLDFLAGS = -specs=nosys.specs
LDFLAGS = $(MCU) $(ADDITIONALLDFLAGS) -T$(LDSCRIPT) $(LIBDIR) $(LIBS) -Wl,-Map=$(BUILD_DIR)/$(TARGET).map,--cref -Wl,--gc-sections
# default action: build all
all: $(BUILD_DIR)/$(TARGET).elf $(BUILD_DIR)/$(TARGET).hex $(BUILD_DIR)/$(TARGET).bin
#######################################
# build the application
#######################################
# list of cpp program objects
OBJECTS = $(addprefix $(BUILD_DIR)/,$(notdir $(CPP_SOURCES:.cpp=.o)))
vpath %.cpp $(sort $(dir $(CPP_SOURCES)))
# list of C objects
OBJECTS += $(addprefix $(BUILD_DIR)/,$(notdir $(C_SOURCES:.c=.o)))
vpath %.c $(sort $(dir $(C_SOURCES)))
# list of ASM program objects
OBJECTS += $(addprefix $(BUILD_DIR)/,$(notdir $(ASM_SOURCES:.s=.o)))
vpath %.s $(sort $(dir $(ASM_SOURCES)))
$(BUILD_DIR)/%.o: %.cpp STM32Make.make | $(BUILD_DIR)
$(CXX) -c $(CXXFLAGS) $(CFLAGS) -Wa,-a,-ad,-alms=$(BUILD_DIR)/$(notdir $(<:.cpp=.lst)) $< -o $@
$(BUILD_DIR)/%.o: %.c STM32Make.make | $(BUILD_DIR)
$(CC) -c $(CFLAGS) -Wa,-a,-ad,-alms=$(BUILD_DIR)/$(notdir $(<:.c=.lst)) $< -o $@
$(BUILD_DIR)/%.o: %.s STM32Make.make | $(BUILD_DIR)
$(AS) -c $(CFLAGS) $< -o $@
$(BUILD_DIR)/$(TARGET).elf: $(OBJECTS) STM32Make.make
$(CC) $(OBJECTS) $(LDFLAGS) -o $@
$(SZ) $@
$(BUILD_DIR)/%.hex: $(BUILD_DIR)/%.elf | $(BUILD_DIR)
$(HEX) $< $@
$(BUILD_DIR)/%.bin: $(BUILD_DIR)/%.elf | $(BUILD_DIR)
$(BIN) $< $@
$(BUILD_DIR):
mkdir $@
#######################################
# flash
#######################################
flash: $(BUILD_DIR)/$(TARGET).elf
"/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/openocd/0.11.0-2.1/.content/bin/openocd" -f ./openocd.cfg -c "program $(BUILD_DIR)/$(TARGET).elf verify reset exit"
#######################################
# erase
#######################################
erase: $(BUILD_DIR)/$(TARGET).elf
"/Users/noahpique/Library/Application Support/Code/User/globalStorage/bmd.stm32-for-vscode/@xpack-dev-tools/openocd/0.11.0-2.1/.content/bin/openocd" -f ./openocd.cfg -c "init; reset halt; STM32L432KBUx mass_erase 0; exit"
#######################################
# clean up
#######################################
clean:
-rm -fR $(BUILD_DIR)
#######################################
# dependencies
#######################################
-include $(wildcard $(BUILD_DIR)/*.d)
# *** EOF ***

8
openocd.cfg Normal file
View File

@ -0,0 +1,8 @@
#OpenOCD configuration file, generated by STM32 for VSCode
# Programmer, can be changed to several interfaces
# Standard will be the stlink interface as this is the standard for STM32 dev boards
source [find interface/stlink.cfg]
# The target MCU. This should match your board
source [find target/.cfg]