You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
560 B
Arduino
35 lines
560 B
Arduino
2 years ago
|
void periodic_10ms(){
|
||
|
msCnt += 10;
|
||
|
|
||
|
if(!busy){
|
||
|
// Call a function every 10ms
|
||
|
read_analog(Values_AI, Size_AI);
|
||
|
read_mc9(Values_PV, Size_PV);
|
||
|
|
||
|
// Call a function every 50ms
|
||
|
if (msCnt % 20 == 0){
|
||
|
|
||
|
}
|
||
|
|
||
|
// Call a function every 50ms
|
||
|
if (msCnt % 50 == 0){
|
||
|
|
||
|
}
|
||
|
|
||
|
// Call a function every 100ms
|
||
|
if (msCnt % 100 == 0){
|
||
|
|
||
|
}
|
||
|
|
||
|
// Call a function every 500ms
|
||
|
if (msCnt % 500 == 0){
|
||
|
read_mc9_req();
|
||
|
}
|
||
|
|
||
|
// Call a function every 1000ms
|
||
|
if (msCnt > 1000){
|
||
|
msCnt = 0;
|
||
|
}
|
||
|
}
|
||
|
}
|