Hi, guys. I'm trying to use the constrain function but i'm getting an error
Here's my code
constrain(vol[0], 0, 127); //vol is a byte type variable
and the error i'm getting
C:\Users\Tomas\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.3\cores\arduino/Arduino.h:95:39: error: expected ')' before '<' token
#define constrain(amt,low,high) ((amt)<(low)?(low):((amt)>(high)?(high):(amt)))
^
c:\ProgramData\Arduino - VSCode\MML_TomasSasovsky\MML_TomasSasovsky.ino:94:1: note: in expansion of macro 'constrain'
constrain(vol[TR1], 0, 127);
^~~~~~~~~