33 #ifndef CH201_GPR_STR_H_ 34 #define CH201_GPR_STR_H_ 41 #define CH201_GPR_STR_REG_OPMODE 0x01 42 #define CH201_GPR_STR_REG_TICK_INTERVAL 0x02 43 #define CH201_GPR_STR_REG_LOW_GAIN_RXLEN 0x04 44 #define CH201_GPR_STR_REG_PERIOD 0x05 45 #define CH201_GPR_STR_REG_CAL_TRIG 0x06 46 #define CH201_GPR_STR_REG_MAX_RANGE 0x07 47 #define CH201_GPR_STR_REG_INTCFG 0x08 48 #define CH201_GPR_STR_REG_THRESH_LEN_1 0x09 49 #define CH201_GPR_STR_REG_TX_LENGTH 0x10 50 #define CH201_GPR_STR_REG_RX_GAIN 0x11 51 #define CH201_GPR_STR_REG_CAL_RESULT 0x0A 52 #define CH201_GPR_STR_REG_THRESH_1 0x0C 53 #define CH201_GPR_STR_REG_THRESH_0 0x0E 54 #define CH201_GPR_STR_REG_READY 0x14 55 #define CH201_GPR_STR_REG_TOF_SF 0x16 56 #define CH201_GPR_STR_REG_TOF 0x18 57 #define CH201_GPR_STR_REG_AMPLITUDE 0x1A 58 #define CH201_GPR_STR_REG_DATA 0x1C 60 #define CH201_GPR_STR_MAX_SAMPLES (290) 62 #define CH201_GPR_STR_THRESHOLD_NUMBER 2 64 extern const char *ch201_gpr_str_version;
65 extern const uint8_t ch201_gpr_str_fw[CH201_FW_SIZE];
67 uint16_t get_ch201_gpr_str_fw_ram_init_addr(
void);
68 uint16_t get_ch201_gpr_str_fw_ram_init_size(
void);
70 const unsigned char * get_ram_ch201_gpr_str_init_ptr(
void);
72 uint8_t ch201_gpr_str_init(
ch_dev_t *dev_ptr,
ch_group_t *grp_ptr, uint8_t i2c_addr, uint8_t dev_num, uint8_t i2c_bus_index);
Chirp SonicLib public API and support functions for Chirp ultrasonic sensors.
Chirp sensor device structure.
Definition: soniclib.h:349
Chirp sensor group configuration structure.
Definition: soniclib.h:329
Internal definitions for the Chirp CH201 ultrasonic sensor.