To accommodate sufficient sensors (laser rangefinder, line sensor, 9DOF IMU) and control two motors I can't see any other way than using two Pi 3. The first drives the motors, and senses the line. The second senses distance and heading using the range finder and IMU. The driving Pi is also set up as a wireless access point for for the second pi to communicate with it using MQTT.

I've no problem software wise, but mounting two Pi 3 on a single chassis is proving a trial. The driving Pi uses a PiJuice battery which allows me to mount a CamJam Edukit 3 motor controller on top of it and connect a line sensor. For the sensing Pi 3 I have a Crazepony-UK Lithium Battery Expansion Board as the power source with the sensors mounted on a PiMoroni Breakout garden. Both Pi 3s extend to a height of around 3 to 4 inches and together with a 6V battery power pack to power the motors have to fit on a single chassis.

Has anyone else built something similar or ca useful advice on how to mount such hardware onto a suitable chassis?

  • 1
    Why do you need two Pi? You have at least 26 GPIO to play with.
    – joan
    Feb 29, 2020 at 16:17
  • also, if you really need two pi's (and I can't see why you would), is there any reason one of them can't be a pi zero/zero(w)? Mar 1, 2020 at 1:57
  • The CamJam Edukit 3 motor controller is stacked on the GPIO passed through the PiJuice UPS on the first Pi. That in turn exposes sufficient GPIO pins to mount the line sensor, but not the BreakoutGarden which needs a full GPIO to be mounted on.
    – Nick
    Mar 1, 2020 at 18:13
  • The CamJam Edukit 3 motor controller is stacked on the GPIO passed through the As for a Pi Zero, I have considered such but I'm not convinced there will be enough power esp. if I need to do any onboard signal processing to clean up the sensor output from the IMU ie fusing the IMU's gyroscope, accelerometer and magnetometer. The driving Pi also needs power for reinforcement learning for autonomous control.
    – Nick
    Mar 1, 2020 at 18:20


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.