apero du mercredi soir, no bug spotted

This commit is contained in:
phyto 2019-04-04 01:24:40 +02:00
parent e6f4bf7a0f
commit 6583891486
2 changed files with 9 additions and 8 deletions

View File

@ -7,10 +7,10 @@ DATAFILE="serial/foo.dat"
IMAGE="graphe.png"
TMPFILE="/tmp/tmpdata"
tail -700 < ${DATAFILE} > ${TMPFILE}
tail -1200 < ${DATAFILE} > ${TMPFILE}
gnuplot << __EOC__
set term png size 1000,700
set term png size 1400,700
set output "${IMAGE}"
set ytics 2
set xtics

View File

@ -12,6 +12,7 @@ void setup() {
pinMode(LED_BUILTIN, OUTPUT);
Serial.print("\n");
/* XXX */
/* changing the voltage reference of the ADC
* greatly increase the prcision on the limited
@ -32,9 +33,8 @@ void updatevalues(short *ptr)
{
short foo, pass;
for (foo=0; foo<NBVAL; foo++) {
ptr[foo] = 0;
}
for (foo=0; foo<NBVAL; foo++) { ptr[foo] = 0; }
digitalWrite(LED_BUILTIN, HIGH);
for (pass=0; pass<NB_PASSE; pass++) {
for (foo=0; foo<NBVAL; foo++) {
@ -42,9 +42,9 @@ void updatevalues(short *ptr)
delay(100);
}
}
for (foo=0; foo<NBVAL; foo++) {
ptr[foo] /= NB_PASSE;
}
for (foo=0; foo<NBVAL; foo++) { ptr[foo] /= NB_PASSE; }
digitalWrite(LED_BUILTIN, LOW);
}
/* -------------------------------------------------- */
@ -67,6 +67,7 @@ void update_and_send(void)
updatevalues(values);
sendvalues(values);
}
/* ================================================== */
void loop() {