I am struggling on how to get an analog output from a serial message
I have spent all the afternoon trying but no luck at all…
Here is the code that I have written:
int test;
void setup()
{
Serial.begin(9600);
}
void loop(){
while (serialAvailable()){
test = serialRead(); //read Serial
serialWrite(test);
analogWrite(9,test);
}
}
For some reason the analogWrite function does not want to read the test variable value which is the one that I send through serial […]
