Design and development of modular magnetic bio-inspired autonomous underwater robot – MMBAUV

This paper describes the design and construction of a magnetically coupled modular bio-inspired underwater robot named the Modular Magnetic Bio-Inspired Underwater Vehicle (MMBAUV). Designed to form a traveling wave to mimic efficient Body Caudal Fin (BCF) swimming and manoeuvring, its modularity allows for flexible system setup and offers an opportunity for redundancy and cost reduction through a common design structure. The specific feature of this design presents a novel application of a permanent synchronous magnetic coupling between neighbouring modules with a rotational degree of freedom (DoF). The actuated magnetic coupling provides a reliable and low maintenance solution to the fundamental issues of water tightness of flexible underwater structures. When encountering extreme conditions, the magnetic coupling allows the safe decoupling of the modules increasing the survivability of the robotic system. Presented lab testing results demonstrate the function of the design and provide initial evidence of its thrust generation and manoeuvrability.


Introduction
Growing offshore activities in the construction and operation of, for example, renewable energy sites and fossil fuel decommissioning sites have driven interest in robotic systems able to autonomously carry out monitoring and intervention tasks.Capable robotic systems promise to reduce costs through reliable and repeatable task execution while being deployed continuously with the ability to recharge and exchange information at a local dock.As a result, human presence can be reduced, mitigating the dangers to human life of operating in harsh sea environments.
Bio-inspired autonomous underwater vehicles are designed to mimic the high efficiency abilities of underwater creatures.Fish amongst other natural swimmers are known to manoeuvre through tight spaces with low noise and high efficiencies.Next to active muscle actuation many species make use of flexible appendages.Swimming abilities developed under evolutionary pressures suggest they are optimal for specific physiological features and the environment.Following this assumption, learning from natural swimmers promises improved abilities such as increased efficiency, agility, and manoeuvrability.The category of Body Caudal Fin (BCF) describes a classification of fish swimming motion that utilises the central body line to form a traveling wave to generate forward and directional thrust for propulsion and manoeuvring.
Categories are distinguished by the wavelength and amplitude envelope of the traveling wave adopted by different species.These categories have been generally accepted (Sfakiotakis et al., 1999;Blake, 2004).However, the latest research suggests less significant differences between categories and a higher convergence of body motion across different species (Di Santo et al., 2021).In particular, the assumption of reduced head amplitude of Thunniform swimmers compared to Anguilliform swimmers was not confirmed.This suggests it is necessary for an efficient bio-inspired robot to be able to adopt novel swimming gaits that can be modified in a continuum.Fig. 1 plots the amplitude envelope of published experimental measurements.
In contrast to a bulk body containing all equipment with dedicated flexible appendages, a modular design distributes electronic and mechanical equipment along the whole length of the body, discretised into modular packages.A modular design provides the ability to flexibly configure and re-configure the number and type of modules and therefore adapt and lengthen the robot structure in response to different requirements for tasks.It also increases reliability through redundancy of function across similar modules and shows high potential for cost reduction through repeatedly applying a common modular structure with common interfaces.The capabilities for such a robot can also be efficiently extended and enhanced through the addition of new modular segments using common interfaces without replacement of the entire robot.Many reconfigurable modular robotic systems for research have been developed (Liu et al., 2016;Chennareddy et al., 2017) but none of these reconfigurable systems have been designed for underwater operation potentially as part of a biomimetic swimmer.
Numerous ingenious BCF type swimming robots are present in literature.Famously, there is MIT's Robotuna (Tolkoff, 1999) and more recently SoFi (Katzschmann et al., 2018), both of which follow the form of a bulk body with dedicated flexible appendages.Related to the proposed design by the use of magnetic couples, the Lampetra Artefact (Stefanini et al., 2012) makes use of rotating magnets to alternate attraction force between magnetic couples on the sides and is enclosed in a watertight flexible cover.Closed segment modular design approaches can be found in: Amphibot (Crespi and Ijspeert, 2006), Envirobot (Bayat et al., 2016), Mamba (Liljebäck et al., 2014) and Eelume (Liljebäck and Mills, 2017).The named robots achieve watertight flexibility either by means of a dynamic O-ring seal or flexible cover.While these are valid solutions, they place high demands on material and tolerances and have potential to degrade over time.
The robot presented, shown in Fig. 2, in this paper was developed to withstand harsh sea environments, to conduct, for example, offshore inspection tasks while maintaining anticipated efficiency improvements from a bio-inspired design structure.The robot is made up of a variable number of similar body modules connected in series, completed by a head module at the front and caudal fin module at the back of the respective module chain.The presented design emphasises the focus on modularity by use of a non-fixed powerful magnetic coupling between modules.This provides practical advantages, such as easy assembly and disassembly during transportation as well as flexibility of system setup and repair.It further provides space for innovation with regards to modular robotics in underwater environments including electronic aspects such as redundancy and exchangeability of modules including those that store a power source.
A magnetic couple between modules allows for a static seal able to withstand higher pressures without degrading over time which, as a consequence, provides greater protection to the housed components.Further, the proposed design avoids using fixed mechanical connection which facilitates disconnection under high load and increases the survivability of the robot in harsh environments.Finally, the strong but breakable connection offers a development direction for underwater robots seen already in space robotics, namely the use of self-configurable modular robotic technologies (Letier et al., 2019).Development towards self-configuration and adaptation to the encountered environment will be enabled by adding an actuated decoupling mechanism to the current permanent magnet connection.
The paper is organised to describe the design, construction, and lab testing in chronological order.The design processes, detailed in section 2, includes descriptions on mechanical design, magnetic coupling design, electronic design as well as communication and control strategy.Section 3 provides details on the manufacturing process, assembly, and balance and ballasting considerations.Finally, lab tests results are presented in section 4.

