AVBotz

Marlin V2

🐟 AVBotz Marlin V2

Marlin V2 represents our team's best foot forward as the sum of our engineering experience gained over the past 21 years. Marlin V2's name is fitting in its speed, size, and agility; updated internals, software, and hardware make it our most powerful submarine. Marlin V2 is designed to compete in the RoboSub Competiton and is equipped with sensors, actuators, and thrusters to interact with its surroundings underwater. The measurements taken by our positioning and vision systems allow Marlin V2 to complete various competition tasks such as dropping objects into bins or navigating to specific locations underwater.

This page overviews Marlin V2’s existing specifications and recent changes contributed by each of the our subteams. Special thanks to all of our sponsors who contributed hardware and monetary value to help bring Marlin V2 to life.

32 meters

Maximum Depth

3,500+

Lines of Mission Code

4 m/s

Top Speed

5 years

In Development

Subdivision Overview

AVBotz's technical subteams include the electrical, mechanical, and software systems of Marlin V2. Each team's role is described in detail below.

Mechanical

Mechanical's responsibilities are to design, build, and maintain the vehicle. With the help of Onshape, Solidworks, and Datron, we are able to model and fabricate much of our vehicle's parts, while teaching our members many engineering skills and processes along the way. Every year, the mechanical team focuses on the designs for yearly task changes and the construction of competition props. These mechanisms to complete each task must be designed in such a way as to maximize the number of points we gain at competition. In order to ensure this, the mechanical team goes through rigorous prototyping and multiple design iterations to create the most efficient and reliable mechanism.

Electrical

Electrical is responsible for the design and application of equipment and implementation of the electrical circuits that bring the vehicle to life. Electrical primarily works within the hull, piecing together the circuit boards and managing power delivery make sure that the subsystems can communicate with each other safely and reliably.

Software

Responsible for the design and implementation of the software and mission code that allows Marlin V2 to operate with autonomy. The major software components include: Mission Planning, Control Systems, Computer Vision Machine Learning, and Navigation.

Mechanical Team

Mechanical is responsible for the parts outside of the main body (the tube), as well as the support inside. Its goal is to improve the capabilities of the sub’s hardware and to help maintain the sub in its working capacity. Using the CAD software, we are able to design, create, and test new components such as the rack and the grabber easily, as well as save our designs for future club members to reference.

Marlin V2’s hull is a 9.5-inch diameter acrylic tube, 25.875 inches long, and sealed by two anodized 6061-T6 aluminum endcaps.

The front endcap is sealed to the end of the tube with 3M DP420 epoxy, and the front camera dome is sealed using a face o-ring. An aluminum collar was added to the back of the tube, so that the back endcap seals to aluminum instead of casted acrylic, ensuring seal integrity.

The back end cap uses o-rings 3% smaller than normal specification and was given a 10-degree chamfer to ease insertion and extraction of the electronics rack. Four spring-draw latches on the rear of the hull help keep the back endcap seal watertight by preventing the endcap from sliding out of the tube. Thirteen waterproof SubConn connectors interface between Marlin V2’s internal and external electronics, and can be quickly detached and reattached without disrupting the watertight seal. Two aluminum mounts attach the hull to the horizontal plane of the submarine.

Marlin V2 maneuvers using eight BlueRobotics T200 thrusters, chosen for their high thrust and efficiency. Four are arranged horizontally at 45-degree angles and control strafe, yaw, forward, and reverse movements, while the other four are oriented vertically and control depth, pitch, and roll.

The frame is built from 6061-T6 aluminum components for high strength and relatively low weight. Sheets and L-pieces are machined using CNC machines and standard industrial tooling machines and then anodized with a type II coating. Modular Panels were also integrated to easily adapt the frame to changes that need to be needed. These panels can easily be printed or machined to fit our new needs. The top plane has five while the front and back legs each have one giving us a total of seven spots to mount components. With the 3D-printed modular panels, all of our new parts like grabbers and torpedoes can easily be added in multiple orientations and locations on the submarine creating more possibilities.

Hydrophone Enclosure (left) and Battery Box (right)

Hydrophone Enclosure (left) and Battery Box (right)

Electrical Team

This year, electrical improved Marlin V2’s electrical internal infrastructure. This system is intended to be more powerful and capable than any previous system to accommodate for this year’s mechanical and software changes. To accomplish this, Marlin V2 has a more powerful main computer and a revamped acoustic system.

This year, two 4S batteries are powering the electrical system. The batteries are routed to a 200A fuse that goes to the relay for our thrusters, activated with an external kill switch. Another 16V line goes from our 200A fuse to our fuse box, where the rest of our components branch off from. One of these components is our Cincon, a 16V to 12V DC-DC converter, used to power our relay, down camera, Jetson computer, Ashcroft pressure sensor, and DVL. A 12V line goes from the fuse box to a buck converter, which steps it down to 5V to power our AHRS and Nucleo hat. Another 12V line goes to a separate buck converter which steps the voltage down to 7V to power the three servos in our system.

A Nucleo-144 H7431 microcontroller interfaces with all of our low level control as well as most of our signal distribution the electrical signal system with its STM32 chip. Devices like our DVL and AHRS use UART to communicate with the MCU. Our ESCs are daisy chained with CAN, which also connects to our Nucleo. We have two pressure sensors, a Bar-30 from BlueRobotics that uses I2C communication and a K1 pressure sensor from Ashcroft, read by an analog pin on the microcontroller. Finally, our external tether, down camera, and DVL (web GUI) are all routed through Ethernet to the Edge Router, which is connected to our Jetson.

