At the first program, I sent the following data:
SK,2000,SETLAIN,1,SETGT,1,SETTEMP,1,SETPH,1,SETAT,1,SETLEMBAB,1,SET,1,SETK,1,SETLL,0,
This data was sent when the arduino processed the delay in 5 second in the void kontroler ().
When the ardino has finished running the void kontroler (), it supposed to run void store ().
Normally, the data supposed to be processed in the void store()
and it should be appeared on the serial screen when currentCommand == 20.
The problem: it did not show up in the screen.
My expectation: to see
SK,2000,SETLAIN,1,SETGT,1,SETTEMP,1,SETPH,1,SETAT,1,SETLEMBAB,1,SET,1,SETK,1,SETLL,0,
2000,1,1,1,1,1,1,1,1,0
in the serial screen
A different result happened when I used the second program (after ledpin 13 was active and was doing delay), I sent the data :d.
After the arduino finished with the delay, the data was processed in the void store () and it was successfully appeared in the serial screen.
How did it happen?
Why it gave a different respond?
this is my first program and my second program
second_program.txt (378 Bytes)
first_program.txt (9.35 KB)