This Arduino project has the target of full autonomous driving around. To make it more usable for others, I divided it into three subproject (might be changed). As a plattform I am using a modified Lego Set 42043 "MERCEDES-BENZ AROCS 3245", which does not contains Power Functions for driving out of the box, but is large enough to be modified in a lot of ways.
- Manual App: basic hardware and App setup to have fun with, only manual control
- With Sensors: extended setup with distance sensors, only manual control
- Mapping the surroundings: creating a map of the appartment when driving around
- Autonomous driving: from a to b, drive to the fridge and get a 🍺
Please check out these projects, since this project is based on it (especially on the first project of Patrick Müller)
- Take Control Over Lego Power Functions @ github
- On the hardware side I basically added lights and distance sensor, modified it to single power source and corrected a few minor things
- Most changes are on App, where data is now transfered back to the app and more buttons for lighting were added
- Serial to Parallel Shifting-Out with a 74HC595
- Driving around controlled vie bluetooth by Android App
- Automated breaking when obstable
- Manual Lighting
- White front and red taillights
- Blue flashlights on roof
- Yellow blinking warnlights
- Automatic Lighting
- Red breaklights
- Yellow blinking when turning left and right
- App Buttons
- Bluetooth: connect to Arduino
- Servo: switch servo direction
- STOP: stop truck immediately
- Flash Top: en-/disable roof flashing lights
- Warn Blink: en-/disable all blinking lights on sides
- Head/Tail: en-/disable head- and taillights
- Touchfield: steer and speed control
Parts:
- 1x Arduino UNO
- 1-2x Breadboards
- 1x Motor driver L293D
- 1x Shift register 74HC595
- 1x Bluetooth HC-05
- 12x LEDs of different colors, 3mm or smaller
- 8x 220Ω resistances
- 3x 1KΩ resistances
- 1x 9V battery connector to cut
- 2x Logo Power Functions Extension to cut, e.g. 8871 for 50cm
- 1x Lego car or truck with at least one Power Functions servo for steering and one motor
- A lot of wires, I used approx. 7 meters in total on the Lego truck
Upload the code:
- Arduino IDE to upload the code
- Install the App on Android phone or tablet
To edit the App:
- MIT App Inventor to open the App code
- Photos of everything
- Apps
- "Real" Android App in Java or Kotlin
- iOS App
- At least 4 more distance sensors
- 2x front corners (45°)
- 2x back corners (45°)
- front bottom (maybe, for low obstacles like higher carpets)
- back (maybe, depending how it turns out driving around)
- GPL3+
- Trademarks belongs to their respective owners