Design process
The design process aims to create a robust robotic structure able to exploit the benefits of a modular structure and BCF swimming technique while maintaining sufficient robustness for applications in harsh sea environments.The final swimmer is targeted to be of a maximum length of 1m to allow local water tank testing.Further restrictions arise from the applied prototyping tools and the overall budget.The design process followed five stages: i) mechanical design, ii) electronic design, iii) control and communication, iv) prototyping and assembly, and v) lab testing.

Mechanical design
A long and elongated body is a common feature of BCF type swimmers, observable in, for example, the American eel, as shown in Fig. 3. To replicate the general physical aspects in a robotic structure, the body is modelled into discrete elements.Unique body elements are the head, body segments and tail fin.The head typically houses sensor systems for navigation, leads the body, and consequently its shape has high influence on the drag and steering.The head module is followed by a series of repeating body segments, assuming constant aspect ratios.The tail fin, as the last element of the serial structure, influences the vortex shedding at the trailing end and is often made up of a flexible structure that passively extends the body wave.Rigid body modules provide protection for electronic components, while flexibility is implemented via connecting joints.The joints can be considered as nodes along the central spinal cord as described in (Ijspeert, 2008).
A general challenge in the design of jointed rigid body elements is the flexible connection between rigid body parts ensuring a compliant and watertight connection.Typical solutions between separate modules involve mechanical coupling with dynamic seals (Crespi and Ijspeert, 2006) or flexible covers (Kirchner et al., 2006).A dynamic seal deteriorates over time and risks water ingress under high pressure, and a flexible cover could tear when coming into contact with sharp objects in the underwater environment.In all solutions, the lever arm, mechanically connected to the torque generation servo or motor, is a weak point and can potentially break under peak stress from impact.
To increase reliability and reduce risk of water ingress, particularly in deeper water, this work presents the design of a one degree of freedom (DoF) actuated joint between statically sealed modules coupled by permanent magnets.The design achieves torque transfer without fixed mechanical connections allowing for a reduced weight structure and protective decoupling under extreme load.

