STM32 Blue Pill Drivers
Drivers that could be used to interface and interact with STM32F103C8T6 Microcontroller
Loading...
Searching...
No Matches
Testing Applications

Testing Applications. More...

Functions

void vAPPS_main (void)
 This function is responsible for running the applications. More...
 
void vTestApp_TestingGPIO_main (void)
 This function is the main function for the TestApp_TestingGPIO application. More...
 

Detailed Description

Testing Applications.

This module contains all the testing applications

Function Documentation

◆ vAPPS_main()

void vAPPS_main ( void  )

#include <APPS/APPS_main.h>

This function is responsible for running the applications.

This function is responsible for running the applications

26{
27 RCC_vInit();
29
30 for (;;)
31 {
32 /* Do nothing */
33 }
34}
#define TestingGPIO
Definition: APPS_main.c:19
#define TESTING_APPLICATION_MAIN_FUNC(APP_NAME)
This macro is used to define the main function of the application.
Definition: APPS_main.c:17
void RCC_vInit(void)
This function initializes the RCC peripheral.
Definition: RCC_program.c:324

References RCC_vInit(), TESTING_APPLICATION_MAIN_FUNC, and TestingGPIO.

Referenced by main().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ vTestApp_TestingGPIO_main()

void vTestApp_TestingGPIO_main ( void  )

#include <APPS/TestingGPIO/TestApp_TestingGPIO_main.h>

This function is the main function for the TestApp_TestingGPIO application.

This function is the main function for the TestApp_TestingGPIO application

16{
17 // t_u32 u32Counter = 0;
22 // GPIO_vSetPinInputType(GPIO_Ports_B, GPIO_Pins_7, GPIO_Input_Type_Pull_Down);
24
25 for (;;)
26 {
28 // if (GPIO_tGetPinValue(GPIO_Ports_B, GPIO_Pins_7) == GPIO_Value_High)
29 // if (GPIO_tGetPinValue(GPIO_Ports_B, GPIO_Pins_7) == GPIO_Value_Low)
30 // {
31 // GPIO_vSetPinValue(GPIO_Ports_A, GPIO_Pins_1, GPIO_Value_High);
32 // }
33 // else
34 // {
35 // GPIO_vSetPinValue(GPIO_Ports_A, GPIO_Pins_1, GPIO_Value_Low);
36 // }
37
38 // GPIO_vSetPinValue(GPIO_Ports_A, GPIO_Pins_1, GPIO_Value_High);
39 // for (u32Counter = 0; u32Counter < 10000000; u32Counter++)
40 // ;
41 // GPIO_vSetPinValue(GPIO_Ports_A, GPIO_Pins_1, GPIO_Value_Low);
42 // for (u32Counter = 0; u32Counter < 10000000; u32Counter++)
43 // ;
44 }
45}
void GPIO_vSetPinValue(t_GPIO_Ports tPort, t_GPIO_Pins tPin, t_GPIO_Value tValue)
This function is used to set the value of a GPIO pin.
Definition: GPIO_program.c:174
void GPIO_vSetPinDirection(t_GPIO_Ports tPort, t_GPIO_Pins tPin, t_GPIO_Direction tDirection)
This function is used to set the direction of a GPIO pin.
Definition: GPIO_program.c:103
t_GPIO_Value GPIO_tGetPinValue(t_GPIO_Ports tPort, t_GPIO_Pins tPin)
This function is used to get the value of a GPIO pin.
Definition: GPIO_program.c:198
void GPIO_vSetPinInputType(t_GPIO_Ports tPort, t_GPIO_Pins tPin, t_GPIO_Input_Type tInputType)
This function is used to set the input type of a GPIO pin.
Definition: GPIO_program.c:132
@ GPIO_Pins_1
GPIO Pin 1.
Definition: GPIO_interface.h:74
@ GPIO_Pins_7
GPIO Pin 7.
Definition: GPIO_interface.h:98
@ GPIO_Ports_A
GPIO Port A.
Definition: GPIO_interface.h:33
@ GPIO_Ports_B
GPIO Port B.
Definition: GPIO_interface.h:37
@ GPIO_Input_Type_Pull_Up
GPIO Pin Input Type: Pull-Up.
Definition: GPIO_interface.h:205
@ GPIO_Direction_Output_50MHz
GPIO Pin Output with max speed of 50 MHz.
Definition: GPIO_interface.h:155
@ GPIO_Direction_Input
GPIO Pin Input.
Definition: GPIO_interface.h:143
@ RCC_APB2Peripherals_PORTA
I/O port A clock.
Definition: RCC_interface.h:295
@ RCC_APB2Peripherals_PORTB
I/O port B clock.
Definition: RCC_interface.h:299
void RCC_vEnablePeripheralABP2(t_RCC_APB2Peripherals enuPeripheral)
This function enables the clock of a peripheral connected to the APB2 bus.
Definition: RCC_program.c:352

References GPIO_Direction_Input, GPIO_Direction_Output_50MHz, GPIO_Input_Type_Pull_Up, GPIO_Pins_1, GPIO_Pins_7, GPIO_Ports_A, GPIO_Ports_B, GPIO_tGetPinValue(), GPIO_vSetPinDirection(), GPIO_vSetPinInputType(), GPIO_vSetPinValue(), RCC_APB2Peripherals_PORTA, RCC_APB2Peripherals_PORTB, and RCC_vEnablePeripheralABP2().

+ Here is the call graph for this function: