[DHT11] add testing code, currently not functional
This commit is contained in:
17
Core/Inc/DHT11.h
Normal file
17
Core/Inc/DHT11.h
Normal file
@@ -0,0 +1,17 @@
|
||||
#ifndef __DHT11
|
||||
#define __DHT11
|
||||
|
||||
#define SKIP_LOW while (!(GPIOD->IDR & 0x0800)) {}
|
||||
#define SKIP_HIGH while (GPIOD->IDR & 0x0800) {}
|
||||
|
||||
struct DHT11_Data {
|
||||
uint8_t humid_integral;
|
||||
uint8_t humid_decimal;
|
||||
uint8_t temp_integral;
|
||||
uint8_t temp_decimal;
|
||||
uint8_t crc;
|
||||
};
|
||||
|
||||
void DHT11_run_test(void);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user