Magnetic joint
A synchronous mechanical coupling between two physically separated shafts is achieved by means of a magnetic attraction force.Typically, attracting magnetic forces are generated from permanent magnets or eddy current couplings using electromagnetic coils.Because the latter relies on a constant energy supply to maintain an induced magnetic field, the design focuses on permanent magnets.Magnetic couples are fixed to a driven side and a load side, where magnet couples are typically arranged in either an axial or coaxial configuration, as shown in Fig. 4 a).Synchronous motion is maintained via restoring torque relative to the displacement angle between the two sides, the so called load angle (Nagrial et al., 2011).When the load difference between the two sides exceeds the maximum magnetic torque, coupling 'slip' occurs.Consequently, it is important to design the magnetic couples to provide sufficient coupling strength for the target application.
Next to torque transmission, the proposed design makes use of the attractive force in the magnetisation direction to align and hold neighbouring body modules, with the descending module resting atop the neighbouring module's ball bearing.A characteristic part of the design is the placement of magnets within a limited arc space on both shafts, not around the full shaft as would typically be the case of a synchronous magnetic coupling.This achieves an interlinked shape and avoids large joint structure parts, Fig. 4 b), which in turn reduces weight.Further, this allows for modules to decouple when experiencing extreme external loads.Decoupling will appear when a pull force between magnets exceeds the magnetic couples normal force.Under normal operating conditions decoupling does not appear, as there is a push force generated between the coupled modules when the fish is forward swimming and due to the characteristics of the viscous, self-supporting nature of water.
The complete coupling is made up of n pairs of magnet couples in alternating arrangement.The alternating arrangement makes use of the repelling force of neighbouring magnets of the same polarity.To reduce the cost of the initial prototype, only widely available cuboid shaped neodymium magnets are considered.The final coupling provides one DoF between neighbouring body modules to enable the shaping of a traveling wave in the common plane of rotation of the joints.
Fig. 5 a) shows the force vector, for a normal distance Δx and perpendicular distance Δy for a single magnetic couple that ensure connection in normal and rotational direction.The cuboid magnets' force vector direction is noted in the variable index and the dimensions of the magnets are denotated by W, L and T for width, length, and thickness, respectively.While a sufficiently strong normal holding force F x between magnets is easily achievable, it is critical to design the maximum shear force F y to reduce appearing load angle and avoid slip when transferring torque.
To support the design process an approximation model was used that is sufficiently accurate and fast to support an iterative design process.
The maximum transferable torque, τ max , is approximated by a function of the number of magnet couples, n, the maximum shear force, F x,max , and the radius, r, between the joint centre points, and the half distance between the two magnets, z 2 : The magnetic forces F y,max and F x are calculated using equations published in (Schomburg et al., 2020).Accordingly, F z can be approximated by: where, F 0 is the force F x at x = 0, and the variable d e is defined as The orthogonal component of the maximum shear force in the X-Y plane is approximated by Here, L1 L2 is the length ratio between magnet couples and remains equal to 1.To identify d e values for F x=0 and 1 4 F x=0 are computed via magnetostatic FEM simulation using EMWork (EMSworks, 2022) for (Inventor and Tooling, 2002).As shown in equations ( 2) and (3), the coupling strength is directly related to the magnet strength, dimension, and the normal distance between magnet couples.The section view of the magnetic field, of Fig. 6 c), shows the connecting field lines between magnet couples and the minimum magnetic field intensity between magnets of the same polarity.

Electronic circuit design
Each module houses an identical set of electronics to enable actuation of the drive shaft and allow wireless communication between each module and a controlling laptop.Each circuit is built around an Arduino NANO 33 BLE and is powered by two 18,650 batteries connected in series via a 2S BMS resulting in 3000mAh capacity and a supply voltage between approximately 7V-8.4V.The joint is actuated by a Hitec HS-646WP Servo.The servo power is measured by the Adafruit INA260 breakout board which is powered via the Arduino board's 3.3v pin and communicates via I2C bus.An additional Zener diode, a capacitor, and two Schottky diodes are added to protect the Arduino's Vin pin from over-voltage and reverse current transients caused by rapid servo movement.Each module includes a 12-V TDK WRM483265-10F5-12V-G wireless charging coil at the bottom.A switch makes it possible to turn off the module while wireless charging continues.No magnetic sensors, such as a current hall sensor were used to avoid any interference between the sensor and the magnetic field of the joint.Fig. 7 shows the full module circuit design.

