So this is an activity which I though would inspire young people to get involved in taking and processing environment data.
It's goal is to making a boat that can carry environmental sensors to the centre of the Shannon Wetlands ponds.
My thinking being two fish tank water pumps could be the motors with their power controlled by a BBC micro:bit which could receive commands remotely from another micro:bit. The boat could be made of cardboard which is waterproofed by gaffer tape. The motor control board and code from the Kitronix Move mini robot could be re-used.
So it composes of 5 elements:
1) A waterproof hull (cardboard covered with black plastic gaffer tape)
2) A motor (two water pumps taped to the rear of the boat)
3) A receiver that controls the motors (a BBC micro:bit and motor board from a Kitronix Move)
4) A power source on the boat (a 5v USB power bank)
5) A remote control (another BBC micro:bit using tilt control for direction / speed / full stop)
The code had to provide individual power control to two submersed water pumps which provide propulsion for the boat. That is 100% power to both pumps is full steam ahead, 0% to both is full stop and 100% to left pump (starboard) and 0% to right pump (port) would turn the boat left, etc.
The MOVE mini code is a good starting point:
The Kitronix MOVE mini: https://kitronik.co.uk/products/5624-move-mini-buggy-kit-excl-microbit.html
The Servo:Lite motor board can drive up to 1A: https://resources.kitronik.co.uk/pdf/5623-servo-lite-datasheet.pdf
Library to control motor board: https://github.com/KitronikLtd/pxt-kitronik-servo-lite
Looking at their the servos what VCC, GND amd Cobtrol. And looking at the GIT library code this Control wire is drive by:
export function forward(): void {
pins.servoWritePin(AnalogPin.P1, 0);
pins.servoWritePin(AnalogPin.P2, 180);
}
export function backward(): void {
pins.servoWritePin(AnalogPin.P1, 180);
pins.servoWritePin(AnalogPin.P2, 0);
}
export function left(): void {
pins.servoWritePin(AnalogPin.P1, 0);
pins.servoWritePin(AnalogPin.P2, 0);
}
export function right(): void {
pins.servoWritePin(AnalogPin.P1, 180);
pins.servoWritePin(AnalogPin.P2, 180);
}
export function stop(): void {
pins.analogWritePin(AnalogPin.P1, 0);
pins.analogWritePin(AnalogPin.P2, 0);
}
export function neutral(): void {
pins.servoWritePin(AnalogPin.P1, 90);
pins.servoWritePin(AnalogPin.P2, 90);
}
So this the analogue voltage presented to P1 and P2 controls the servo motor.
https://www.ebay.co.uk/itm/284556271865
http://www.ee.ic.ac.uk/pcheung/teaching/DE1_EE/stores/sg90_datasheet.pdf
But for the boat I just want a voltage!
Parts list:
1) 2x DC 2.5V / 6V Small Mini Water Pump Fish Tank Fountain Aquarium Micro Submersible bought from ebay.ie for £3.50 each.
2) Re-used guts of https://kitronik.co.uk/products/5652-move-mini-mk2-buggy-kit-excl-microbit
3) Cardboard and black duck tape
4) 2x BBC micro:bit
5) 2x 5v USB power banks (from Dealz for 1.50 euro each)