Lucas successfully managed to operate both the motor and the servo
22 Views


Important Note ⚠️
Make sure the Arduino is connected to the Raspberry Pi via USB.
If not connected, pressing W, A, S, D keys will not work because no signal is sent to the Arduino.
Open the provided LucasApp.txt document file.
Copy all the code inside the file.
Paste the code into your Raspberry pi.
save it as a .py file (example: main.py).
/*
RC Robot - Arduino Uno + L298N
Commands from serial (USB from Raspberry Pi):
W = forward
S = backward
A = turn left (pivot)
Copy all the code here
Paste the code into your Arduino IDE.
Make sure to select the correct board and port, then upload the code to your Arduino.