Communication and control
Wireless communication for maintaining remote control of the robot is required to facilitate untethered swimming.With the application of the prototype being exclusively in a lab environment, Bluetooth Low Energy (BLE) has shown to provide effective and reliable connection when the robot is swimming close to the surface.Therefore, for convenience the BLE function of the Arduino NANO 33 BLE board was used.
Communication is established between each module and a laptop.Within the network, two-way data transfer, with a BAUD rate of 115,200, is achieved between the central device (laptop) and the peripheral devices (Arduino boards) where each device is identified via a unique UUID.BLE data transfer organised into Services and Characteristics can be selectively made available to all modules with the laptop being the central node.
BLE communication is setup via a MATLAB function within Simulink.Robot kinematic parameters can be changed online and live data, such as servo power, is recorded.
The robot structure can form a traveling wave via oscillation motion of its joints at a phase difference according to their body position.Each joint follows a sinusoidal oscillation according to equation (4): Θ is the pitching angle, t is time, A(s) and φ(x) define the amplitude envelope and phase offset which depend on the body position.Control variables for amplitude magnitude, wavelength, offset and frequency, respectively, are c a , c p , c s and f.Further changes to the wave shape can be made using the amplitude envelope equation A(x).

The maximum frequency is given by
] being the no load servo velocity, and the max torque is calculated to be 9.6-11.6kg/cm given by the Hitec HS 646 WP Analog Servo.

Manufacture, assembly, and preparation to swim
All structural components are created using a Digital Light Processing -Stereolithography (DLP-SLA) printer: ANYCUBIC Photon Mono (ANYCUBIC, 2022).This makes it possible to create parts up to a tolerance of 50 μm.The well-established technique can produce durable 3D objects by solidifying UV activated resin.A standard translucent resin is used with the properties listed in Table 1.
DLP-SLA printers represent a cost effective and fast method to create complex and watertight 3D structures.The technique has advantages over Fused Deposition Modelling (FDM) printing in that it creates solid wall structures at close tolerances, which is particularly suitable for applications requiring watertightness.Print failure and part deformation during the printing process can result from printing closed cavities that lead to a pressure difference, the so-called 'cup effect', and extensive overhang or insufficient support structure resulting in unsupported new layers.It is possible to avoid printing errors through careful design, print orientation and sufficient support structure in the preparation stages.To avoid the 'cup effect', the enclosure is broken down into 6 parts which are later assembled permanently using an epoxy resin or via threaded inserts and screws to allow for assembly access.All 3D printed parts were coated with a UV blocking spray to stop the materials from further solidifying when exposed to UV light, for example during transport, and extend the longevity of the parts.No degradation of part quality or structural integrity was observed over several months of tests.Fig. 8 shows CAD models for the three main body sections identified in Fig. 3 (Head, Body and Tail fin).All presented parts are 3D printed except for the tail fin plate.Electronic components can be placed and accessed via the flange connection between the joint enclosure and the electronic compartment.The interface is watertight sealed via 6 M3 screws and the surface seal made of expanded DA320 closed cell sponge material.
Apart from the head and tail, it is possible to vary the swimmer configuration by adding or removing body modules.For optimal swimming it is important to balance and ballast the model to ensure it shows sufficient buoyancy and swims stably in an upright position as well as to reduce static and dynamic instabilities.Modules are balanced and ballasted individually to allow for flexible extension or reduction of body modules.Individual module balancing and ballasting is also important to reduce any undesired roll motion to one side during curvature swimming while added camber would lead to a stark bias in the centre of mass.All module structures are axisymmetric in Z and Y Cartesian coordinate directions (see Fig. 9).Static components are placed to ensure a centre of gravity point below the centre of buoyancy for static stability in upright position.The modules buoyancy force and mass, due to the module shape showing lower volume and greater mass towards the joint side, are X axis asymmetric.Added weight is needed to make it possible to align the centre of mass and centre of buoyancy for each module.
Overall dimensioning of the body volume during the design process,  considering Archimedes' principle, resulted in only low amounts of ballast being required.Final balancing and ballasting were achieved together by adding weights at the bottom of each module.As a result, the robot is submerged along the free surface of water and a stable horizontal floating position of the assembled robot was achieved.
The robot structure used in the test consists of a head module, two body modules, and a tail module with a total length of 907 mm, 70 mm width and a height of 110 mm.Each joint is driven via a HTD M5 timing belt connected to a servo pulley with a gear ratio of 32/12.The design allows for a maximum rotation angle of ± 35 • between two modules given by the mechanical constraint of intersecting neighbouring modules and the gear ratio between pulley, shaft, and servo.
The final robot configuration used in the test is shown in Fig. 10.

