Hi, how can I use the ISR(TIMER3_COMPA_vect) from this code: https://www.industrialshields.com/blog/arduino-industrial-1/post/servo-motor-with-arduino-based-plc-104, in the void loop?
If I copy the ISR in the loop, the Arduino IDE shows me these error messages:
Arduino: 1.8.12 (Windows 10), Board: "M-Duino family, M-Duino 21+"
In file included from C:\Users\xt\AppData\Local\Arduino15\packages\industrialshields\hardware\avr\1.1.38\cores\industrialshields/Arduino.h:30:0,
from sketch\m-duino_test_2.ino.cpp:1:
C:\Users\xt\Documents\Arduino\m-duino_test_2\m-duino_test_2.ino: In function 'void loop()':
m-duino_test_2:25:3: error: expected unqualified-id before string constant
ISR(TIMER3_COMPA_vect) {
^
m-duino_test_2:25:26: error: a function-definition is not allowed here before '{' token
ISR(TIMER3_COMPA_vect) {
^