TTS/Core/Inc/HTPA_32x32d.h

41 lines
960 B
C
Raw Normal View History

2023-03-25 13:15:31 +01:00
/**
* @file HTPA_32x32d.h
* @brief Header for HTPA 32x32d infrared array sensor library
* @author Tim-Erik Düntzsch t.duentzsch@fasttube.de
*
* @date 25.03.2023 - first implementation (untested)
*
* @todo finish HTPA_ReadBlock function
* @todo add calibration function
* @todo add temperature conversion function
*
* @test communication and readout
*
* @version 0.1
2023-03-24 21:42:21 +01:00
*/
2024-02-26 13:31:39 +01:00
#include <stdbool.h>
2023-03-24 21:42:21 +01:00
#ifndef INC_HTPA_32X32D_H_
#define INC_HTPA_32X32D_H_
2023-03-25 13:15:31 +01:00
/// @brief HTPA status register struct
2023-03-24 23:23:49 +01:00
typedef struct {
2023-03-25 13:15:31 +01:00
uint8_t block; // currently selected block
bool vdd_meas; // selection whether first two bytes are VDD or PTA
bool blind;
bool eoc; // end of conversion flag
} HTPA_Status;
2023-03-24 23:23:49 +01:00
2024-03-09 15:33:12 +01:00
2023-03-24 21:42:21 +01:00
void HTPA_Init(I2C_HandleTypeDef *);
2024-03-09 15:33:12 +01:00
void HTPA_ReadSensor(void);
void HTPA_WriteRegister(uint8_t address, uint8_t byte);
void HTPA_ReadRegister(uint8_t address, uint8_t* pData, uint16_t length);
void HTPA_GetStatus(void);
2023-03-24 21:42:21 +01:00
#endif /* INC_HTPA_32X32D_H_ */