add config array

This commit is contained in:
yelvlab 2024-12-18 20:05:35 +08:00
parent a4ac36de11
commit 58c8ac63fd

View File

@ -39,6 +39,9 @@ void led_config(void) {
nvic_irq_enable(LED_IRQ, 2);
}
uint8_t RCOUNT_ALL[3] = {SET_CONVERSION_TIME_REG_START, 0x05, 0x36};
uint8_t SETTLECOUNT0_ALL[3] = {SET_CONVERSION_TIME_REG_START, 0x05, 0x36};
/*!
\brief main function
\param[in] none
@ -58,24 +61,14 @@ int main(void) {
delay_ms(500);
// int result = 0;
// uint16_t data = 0;
// uint16_t device_id = 0;
// LDC1612_IIC_read_16bits(READ_DEVICE_ID, &data);
// printf("result = %d\r\n", result);
uint16_t device_id = 0;
device_id = ldc1612_get_deveice_id();
printf("device id = 0x%x\r\n", device_id);
// delay_ms(1000);
// LDC1612_IIC_read_16bits(READ_DEVICE_ID, &device_id);
// printf("Manufacturer: 0x%x\r\n", data);
// printf("Device: 0x%x\r\n", device_id);
ldc1612_iic_get_sensor_infomation();
while (1) {
delay_ms(1000);
printf("OK!!!\r\n");
// delay_ms(1000);
// printf("OK!!!\r\n");
}
}