TM STM32F4xx Libraries  v1.0.0
Libraries for STM32F4xx devices from Tilen Majerle
TM_HCSR04_t Struct Reference

HC-SR04 working structure. More...

#include <tm_stm32f4_hcsr04.h>

Data Fields

float Distance
 
GPIO_TypeDef * ECHO_GPIOx
 
uint16_t ECHO_GPIO_Pin
 
GPIO_TypeDef * TRIGGER_GPIOx
 
uint16_t TRIGGER_GPIO_Pin
 

Detailed Description

HC-SR04 working structure.

Field Documentation

float Distance

Distance measured from sensor in centimeters

uint16_t ECHO_GPIO_Pin

GPIO Pin for ECHO pin. Meant for private use only

GPIO_TypeDef* ECHO_GPIOx

Pointer to GPIOx PORT for ECHO pin. Meant for private use only

uint16_t TRIGGER_GPIO_Pin

GPIO Pin for ECHO pin. Meant for private use only

GPIO_TypeDef* TRIGGER_GPIOx

Pointer to GPIOx PORT for TRIGGER pin. Meant for private use only