Lab test
Extensive lab testing was carried out to confirm the designs' function and swimming ability.Results to be presented aim to illustrate the manoeuvrability and thrust generation of the robot.
All testing is conducted in a 3.5 m by 9 m water tank in still water.The head and each joint are fitted with detachable reflector coordinate systems that are detected by a Qualisys motion capture system to record the robot's free-swimming trajectory and body motion.The robot is controlled using open loop real-time serial communication via MATLAB Simulink.Optimal kinematic parameters have not been used in this study, and the following results are obtained using a constant amplitude envelope, A ( s L ) = c a , for free swimming and a linear amplitude envelope, A(s) = cas L , for thrust performance.With s L = 0 at the body head tip and s L = 1 at the tail fin trailing edge.The resulting individual joint positions are s 1 = 0.248, s 2 = 0.444, s 3 = 0.642.Fig. 11 shows the discretised rigid body wave shape over the continuous wave shape.It shows that due to the discretisation some parts of the wave are not well represented, which is a result of the number of DoF.Improvement can come from increased tail fin flexibility and a larger number of joints and body modules.The wavelength is kept at λ = 1 and controlled by c p = 1.

Free swimming
Stable swimming performance for in plane straight and curved swimming trajectories throughout the whole tank space was observed.Fig. 12 shows the trajectory with a constant amplitude envelope at c a = 10, equal joint offset of 25 • and frequency of 1 Hz.It was observed that individual balancing and ballasting of each module, lead the robot to a reduced side leaning position to maintain a stable position in plane when swimming with body camber.Recorded data of roll pitch and yaw is shown in Fig. 13 and corresponds to the trajectory of Fig. 12.
The dynamic roll and pitch amplitude is recorded to be ca.2.5 and 2 • , respectively.Static pitch and roll amplitude are recorded at ca. 8 and 10 • , respectively.
The time for one full circle is approximately 35 s resulting in an angular velocity of 10 • per second.Starting from a resting position, Fig. 12 shows the robot reaches a stable circle trajectory.The head tip follows a smaller radius of ca.300 mm and the position at the tail fin joint a radius of ca.1400 mm.Robot testing was possible for more than 6 h at a time, confirming the recorded low servo power consumption.

