The Airboat Model 4180 was designed and built for the final design project in Embedded Systems Design (ECE4180) at Georgia Tech by Zachary Mathews. It makes use of a GPS and waterproof Li-DAR module to map the floor of a body of non-turbid water. Here's a short demo of the Bluetooth Control. And here's how it's made...
Multithreaded to handle GPS, LiDAR, and Bluetooth control separately. The Airboat Model 4180 uses PIGPIO as the underlying GPIO framework to enable software PWM for DC motor control. In the Git repository, you see a few different class and header files along with the demo and project executables. In order to facilitate use of the PIGPIO library for the purposes of this project, I've written the classes to provide operator overloading and helper functions (position, speed, connect, read, readline). These helped greatly with the organization of the main project.cpp
file.
Aluminum Paint Tray
Backer Rod
Waterproof Glue
Duct Tape
CanaKit Raspberry Pi Zero W Kit
Mini-B USB Breakout
H-Bridge Dual TB6612FNG Motor Driver
DC Motor
Waterproof Servo
Waterproof TFmini Plus Li-DAR
NEO-6M GPS Module
USB to TTL Adapter
Portable Charger
Apply glue below outside rim of paint tray. Stick backer rod to it. Tape each corner to secure while glue dries.
The propeller motor should be mounted dead center in the rear of the boat above the rim of the paint tray.
The rudder motor should be mounted directly below it with the screw dead center.
The LiDAR may be mounted any where the lens is completely submerged and pointing nadir.
Mini-B USB Breakout | Raspberry Pi Zero W | H-Bridge Motor Driver | DC Motor |
---|---|---|---|
3.3V | VCC | ||
GPIO 5 | PWMA | ||
GPIO 6 | AIN1 | ||
GPIO 13 | AIN2 | ||
GPIO 19 | STBY | ||
VCC | VM | ||
AOUT1 | POSITIVE | ||
AOUT2 | NEGATIVE | ||
GND | GND | GND |
Mini-B USB Breakout | Raspberry Pi Zero W | Servo |
---|---|---|
VCC | 5V | |
GPIO 18 | PWM | |
GND | GND | GND |
Mini-B USB Breakout | Raspberry Pi Zero W | TFmini Plus Li-DAR |
---|---|---|
5V | 5V | |
TXD (GPIO 14) | RX (WHITE/BLUE) | |
RXD (GPIO 15) | TX (GREEN) | |
GND | GND | GND |
Raspberry Pi Zero W | USB to TTL Adapter | NEO-6M GPS Module |
---|---|---|
USB | VCC | VCC |
USB | TX | RX |
USB | RX | TX |
USB | GND | GND |
1.) Install Apache -> RaspberryPi.org: Setting up an Apache Web Server on a Raspberry Pi
2.) In airboat_4180
directory run sudo cp -rfv ./html/ /var/www/html/
to copy the webpage and sample data over.
3.) Navigate to the Raspberry Pi's IP address in a web browser. You should see a 3D plot.
In order to use your phone as a Bluetooth remote, download the Android app found here: https://play.google.com/store/apps/details?id=com.hamzaburakhan.btremotecontrolarduino&hl=en_US
Then follow the steps below to pair your Raspberry Pi Zero W.
sudo nano /etc/systemd/system/dbus-org.bluez.service
Add -C to the ExecStart
statement to start the Bluetooth daemon in compatibility mode:
ExecStart=/usr/lib/bluetooth/bluetoothd -C
Add the following statement below the ExecStart
line to enable the SP Profile:
ExecStartPost=/usr/bin/sdptool add SP
Reboot to make changes take effect:
sudo reboot
sudo bluetoothctl
alias raspi0
discoverable on
Now, pair with the device raspi0
in your phone's settings. If asked to verify pairing with a pin, do so.
Emulate a serial port over Bluetooth using the RFCOMM protocol:
sudo rfcomm watch hci0
1.) Select raspi0
from the paired devices list.
2.) Watch the ad (bleh). Then select Tilt Controller
.
1.) Make sure you're emulating a serial port over Bluetooth using sudo rfcomm watch hci0
.
2.) Connect Bluetooth remote app.
3.) In the airboat_4180
directory, build the project using the command make
.
4.) In the airboat_4180
directory, run sudo ./project
and wait for the initialization sequence to finish.
5.) In order to use the mapping function, wait for the message No GPS fix
to go away.
6.) Navigate the area you wish to map.
7.) Close the Bluetooth Controller app to stop the motors.
8.) Shutdown the Airboat 4180 using Ctrl+C.
9.) You may now navigate to your Raspberry Pi's IP address on a web browser and see a map of the lake floor.
The demo simulates movement (GPS data). It is used to test the mapping function where GPS reception is weak to nonexistent.
1.) To run the demo, make sure you're emulating a serial port over Bluetooth using sudo rfcomm watch hci0
.
2.) Connect Bluetooth remote app.
3.) In the airboat_4180
directory, build the demo using the command make demo
.
4.) In the airboat_4180
directory, run sudo ./demo
and wait for the initialization sequence to finish.
5.) Move the boat up and down to emulate a lake bed with varying depth.
6.) When the Finished with sample data
message appears, you may shutdown the Airboat 4180 with Ctrl+C.
7.) You may now navigate to your Raspberry Pi's IP address on a web browser and see a map of the emulated lake floor.