The Discount Mars Rover Project


Now the project really gets started: We need a onboard - computer to test the motors. My choice for the controller board is an ARDUINO MEGA clone. The main reason for the MEGA version is the huge number of I/O Pins: It provides 54 digital IN/OUT pins (14 of these can generate PWM signals) and 16 analog IN pins as well as 4x UART and (important!) one I2C bus. I do not yet know how many servo motors and sensors I want to use with this robot and try to avoid that we run out of I/O channels as the project grows.

We also need a driver for the motor: The cheapest solution is a H-BRIDGE like the L298D for just 2,90€. It can handle 2 Amps, which is on the edge but since each L298D has two bridges, we can use both of them for one motor. Even if the selected motor needs just 450 mA in normal operation, the starting current may peak up to 2400 mA, therefore I will use both bridges. This gives us a combined capacity of 4 Amps which should be more than sufficient.

Last but not least our rover will need motors to drive around. I use a gearmotor for 12V which will run with 76 RPM idle and approximately 50 RPM under load. Make sure tht the motor has a 6mm shaft - the entire weight of the rover will rest on the shafts of the drive motors!

For this step I have just bought one motor and one H-bridge to see if everything is working fine. If you use the same motor version and H-bridge as I did, you may order 6 motors and also 6 L298D to save shipping costs.

Which parts do I need?

1 x Arduino MEGA board or compatible
1 x L298N H-bridge
1 x DC motor (up to 12 V)
Software for the drive test. Use the code for STEP 5.

Which software do I need?


What needs to be done?

Connect your board via USB to your computer. Install the Arduino IDE and get familiar with it. Sorry that I will not provide a complete tutorial how to get startet with Arduino programming, but there are many tutorials in the web. Connect the L298N to a 12 V power supply, connect one PWM IN on the L298N with one of the PWM OUT pins of the Arduino MEGA (e.g. 12) and connect two digital pins with the pin 24 und 25 on the L298N.

The SOFTWARE FOR STEP 5 allows you to send commands via the serial monitor of the Arduino IDE. Use input "1" to drive forward, "2" for the opposite direction and "3" to stop the motor. If you are happy with the results you can directly continue with STEP 3 A



To be able to get up to 4 A from the L298D we will use both bridges for one motor. You need to get the PWM signal from the Arduino to both pins, ENA und ENB. Furthermore you need to set the HIGH and LOW pins for both H-bridges simultaneously (I have just split the cables comming from Arduino to get the same signals on both bridges).

How much do I have to pay?

  The board costs less than  10,00 €,
+ a L298D around              3,00 €
+ the motor comes for        11,90 €
  Total                      25,00 €