CAN_Networking
[STM32F10x_StdPeriph_Examples]

Defines

#define KEY_NOT_PRESSED   0x00
#define KEY_PRESSED   0x01

Functions

void BusFault_Handler (void)
 This function handles Bus Fault exception.
void CAN_Config (void)
 Configures the CAN.
void DebugMon_Handler (void)
 This function handles Debug Monitor exception.
void Delay (void)
 Delay.
void HardFault_Handler (void)
 This function handles Hard Fault exception.
void Init_RxMes (CanRxMsg *RxMessage)
 Initializes a Rx Message.
void LED_Display (uint8_t Ledstatus)
 Turn ON/OFF the dedicate led.
int main (void)
 Main program.
void MemManage_Handler (void)
 This function handles Memory Manage exception.
void NMI_Handler (void)
 This function handles NMI exception.
void NVIC_Config (void)
 Configures the NVIC for CAN.
void PendSV_Handler (void)
 This function handles PendSVC exception.
void SVC_Handler (void)
 This function handles SVCall exception.
void SysTick_Handler (void)
 This function handles SysTick Handler.
void UsageFault_Handler (void)
 This function handles Usage Fault exception.
void USB_LP_CAN1_RX0_IRQHandler (void)
 This function handles CAN1 Handler.

Variables

CAN_FilterInitTypeDef CAN_FilterInitStructure
CAN_InitTypeDef CAN_InitStructure
uint8_t KeyNumber
uint8_t KeyNumber = 0x0
CanRxMsg RxMessage
CanTxMsg TxMessage

Define Documentation

#define KEY_NOT_PRESSED   0x00

Definition at line 37 of file STM32F10x_StdPeriph_Examples/CAN/Networking/main.c.

Referenced by main().

#define KEY_PRESSED   0x01

Definition at line 36 of file STM32F10x_StdPeriph_Examples/CAN/Networking/main.c.

Referenced by main().


Function Documentation

void BusFault_Handler ( void   ) 

This function handles Bus Fault exception.

Parameters:
None 
Return values:
None 

Definition at line 89 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void CAN_Config ( void   ) 
void DebugMon_Handler ( void   ) 

This function handles Debug Monitor exception.

Parameters:
None 
Return values:
None 

Definition at line 124 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void Delay ( void   ) 

Delay.

Parameters:
None 
Return values:
None 

Definition at line 263 of file STM32F10x_StdPeriph_Examples/CAN/Networking/main.c.

void HardFault_Handler ( void   ) 

This function handles Hard Fault exception.

Parameters:
None 
Return values:
None 

Definition at line 63 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void Init_RxMes ( CanRxMsg RxMessage  ) 

Initializes a Rx Message.

Parameters:
CanRxMsg *RxMessage
Return values:
None 

Definition at line 210 of file STM32F10x_StdPeriph_Examples/CAN/Networking/main.c.

References CAN_ID_STD, CanRxMsg::Data, CanRxMsg::DLC, CanRxMsg::ExtId, CanRxMsg::FMI, CanRxMsg::IDE, and CanRxMsg::StdId.

void LED_Display ( uint8_t  Ledstatus  ) 

Turn ON/OFF the dedicate led.

Parameters:
Ledstatus,: Led number from 0 to 3.
Return values:
None 
int main ( void   ) 

Main program.

Parameters:
None 
Return values:
None 

< At this stage the microcontroller clock setting is already configured, this is done through SystemInit() function which is called from startup file (startup_stm32f10x_xx.s) before to branch to application main. To reconfigure the default setting of SystemInit() function, refer to system_stm32f10x.c file

Definition at line 60 of file STM32F10x_StdPeriph_Examples/CAN/Networking/main.c.

References BUTTON_KEY, BUTTON_MODE_GPIO, CAN1, CAN_Config(), CAN_IT_FMP0, CAN_ITConfig(), CAN_Transmit(), CanTxMsg::Data, Delay(), ENABLE, KEY_NOT_PRESSED, KEY_PRESSED, KeyNumber, LED1, LED2, LED3, LED4, LED_Display(), NVIC_Config(), STM_EVAL_LEDInit(), STM_EVAL_LEDOff(), STM_EVAL_PBGetState(), and STM_EVAL_PBInit().

void MemManage_Handler ( void   ) 

This function handles Memory Manage exception.

Parameters:
None 
Return values:
None 

Definition at line 76 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void NMI_Handler ( void   ) 

This function handles NMI exception.

Parameters:
None 
Return values:
None 

Definition at line 54 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void NVIC_Config ( void   ) 
void PendSV_Handler ( void   ) 

This function handles PendSVC exception.

This function handles PendSV_Handler exception.

Parameters:
None 
Return values:
None 

Definition at line 133 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void SVC_Handler ( void   ) 

This function handles SVCall exception.

Parameters:
None 
Return values:
None 

Definition at line 115 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void SysTick_Handler ( void   ) 

This function handles SysTick Handler.

Parameters:
None 
Return values:
None 

Definition at line 142 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void UsageFault_Handler ( void   ) 

This function handles Usage Fault exception.

Parameters:
None 
Return values:
None 

Definition at line 102 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

void USB_LP_CAN1_RX0_IRQHandler ( void   ) 

This function handles CAN1 Handler.

Parameters:
None 
Return values:
None 

Definition at line 157 of file STM32F10x_StdPeriph_Examples/CAN/Networking/stm32f10x_it.c.

References CAN1, CAN_FIFO0, CAN_ID_EXT, CAN_ID_STD, CAN_Receive(), CanRxMsg::Data, CanRxMsg::DLC, CanRxMsg::ExtId, CanRxMsg::FMI, CanRxMsg::IDE, KeyNumber, LED_Display(), ret, RxMessage, and CanRxMsg::StdId.


Variable Documentation

uint8_t KeyNumber
uint8_t KeyNumber = 0x0
STM32F10x Standard Peripherals Library: Footer

 

 

 

      For complete documentation on STM32(CORTEX M3) 32-bit Microcontrollers platform visit  www.st.com/STM32