Thrust measurement
To assess the thrust performance and support future design decisions on the flexibility of the tail fin, three different caudal fin materials (single sided Carbon fibre, Medium -Foamex, Soft -High Impact Polystyrene (HIPS)) at two amplitude and two frequency values were investigated.A test matrix of all parameters is shown in Table 2 with Carbon fibre (i = 0), Foamex (i = 4), HIPS (i = 8) being investigated.
All three tail plates have a 1 mm thickness and follow the dimensions shown in Fig. 14.The tail material properties are in agreement with the general material properties available at (MatWeb, 2023).
As discussed in (Maertens et al., 2015), current hydrodynamic efficiency measurements, such as the Froude efficiency, are not suitable to assess the swimming performance of fish, as the useful energy of fish propulsion is not clearly definable.To measure the thrust generation, a test methodology that resembles the bollard pull test, popular in the assessment of ship forward thrust generation, is used.A comparable test setup has been applied in (Struebig et al., 2020).
The aperture consists of an aluminium bar fitted with 4 strain gauges to measure applied force in normal and side direction.The robot is connected via an adapter fixating the robot head to the strain gauge bar with one rotational DoF to allow for the robot wave shape to start at the head tip.Fig. 15 shows the setup with the three main components 1) strain gauge bar 2) adapter towards train gauge bar 3) robot.
The resulting force data is post-processed via a lowpass filter to cut out frequencies above 2.5 times the actuation frequency.Fig. 16 shows an example set of results of Case 4 with highlighted sampling points and low pass signal filtering.
For equal measurements between cases and to ensure perpendicular alignment of the robot towards the strain gauge bar, sample data is taken at the point where the side forces over one oscillation cycle T = 1/f is closest to zero 1 T ∑ F y ≈ 0. At this point instantaneous force curves are compared, and net thrust is recorded.
Recorded data is compared in terms of performance for frequency   and amplitude increase as well as difference of fin material for equal kinematic parameters.

Increase in frequency
Fig. 17 a) shows an overview of the measured net thrust and pairs are compared for changes in undulation frequency.As detailed in Table 2 the tail plate material is as following: Case 1 to 4 carbon fiber, case 5-8 Foamex, and case 9-12 HIPS.For all cases (i = 0,4,8), an increase in wave frequency results in an increase in net thrust, which can be seen in the numbered order in Fig. 17 a).
While for case pairs 6-8 the increase is marginal, the difference between case pairs 2-4 increases twentyfold.For all cases, as expected, an increase in wave frequency leads to an increase in instantaneous force frequency.The instantaneous forces of case pair 9-11, Fig. 17 b), show that the side force remains stable in magnitude for increasing frequency while the net thrust force increases.

Increase in amplitude
Fig. 18 a) shows an overview where the measured net thrust and pairs are compared for changes in undulation amplitude.For all but one case an increase in amplitude results in an increase in net thrust.Further, it has led for all cases to an increase in observed side force which can be   seen in the comparison of the instantaneous forces of case pair 3-4 in Fig. 18 b).While the general force curves show resemblance, the amplitude of side and thrust force increases with the increase of actuation amplitude.

Change of caudal fin material
The difference in material stiffness will lead to different elastic displacement due to the fluid surface pressure.Fig. 19 shows the deformation of one oscillation cycle T = 1/f of the Foamex material of Case 4. Clearly visible is the formation of vortexes which in a moving swimmer would result in an inverted vortex stream, an indication for thrust generation.
Comparison of the three caudal fin materials show differences in force magnitude as well as differences in wave shape.The fluctuating wave shape of softer materials at lower frequencies indicates a more complex fluid-structure interaction.Comparing the instantaneous force curves of the three materials at constant amplitude and frequency shows smooth curve shapes for side forces in Figs.22 and 24, and complex force curve in Figs.21 and 23, suggesting an influence of the actuation frequency and potentially natural structural frequency.Comparison of net thrust in Fig. 20 does not reveal a clear advantage for any of the three materials for the tested geometries.However, a trend for improved thrust performance with increased stiffness is visible which can be explained by the rather long geometry of the tested tail fins.

Conclusion and future work
A new, robust and fully modular design of a bio-inspired underwater robot is presented.The design shows a novel solution to underwater flexibility and watertightness and is the first such design able to transfer torque between modules without permanently fixed mechanical connection.By utilising magnetic force to connect neighbouring body modules the system shows high flexibility in system setup and adaptability to different applications as well as a safety mechanism to disconnect under extreme loads with anticipated increase in survivability.
Successful lab testing has proven the stable free-swimming capabilities of the design and confirmed thrust generation for a range of kinematic parameters and caudal fin materials.The parametric study on actuation parameters and caudal fin material have confirmed that the two kinematic input parameters amplitude, and wave frequency directly influence the generated forward thrust and therefore are suitable to be

Fig. 26 .
Fig. 26.Photo of thrust measurement test showing vortex generation in the wake of the robot.

Table 2
Test case parameters.