Whale Watcher - Arduino + MQTT

by CasperEnvy in Design > Software

51 Views, 2 Favorites, 0 Comments

Whale Watcher - Arduino + MQTT

WhatsApp Image 2026-04-03 at 16.51.57.jpeg

For this project, another student and I designed and created a device that could be used along shorelines for spotting whales or other sea life. The aim of this product is to draw more people to the ocean and to encourage people's curiosity about wildlife. This design is simple yet flexible, with input and output that are physically visible and communicate over the cloud.

Supplies

Electronic

Input:

  1. RFID reader
  2. RFID fob
  3. Wemos board with a cable
  4. Breadboard
  5. Jumper cables
  6. 2 LEDs, 1 red and 1 green

Output:

  1. Wemos Board with a cable
  2. Buzzer
  3. 180 Servo
  4. Bread Board
  5. Jumper cables


Physical Materials:

  1. 1 A3 sheet of MDF
  2. 2 A4 sheets of foam board
  3. double sided tape
  4. velcro
  5. fabric
  6. Hot Glue
  7. Paint
  8. pla [not required]

Tools:

  1. 3D Printer [not required]

Coding

For this step, we split the entire process into two parts, the input and the output. For the input, an RFID scanner is used to send out a value to the cloud under the topic 'Whale Watchers' using a prechosen RFID fob [which will be embedded into a bracelet.] When the output device picks up this value, it will set off a buzzer [telling the user that the device has been activated], the servo will rotate 180 degrees and another statement will be posted in the cloud stating a whale has been spotted. A flag will be connected to this servo, over time the servo will go back down and another buz will notify that time has passed and the whale is likely to have left.


Input:

Starting off, we needed to focus on coding the RFID on a regular arduino to ensure that it was functioning as intended before mixing it in with other, more complex code. Once we were sure that the intended physical function was working as intended, that was when we integrated it within the MQTT function.

Output:

Once the input was completed, we then shifted to working on the output. The main concern with this aspect of the project isn't just ensuring everything is functioning, but that it's all functioning in the right order and in time. Arduino code works in a list format - reading from top to bottom - so as long as everything is coded in the right order, that should be fine. Note: arduino measures time in milli-seconds [1s = 1000ms]. If you wish to alter the code in any way time wise, ensure you keep that conversion in mind.

Wiring

c947b8b5-ac37-46ca-b1ca-4ce7a1602939.jpg
1e8e44ac-dd4e-4045-961b-b85358b1ccee.jpg
a57c462e-5b60-42ca-9aa3-b5f530c11f27.jpg
Picture4.png

Coding is useless if the wiring isn't perfect, falty wiring can lead to damaged componants. It's always best to start out the wiring using larger boards, that way it's easier to keep track of what wire goes where. Once satisfied with the connections, you can decide whether or not it's worth changing to a different sized bread board, keep the original size or attempt to solder a more perminant solution. However it is that you decide to move forward, it's vital to have a final decision before you move on to designing the casings. Knowing exactly where everything will go saves time in recreating/ resizing either the internal componants or the shell.

Note: if you're testing componants using a regular arduino, be sure to change the digital pin names. For regular arduinos, the pins are labled from 1 to 13, whereas weemos pins are labled D1 to D8. Both boards have A0.

CAD + 3D Printing [Optional]

Screenshot 2026-04-03 163202.png
Screenshot 2026-04-03 161805.png
Screenshot 2026-04-03 164412.png

Now this aspect of the project is on the optional end, as the size and shape of the casing is up to the individual to decide. It's not a requirement to use the exact same processes as us - physical prototypes could do or simple pen and paper - but these are the methods we utilised to come up with the visual aspect.

Before splitting into the methods of creation, we generated 3D models using solid works of the main visual componants; that being the casing for the RFID scanner, the fob holder for the braclet and the flag that specificallt fit's the servo motor. Of all of these, the main concern was ensuring the flag remained attached to the servo at all times, so 3D printing is the preferred method of making. That being said, the method of creation and materials are flexible for the individual. Alternative materials would be to use drift wood or recycled plastic from the ocean [that is if you're wanting to look for a more ocean based theme].

Physical

Picture1.png
96c92a51-8c88-41d7-a311-42acda49a784.jpg
Picture2.png

RFID Scanner

The design for our RFID scanner is intended to be a scaled down model of a much larger installation. The idea is that these installations would be dotted about arounf the beach. The design is of a whale's tail and was made using layers of cut out MDF and later painted with acrylic paints. Behind the front of the scanner, a foam box was made to fit exactly behind it to house the electrical componants.

Alert System

For our alert system, we used foam board for the casing, with minimal adhesive used to keep it together. A hole is cut out in the front to allow the front of the servo to fit through without the entire thing falling through. Doublesided tape is used to hold everything in place inside.

Bracelet

Finally, for the bracelet, a simple casing was 3D printed that fit the fob perfectly. Once the fob was inserted, fabric [cut into 2 strips and with velcro on either side] was stuck to either side of the frame.