Page 1 of 1

serial communication

Posted: Wed May 01, 2019 3:06 am
by luisaagudelo09
Hi.
I have to do a job, which is to communicate two esp32 to control the speed of an engine.
An esp32 is connected to an LCD and here the power is shown to which the motor is wanted to turn and to the other esp32 the motor is connected.
By means of the keyboard of the computer, the hardness cycle can be selected.
if (data == '0') dutyCycle = 0;
     if (data == '1') dutyCycle = 32;
     if (data == '2') dutyCycle = 64;
     if (data == '3') dutyCycle = 128;
     if (data == '4') dutyCycle = 192;
     if (data == '5') dutyCycle = 255;
I am new with this microcontroller, I hope you can help me. Thank you!
Pd: I do not speak English, I speak Spanish and use a translator.