Доблена запись по I2C, лидар переведён на UART
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
#define USART3_FRAME_SIZE 9
|
||||
#define LIDAR_MIN_DIST 0.01f
|
||||
#define LIDAR_MAX_DIST 40.0f
|
||||
#define TF02_I2C_ADDR 0x10
|
||||
|
||||
typedef struct
|
||||
{
|
||||
@@ -35,6 +36,9 @@ void USART3_IRQHandler();
|
||||
void lidar_update(lidar_data* lidar);
|
||||
|
||||
void lidar_i2c2_init();
|
||||
void lidar_i2c2_update();
|
||||
static void i2c2_wait_txis();
|
||||
static void i2c2_wait_stop();
|
||||
static int i2c2_write(uint8_t addr, uint8_t *data, uint8_t size);
|
||||
void tf02_force_uart();
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user