Our main computer is the Jetson Orin AGX Developer Kit from Nvidia. It has a 12-core Arm Cortex CPU and a GPU with Nvidia Ampere Architecture with 2048 Nvidia CUDA cores. We mainly use the Jetson for high-level control like vision system and machine learning. Our microcontroller unit, the Nucleo-144, is in charge of low-level control. Running on an STM32 chip and an ARM Cortext-M7 CPU, the Nucleo is responsible for most of the communication within the electrical system as well as interfacing with all of our sensors including our DVL, AHRS, pressure sensor, etc. Most importantly, it controls our thrusters through a daisychained CAN line to the ESCs.

The main computer on our AUV Marlin V2

The main computer on our AUV Marlin V2

This year the electrical team began many different projects to enhance our system. One of our main focuses this year was the 'hat' (pictured below) that sits directly on top of our microcontroller, which gave us more connections and more stable connections to our external devices. We designed this hat with KiCAD to include connections for CAN, SPI, UART, I2C, and GPIO pins. The hat uses JST connectors which are far more reliable than the regular pin headers we used in last year's competition. Another project we attempted this year was an ESC backplane system. Unfortunately, due to space constraints, we weren't able to implement it. The ESC Backplane comprises of two sets of motherboards with four daughterboards each, each one for a pair of thruster and ESC. The backplane was meant to further simplify our motor control for our ESCs, allowing us to decrease the downtime of a broken thruster or ESC through the highpower Samtec connectors. The backplane allowed communication through CAN (daisychained throught he PCB), UART, and PWM. Finally, we also designed a sensor stack which monitors all of the vitals in our submarine through an STM Blue Pill. The Blue Pill is then connected to the Jetson, which allows us to read the status of voltage levels for each battery cell, temperature, humidity, and leak detection whent he sub is tethered.

The PCB for Electrical's hat

The PCB for Electrical's hat

Software Team

The software subdivision designs, implements, and maintains all programmable elements of the AUV. It strives to create a robust system that is capable of adapting to different conditions and performing complex actions. In order to complete this, the subdivision designs and improves algorithms to manage various aspects of the AUV’s operation, including mission planning, navigation, localization, machine vision, and signal processing.

Marlin V2 runs two main code-bases at the same time. Boops-Boops is the higher level program that the Jetson executes, which controls sub trajectories, handles vision detections, and directs the AUV through the course. Maritime is the lower level program that is run on our Nucleo F767ZI microcontroller, which connects to our thrusters, Doppler-Velocity-Log, Attitude Heading and Reference System, pressure sensor, and kill switch. While Boops-Boops sends high level commands, maritime implements them by running a PID control program to send the appropriate thrusts to each thruster to move the submarine to its waypoint.

To monitor the submarine, we employ a web graphical user interface (GUI), that displays camera image feeds, the sub’s position and orientation in the water, and a remote control interface used when collecting images.

To control Marlin V2 with increased precision, the lower-level control program now implements a cascade PID loop, with position and velocity controllers. The output of the position controller on six axes, one for each degree of freedom, serves as the velocity setpoint. The output of the velocity controller or the velocity error, then becomes the force and torque setpoints on each degree of freedom. This array of force and torque setpoints is then mapped to provide a thrust value for each thruster to direct the submarine to correct its position and orientation error and converge on its waypoint.

To navigate through the course, Marlin V2 employs a vision pipeline of image acquisition, filtering and color correction, and OpenCV image processing to detect contours or PyTorch machine learning detection. Some tasks require OpenCV to determine the orientation, such as path markers, while others require machine learning for more complex image recognition. By combining in-house color correction algorithms with the upgraded YOLOv8s machine learning object detection model, this allows our AUV to see at increased distances with magnified accuracy and speed.

Unfiltered image

Unfiltered image

Filtered image

Filtered image

The simulator remains an integral tool for the software team, as it allows for instant debugging and validation of new navigation and vision detection code. By running Gazebo and designing the latest competition’s props according to their released specs, we can simulate competition settings to develop mission and motor control code to traverse the course. It serves as an invaluable tool, as it allows in-water pool testing sessions to be used primarily for validation of approaches that have already been tested in the simulator.

Marlin V2 in the Simulator

Marlin V2 in the Simulator

Mission generates a list of goals to complete throughout the competition run. Each goal contains a set of instructions, location, and point value. Based on the location of both the sub and the goal, we can compute an estimated time to completion for each goal, and visit the goals in an optimal fashion, maximizing our point value. Once we select a goal to complete, mission tells the corresponding vision function to start returning observations.

Marlin V2's Main Specifications

Weight (in air)

36 kg (80 lbs)

Hull

24 cm (9.5 in) diameter acrylic tube

Dimensions

Length: 0.95 m Width: 0.86 m Height 0.56 m

Propulsion

8x VideoRay M5 Brushless Thrusters

Power

2x 22.2V 16,000 mAh LiPo Batteries (in series)

Underwater Connections

SubConn Power, Circular, Micro Circular, Ethernet, and Coax series

Cameras

1x 1.3 MP Point Grey Blackfly machine vision cameras w/ Theia Technologies SY125M lens

1x 20MP Point Grey Blackfly machine vision camera w/ Computar V0828-MPY lens

Navigation Sensors

Pressure Sensor (Ashcroft Model K1) AHRS (PNI TRAX AHRS Module) Hydrophones (4x Teledyne Reson TC4013)

Main Computer

Intel i7-4790T on Jetway NG9J-Q87 Mini ITX 16GB DDR3 RAM 1TB mSATA SSD

Embedded Computer (Control)

ATmega 2560

Data Acquisition and Signal Processing

Teensy 3.6

AVBotz Logo

© 1999-2024 AVBotz, Amador Valley High School

All materials presented on this site are intended for educational purposes.