diff options
author | root <root@ka-ata-killa.ourano.james.local> | 2021-02-17 18:33:49 +0000 |
---|---|---|
committer | root <root@ka-ata-killa.ourano.james.local> | 2021-02-17 18:33:49 +0000 |
commit | c994c3323ee1b0d19faa86ebe26a01d566b86eaa (patch) | |
tree | 6dd2b0ee878938f13b5cc2429f9092ad659680ad /humidity_sensors/app/main.c | |
parent | 1f91e592c0b97dc315335417f323d31ca028782a (diff) | |
download | heating-c994c3323ee1b0d19faa86ebe26a01d566b86eaa.tar.gz heating-c994c3323ee1b0d19faa86ebe26a01d566b86eaa.tar.bz2 heating-c994c3323ee1b0d19faa86ebe26a01d566b86eaa.zip |
stm8 humidity sensor
Diffstat (limited to 'humidity_sensors/app/main.c')
-rw-r--r-- | humidity_sensors/app/main.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/humidity_sensors/app/main.c b/humidity_sensors/app/main.c index 6f15cdf..6c9e602 100644 --- a/humidity_sensors/app/main.c +++ b/humidity_sensors/app/main.c @@ -15,9 +15,11 @@ main (void) sht20_reset(); - enableInterrupts (); + enableInterrupts(); for (;;) { + sht20_setup(); + printf ("$SNTHD,%s,%s\n", sht20_temp_s(), sht20_humid_s()); while (!uart_rx (&c)) { @@ -25,8 +27,8 @@ main (void) sht20_reset(); } - delay_ms(10); + delay_ms (10); halt(); - delay_ms(10); + delay_ms (10); } } |