1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

drivers/shtcx: fix assertion and shtcx_saul_info idx

This commit is contained in:
Benjamin Valentin 2023-05-31 14:42:44 +02:00
parent d742513b62
commit 7457c4545a

View File

@ -54,7 +54,7 @@
void auto_init_shtcx(void)
{
assert(SHTCX_NUM == SHTCX_INFO_NUM);
assert(2 * SHTCX_NUM == SHTCX_INFO_NUM);
for (unsigned i = 0; i < SHTCX_NUM; i++) {
LOG_DEBUG("[auto_init_saul] initializing shtcx #%u\n", i);
@ -70,7 +70,7 @@
/* Humidity */
saul_entries[(i * 2)+1].dev = &(shtcx_devs[i]);
saul_entries[(i * 2)+1].name = shtcx_saul_info[i].name;
saul_entries[(i * 2)+1].name = shtcx_saul_info[(i * 2)+1].name;
saul_entries[(i * 2)+1].driver = &shtcx_relative_humidity_saul_driver;
saul_reg_add(&(saul_entries[(i * 2)]));