X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=int%2Fsds.c;h=90617b1224aa08ad3e8f60ad6bf4c12a5617ea5b;hb=3c04b0a726017a3c351df574adc8ddab94db541f;hp=b424ff713a57dc50f862388bf5be132e65ba0472;hpb=fb5465ae10e39a9505634e0aaf8e1cab9710f5d7;p=mTask.git diff --git a/int/sds.c b/int/sds.c index b424ff7..90617b1 100644 --- a/int/sds.c +++ b/int/sds.c @@ -1,7 +1,7 @@ #include #include -#ifndef STM32F767xx +#ifndef STM #include #include #endif @@ -52,8 +52,6 @@ bool sds_update(void) sdss[cs].value = read16(); debug("Received sds update %d: %d", sdss[cs].id, sdss[cs].value); - printf("Received sds update %d: %d", - sdss[cs].id, sdss[cs].value); return true; } } @@ -71,10 +69,12 @@ void sds_publish(int id) write_byte(sdss[cs].id); write_byte(sdss[cs].value/265); write_byte(sdss[cs].value%265); + write_byte('\n'); return; } } debug("SDS identifier unknown: %d", id); + die(""); } int sds_fetch(int id) @@ -84,6 +84,7 @@ int sds_fetch(int id) if(sdss[cs].used && sdss[cs].id == id) return sdss[cs].value; debug("SDS identifier unknown: %d", id); + die(""); return 0; } @@ -97,4 +98,5 @@ void sds_store(int id, int val) } } debug("SDS identifier unknown: %d", id); + die(""); }