Development of a Quadruped Robot Platform for Optimizing Wheat and Corn Field for Phenotyping A THESIS SUBMITTED TO THE FACULTY OF THE GRADUATE SCHOOL OF THE UNIVERSITY OF MINNESOTA BY David Moises Aviles Hinostroza IN PARTIAL FULFILLMENT OF THE REQUIREMENTS FOR THE DEGREE OF MASTER OF SCIENCE August 2024 © David Moises Aviles Hinostroza 2024 ALL RIGHTS RESERVED Acknowledgements I would like to thank my advisor, Dr. Ce Yang, for her unwavering support and guidance throughout these years. I would like to thank Dr. Nikolaos Papanikolopoulos for his support and encouragement in moving forward with the project. I would like to thank Dr. William Durfee for his support and advice on the project. I would also like to thank the people at the Agricultural Robotics Lab who provided support and insight into the project’s development. This project was partially funded by the Minnesota Robotics Institute(MnRI) and the Agricultural Robotics Lab. ii Dedication To my parents and my brother for their encouragement and continuous support iii Abstract Phenotyping farmland can be very challenging as the terrain is not even, and at times, due to continuous rain, the dirt can be muddy. Current so- lutions, such as wheeled robots, are ineffective because the wheels become trapped in the mud. Our proposed solution is to develop a quadruped plat- form robot explicitly built for phenotyping farmland. The idea was influ- enced by current quadrupeds platforms such as Spot from Boston Dynamics and the MIT Cheetah. The quadruped would be equipped with cameras and sensors to properly phenotype the plants on the field where data can be accessed live but would be processed offline through other means. The project’s approach to the problem led to the creation of three dif- ferent quadruped prototypes, with each iteration being upgraded. Starting with the initial SpotMicro, subsequent iteration with the OpenQuadruped, and lastly, the “OmniAgrobot” brushless quadruped. The bodies of the three systems involved precisely designed 3-D printed parts made out of PETG filament due to their enhanced durability to UV resistance and stress handling. The first two platforms involved using servo motors for 12 degrees of freedom, with the second model red dog having a higher torque and dif- ferent placement of the servo motor to reduce the stress on the lower part of the leg by placing it next to the upper leg. The two iterations had issues with weight, and the servos were not strong enough to hold them in place when tested in outdoor environments. OmniAgrobot, the brushless quadruped, uses a ROS motion control al- gorithm developed for the OpenQuadruped but modified with a hardware interface for brushless motors. The motion algorithm, called CHAMP, sends position commands to each of the 12 motors and updates them accordingly. The actuator was initially built using 3D-printed parts. The gears were made from nylon, while the housing was made of PETG. The 3D-printed actuators worked great and could output 12.8Nm of torque at 10 amps with a difference of 0.6 Nm from the calculated torque loss due to backlash and other factors. With the success of the 3D-printed actuators, prebuilt motor actuators were acquired with a higher torque of 23.814Nm at ten amps. The torque is enough for the robot dog leg to stand up with a payload of 4KG iv with these commercial actuators. The results of this research prove the feasibility and effectiveness of quadrupeds in the agricultural field for phenotyping crops for diseases like Fusarium Head Blight(FHB) in wheat and barley. The maneuverability and versatility of the quadrupeds provide superior mobility to the current op- tions of using wheeled robots. Using a real sense camera can prove helpful when it’s used for phenotyping, as this could provide a point cloud and RGBD imaging. The quadruped may also improve their mobility by using an IMU and upgrading their motion algorithm with the help of machine learning methods in the future. v Table of Contents Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . . . ii Dedication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iv Table of Contents . . . . . . . . . . . . . . . . . . . . . . . . . . . vi List of Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . viii List of Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix Chapter 1: Introduction . . . . . . . . . . . . . . . . . . . . . . . 1 Chapter 2: Related Work and Background . . . . . . . . . . . 3 2.1 ROS Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2.2 PID Tunning . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2.3 Spot Micro . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.4 OpenQuadruped . . . . . . . . . . . . . . . . . . . . . . . . . 5 Chapter 3: Methodology . . . . . . . . . . . . . . . . . . . . . . 8 3.1 Field topology for Phenotyping . . . . . . . . . . . . . . . . . 8 3.2 CHAMP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 3.3 Agrobot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 3.4 Leg design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 3.5 Computing and Firmware . . . . . . . . . . . . . . . . . . . . 13 3.6 Control system . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Chapter 4: Results . . . . . . . . . . . . . . . . . . . . . . . . . . 16 4.1 PID Tunning . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 4.2 Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 vi TABLE OF CONTENTS 4.3 Actuator Prototype and Commercial . . . . . . . . . . . . . . 18 4.4 Shoe Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 4.5 Field Test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 4.5.1 Grass field . . . . . . . . . . . . . . . . . . . . . . . . . 24 4.5.2 Wheat field . . . . . . . . . . . . . . . . . . . . . . . . 25 4.5.3 Corn field . . . . . . . . . . . . . . . . . . . . . . . . . 26 4.5.4 Motor temperature . . . . . . . . . . . . . . . . . . . . 28 4.6 IMU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 4.7 Camera . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Chapter 5: Conclusion . . . . . . . . . . . . . . . . . . . . . . . 30 Chapter 6: Future work . . . . . . . . . . . . . . . . . . . . . . . 31 Bibliography . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Appendix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 Appendix A: CAN communication messages . . . . . . . . . . . . . 36 Appendix B: Torque calculation . . . . . . . . . . . . . . . . . . . . 37 vii List of Tables Table 4.1 KP and KD Values from PID tunning . . . . . . . . . 17 Table 4.2 Torque Values at Different Feed Forward Settings . . . 21 Table 4.3 Torque Values at Different Feed Forward Settings . . . 22 viii List of Figures Figure 1.1 Google X. . . . . . . . . . . . . . . . . . . . . . . . . . 2 Figure 2.1 SpotMicro. . . . . . . . . . . . . . . . . . . . . . . . . 5 Figure 2.2 SpotMicro and OpenQuadruped showing the different design with a belt driven design from OpenQuadruped and a lower joint placement for the motor on the Spot- Micro. . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Figure 2.3 OpenQuadruped. . . . . . . . . . . . . . . . . . . . . 7 Figure 3.1 After rain fields for both corn and wheat for quadruped run trials. . . . . . . . . . . . . . . . . . . . . . . . . . 9 Figure 3.2 Rqt graph of CHAMP. . . . . . . . . . . . . . . . . . 10 Figure 3.3 OmniAgrobot in the field. . . . . . . . . . . . . . . . . 11 Figure 3.4 Leg design of the OmniAgrobot. . . . . . . . . . . . . 12 Figure 3.5 Flowchart of Hardware interface. . . . . . . . . . . . . 14 Figure 3.6 Outline of CAN set up. . . . . . . . . . . . . . . . . . 14 Figure 3.7 CHAMP teleop. . . . . . . . . . . . . . . . . . . . . . 15 Figure 4.1 PID Graph description. . . . . . . . . . . . . . . . . . 16 Figure 4.2 OmniAgrobot in Simulation. . . . . . . . . . . . . . . 18 Figure 4.3 3D printed Actuator set up. . . . . . . . . . . . . . . 20 Figure 4.4 Motor Actuator Scale test. . . . . . . . . . . . . . . . 22 Figure 4.5 Weighted test of agrobot leg. . . . . . . . . . . . . . . 23 Figure 4.6 Shoe designs for OmniAgrobot. . . . . . . . . . . . . 24 Figure 4.7 OmniAgrobot in the grass field. . . . . . . . . . . . . 25 Figure 4.8 OmniAgrobot in the wheat field. . . . . . . . . . . . . 26 Figure 4.9 OmniAgrobot in the corn field. . . . . . . . . . . . . . 27 Figure 4.10 Temperature reading from lower motor. . . . . . . . . 28 Figure 4.11 Real sense image walk trial. . . . . . . . . . . . . . . 29 Figure A.1 MIT Driver Data Definition. . . . . . . . . . . . . . . 36 ix Chapter 1 Introduction Phenotyping crops is essential to determine different plant agents’ effi- cacy and experimental methods. The current process involves using human vision(manual phenotyping), drones in the sky, and field ground robots. Traditional methods, such as human vision, can deteriorate over time and be time-consuming, and with the advances in computer vision, it may need to be more accurate [DWHB+17]. Drones can provide aerial data by using multispectral and hyperspectral cameras post-processing the data. Drones capture detailed images of crop fields; the images are then stitched and reconstructed to be processed for phenotyping. The process follows by examining the different types of wave- lengths across the crops. We can assess the stress on the plant or chlorophyll content by looking at the wavelengths. [LST+22] Field robots get data up close by using cameras and other sensors at- tached to the field robot. Having a reliable platform, especially in field robots, to phenotype is essential. Current methods involve wheeled robots such as the Google X. The phenotyping information gathered is crucial, as it provides ways to improve crops and adequately identify them. The infor- mation usually involves leaf length, leaf area, plant height, and non-contact phenotyping using RGB cameras, stereo vision, and LIDAR to capture im- ages and 3D models of the crops. Current wheeled robots have these sensors but can get stuck in wet conditions as the wheel lacks the friction required to move forward or backward [ZZ19]. With technological advancement, dif- ferent types of robots have been introduced into the market, such as legged robots. The legged robots can traverse fields where wheeled robots cannot, such as muddy or uneven terrain. Design constraints for robots, such as row spacing between crops, must be considered, as some agricultural robots can only work in a certain amount of space[LPB19]. The versatility of the quadruped platform allows us to go as low as 16 inches in terrain. This study aims to build a quadruped-legged robot phenotyping plat- form named OmniAgrobot that traverses dry and muddy fields to phenotype various crops, such as corn and wheat. The OmniAgrobot is a slim, adapt- able platform that can traverse multiple crop fields. It provides a reliable 1 platform with a control system algorithm to traverse harsh environments. High-torque motors on each leg allow it to traverse harsh conditions where wheeled field robots can get stuck. Figure 1.1: Google X or Alphabet X in an agricultural field [Hea23] . 2 Chapter 2 Related Work and Background 2.1 ROS Overview ROS or Robotics Operating System, is an open-source framework that fa- cilitates robot software development. It has a collection of tools and libraries that support and simplify the complexity of robot behavior and creation. ROS allows multiple components, such as sensors, to communicate with each other and other machines [QCG+09]. ROS uses a publish-subscribe archi- tecture to handle complex robot behavior. Data is published on a topic, and then multiple nodes can subscribe to this topic to receive the data in real time[QCG+09]. ROS also come with prebuilt software for sensor data processing, control algorithms, and simulation for robot viewing like Gazebo or Rviz [KH04]. Using the prebuilt packages can save time and accurately depict the robot and its functions. 2.2 PID Tunning Ziegler-Nichols method is a well-known technique for tuning PID Proportional- Integral-Derivative controllers. These are used to tune the system’s response to a signal, in this case, the motor’s position. The Ziegler-Nichols method was a starting point for tuning in the motors. While not optimal, it provides a good starting point for any signal tunning, particularly in nonlinear sys- tems [MENN23]. Although the 3-phase motor driver does not include the integral parameter, the proportional and the derivative were used to cali- brate the motor positions. The Ziegler-Nichols method provided a starting point, and then manual tuning was used to tune by looking at the curves drawn from the motor signal until a critically damped response was achieved. Critically, it is important in our application because, at this position, it is where it stops oscillating, thus giving an exact motor position. [Lá18] 3 2.3. SPOT MICRO 2.3 Spot Micro SpotMicro was developed as a small copy of the Spot from Boston Dy- namics. The spotMicro was 3D printed and made out of 4 legs with 12 servo motors. The body was developed by the Korean designer KDY0523 [Tay21]. The initial design used low torque servos named MG996R, which output 11kg/cm in stall torque at 6v. The design chosen for our model en- tails the hv5523mg, which holds a 23kg stall torque of 8.4v. The additional torque ensured that the robot dog walked properly without difficulties in indoor settings. The robot dog featured a Raspberry Pi 3 running ROS as its main computer and a PCA9685 microcontroller to control the servo motors. The motion control algorithm used the following kinematic model [SBK17]. It makes its motion control by creating a kinematic analysis of the forward kinematics of quadruped robots using the Denavit-Hartenberg parameters and then solving for the inverse kinematics. The body parts were 3D printed using PETG and TPU filament. The experimentation with PETG filament was a great success. PETG has tensile solid properties, high ductility, and resistance to heat and some chemicals; it also features some UV resistance [YKT+24]. The body structure could han- dle itself without breakage, resisting the force applied by the servo motors. The TPU filament shoes provided a rubbery surface with a high friction point so the robot would not slip. The result of this robot walking on the field could have been more prac- tical as it was slower in performance and not the most stable platform. The legs were too short to traverse through the wheat fields, and the torque of the individual motors was not strong enough to keep the robot moving forward. The robot could not move forward with added weight as it overloaded the motors; thus, only a tiny Raspberry Pi camera was added, and it recorded 720p images. The SpotMicro build proved to be enough for flat terrain. The motion of the legs was shaky at times, and they slipped from time to time. This was due to the limited torque of the servo motors. The SpotMicero was also tested in the outdoor terrain, where it could go forward in small strides, but at times, it locked up as the holes in the terrain were too deep for its structure. Although it did not perform as expected in its design, It caved in for the possibility of making a more stable platform if more robust motors were used, as it was not a complete failure. 4 2.4. OPENQUADRUPED Figure 2.1: SpotMicro with Raspberry pi camera 2.4 OpenQuadruped OpenQuadruped is another open-source project with a 12 DOF 3D printed quadruped driven by 12 servo motors with a custom motion control [EA21]. The main difference between the Open-quadruped and the SpotMicro is the placement of the servo motor. The servo motor in the OpenQuadruped is located in the upper arm where as the SpotMicro has it on the lower joint connection. Following this change, the weight is shifted to the top, thus reducing the leg’s total weight. The stress required for the upper and lower servo motor is reduced, with a more advantageous center of mass. The Open- Quadruped achieves this change by introducing a belt system that connects the lower leg. The OpenQuadruped platform was created to be experimented with us- ing the CHAMP motion control framework. The Openquadruped platform 5 2.4. OPENQUADRUPED (a) SpotMicro with servo motor in lower joint. (b) OpenQuadruped with servo motor in upper arm. Figure 2.2: SpotMicro and OpenQuadruped showing the different design with a belt driven design from OpenQuadruped and a lower joint placement for the motor on the SpotMicro. was successfully integrated with CHAMP by fulfilling the requirements of creating a custom hardware interface and using a pre-built URDF made for it. At the same time, the platform was able to stand on its own; whenever in motion, the tension on the TPU belts was not strong enough to maintain its posture. The pulley and belt slipped due to its high torque. Neverthe- less, the experiment succeeded by integrating the CHAMP framework with a URDF from a different robot and making it move in real-time. 6 2.4. OPENQUADRUPED Figure 2.3: OpenQuadruped 7 Chapter 3 Methodology 3.1 Field topology for Phenotyping The testing fields were wheat and corn. These fields are part of the Uni- versity of Minnesota and are in the A5 and A1 experimental areas. The tests were conducted in after-rain terrain in the corn and wheat fields, as shown in Figure 3.1. The Corn plots are spaced at 26 inches. The wheat fields feature a mixture of grass and wheat grass, including uneven terrain and small potholes along the way. The corn fields feature a dirt road that is made of loose dirt. Similar to the corn plots, the terrain features uneven- ness. After rain, conditions include a muddy texture and loose dirt for both fields. 8 3.2. CHAMP (a) Corn field hours after rain at St. Paul campus A1 field. (b) Wheat field hours after rain at St. Paul campus A5 field. Figure 3.1: After rain fields for both corn and wheat for quadruped run trials. 3.2 CHAMP CHAMP is an open-source development framework for building new quadrupedal robots and developing control algorithms for quadrupeds. The control framework is based on the MIT cheetah[Lee13]. CHAMP provides the freedom to use the control algorithms developed for the MIT cheetah and apply them to multiple robots. CHAMP contains preconfigured URDF (Unified Robotics Description Format) for some robots such as the Anymal, SpotMicro, OpenQuadruped, Spot, and Unitree A1. It also allows upload- ing a custom URDF to use with the control algorithm. CHAMP can be used in a simulation environment such as Gazebo and Rviz, but it is not limited to simulation; it can be applied to a real robot. A custom URDF and hardware interface must be created so that the motors can use CHAMP in a real robot. CHAMP’s process flow is as follows. First, it receives a command via /cmd vel, which is smoothed to avoid abrupt motion. This is sent to the 9 3.3. AGROBOT champ controller, which holds the control framework of the MIT Chee- tah that calculates the necessary joint positions. The joint positions are then sent to joint group position controller, which forwards them to the hardware interface. The hardware interface then translates it into CAN messages to the individual motor positions, moving the robot’s legs. Simultaneously, sensors like the IMU, foot contacts, and odometry provide data that the state estimator then uses to update the motor’s position and motion. This information is depicted below in the rqt graph of CHAMP in Figure 3.2. Figure 3.2: Rqt graph of CHAMP 3.3 Agrobot Based on the information provided by the previous designs, a higher torque model was created to test the capabilities of a brushless motor con- nected to a gearbox system. The results from this experiment provided results on the capabilities of this gearbox. It was decided to purchase Cube- mars motors because they met the requirements better than the gearbox system at a lower The OmniAgrobot is the third variant of the quadruped platform ex- plicitly created for walking on agricultural fields. It is made of PC or poly- carbonate and aluminum. The OmniAgrobot features high torque density electric motors weighing 500g. Each motor can have a high precision with 0.2 degrees of backlash and a high peak torque of 24.8Nm [Cub24]. The OmniAgrobot’s overall weight is 15kg, and its dimensions are 16.5 in by 25 in by 19 in, making it suitable for traversing corn plots. The OmniAgrobot is powered by two 24v lithium tool batteries with 10 3.3. AGROBOT 4Ah, for a total of 196Wh, each connected to the front and back legs. This provides a total runtime of approximately 2 hours at constant motion. It contains a portable battery for the computer to avoid any discharge when in motion. It communicates with individual motors through CAN, with each leg connected to a separate CAN bus. This setup avoids overloading the CAN bus with messages exchanged with the computer, primarily when run at higher refresh rates. The current refresh rate at which it exchanges messages is 200 Hz when connected with CHAMP’s control algorithm. Figure 3.3: OmniAgrobot in the field 11 3.4. LEG DESIGN 3.4 Leg design The OmniAgrobot contains three motors at each axis of rotation: one for the hip, one for the upper arm, and one for the lower leg. Figure 7 shows a breakdown of each component on the legs. Adding bearings on the inner lower tab to ensure a low friction system at the lower leg helped with smooth motion. The lower leg was upgraded from the previous designs. As the belt slippage was an issue, upgrading it to a four-bar linkage was decided. The upgrade has a lower leg range of limitation, as it can only move at 120 degrees, unlike the Cheetah 3 with 330 degrees [BPK+18]. The length of the limps followed the same structure as the MIT mini cheetah’s compact body design [KCK19]. This design ensures the capability of traversing through the different types of fields. (a) Exploded view of the OmniA- grobot. (b) Entire leg assembly of the Om- niAgrobot. Figure 3.4: Leg design of the OmniAgrobot. Unlike a traditional belt-driven system, a four-bar linkage produces al- most nonexistent backlash [ insert reference on four-bar linkage vs. belt- driven]. The mechanical advantage of the four-bar linkage was blank; this was calculated using the formulas below. [insert calculations for the amount of torque produced with the four-bar linkage(mechanical advantage)] Its body is made of a combination of PC and aluminum. The lower 12 3.5. COMPUTING AND FIRMWARE leg connector’s top and bottom portion is made of aluminum to avoid the breakage and deformity of the plastic. The body features aluminum rein- forcement on heavy-stressed parts such as the lower legs’ sides and hips. The quadruped’s feet or shoes are made of TPU filament, which was chosen due to its elasticity and malleability. The shoes are made in a round shape to adapt to uneven terrain, and a special, specific design pattern enables a high-grip design in most cases. 3.5 Computing and Firmware The OmniAgrobot uses a mini PC running Ubuntu 20.04 with ROS Noetic installed. Ubuntu allows for more effortless transfer and modification of its Linux-based operating system. Each motor contains its driver board, which is made of an STM32. The firmware installed onto the STM32 board was created for the FOC or Field Oriented Control of the 3 phase motors; it features a loop that runs at approximately 40 kHz, which in turn allows for precise control of the motor’s torque by regulating the phase currents [KCK19]. 3.6 Control system The Hardware Interface is the communication conduit between the CAN interface and ROS. It operates as a control loop in integrating the motors into the ROS CHAMP Package. It primarily contains the following func- tions. Figure 8 demonstrates how these functions are being used in the flowchart loop. 1. Setup all the Motors. It is responsible for creating the Motor Interface, setting the required operating conditions, and creating the MotorController Objects 2. Shut Down, it is responsible for cutting the communication channels and disable the motors from executing any more CAN Messages received by their socket address. 3. Send Motor Commands, it is responsible for sending the motors the write can frame function call, which creates a CAN message in the form of a CAN frame and communicates with the motors via sockets 4. Publish Joint States; it publishes the joint states to the ROS stack. 5. Subscribe to required ROS topics The communication standard used for communicating with our high torque density electric motors was using the CAN Bus [PR20], popular in 13 3.6. CONTROL SYSTEM Figure 3.5: Hardware interface flowchart automation electronics. Working within the predefined operation modes available on the motors, Servo mode, and MIT mode The development of the CAN communication interface was based on C++, the programming language of choice. Alternatively, a working variant of the CAN Communication interface was built using Python but never incorporated; it was only used to check positions and calibration. The CAN interface initially operated on a sequential execution flow, where each motor received a message. It is built with parallel threading, allowing the interface to communicate with all 12 motors individually. This helps reduce buffer and lag between processing CAN messages using a dual CAN Bus. Figure 3.6 shows the setup of each of the motor IDs and their respective CAN bus. Figure 3.6: Outline of the CAN connection and CAN bus set up for the OmniAgrobot To control the quadruped robot, it uses an open-loop control system. CHAMP provides two modes of control. One uses a keyboard for inputs, 14 3.6. CONTROL SYSTEM as shown in Figure 3.7, where “i” is forward, “,” is backward, “j” is left, and “l” is correct. Teleop also features a way to increase the linear and angular speed. Increasing the speed is helpful as it can improve the speed and the size of the stride. The second method is different; this uses a gaming joystick, an Xbox or a PS4 controller. These controllers can then be used similarly to the keyboard as they feature the same controls. Figure 3.7: Teleop controls for quadruped robot 15 Chapter 4 Results 4.1 PID Tunning The PID tuning for the brushless motor was ultimately tuned manually. Figure 4.1 shows a great example of how manually the motors were tuned. It initially starts with the initial KP value, which causes an overshoot. Adding the KD values acts as a damper for the oscillation. The KD values are then increased until a critically damped response is attained. This process was repeated for all values in Table 4.1. Multiple values for KP were tested for the initial walk. Since KP and torque are related to each other. The minimum KP values for a great walk were of 120 KP, this provided enough force for the robot to walk without any problems. Introducing the robot to more rugged terrain calls for an increase in KP up to 150 KP. Figure 4.1: PID tunning response [Man22] 16 4.1. PID TUNNING KP KD 10 0.4 15 0.52 20 0.6 25 0.65 30 0.7 35 0.75 40 0.83 45 0.89 50 0.96 55 1.01 60 1.07 65 1.15 70 1.15 75 1.15 80 1.19 85 1.24 90 1.29 95 1.44 100 1.46 105 1.51 110 1.52 115 1.55 120 1.6 125 1.65 130 1.7 135 1.75 140 1.75 145 1.78 150 1.95 155 1.95 160 1.95 165 1.96 170 2.0 175 2.0 180 2.04 Table 4.1: KP and KD Values from PID tunning 17 4.2. SIMULATION 4.2 Simulation Solidworks, a CAD design software, was used to model the OmniA- grobot. Each piece was then carefully assembled, and subassemblies were created, each corresponding to each leg and, finally, the main body. Solid- works offers a way to convert from CAD files to URDF using the SW2URDF plugin. Once the URDF is created, it is fed to the CHAMP SDK. The simu- lation can then be run with CHAMP to simulate the OmniAgrobot in Rviz and Gazebo. The custom URDF worked flawlessly in the simulated straight field, as shown in the figure. Figure 4.2: OmniAgrobot displayed in rviz 4.3 Actuator Prototype and Commercial Initially, the prototype for the OmniAgrobot featured a 3D-printed plan- etary gearbox actuator. The actuator is made out of PETG filament and nylon gears. The nylon gears were chosen for their durability and self- lubrication, produced in motion [Yan16]. The actuator used a U8-KV100 motor, with a mechanical advantage of a 6 to 1 gear ratio, which allows 18 4.3. ACTUATOR PROTOTYPE AND COMMERCIAL for a high torque actuator. The design work featured a modified version of the OpenTorque actuator gearbox, an 8 top 1 gear ratio design[Lev23]. The limitations to this design included the backlash from the gearbox design and the higher weight, cost, and availability of the T-motors. The prototype was experimented with through different tests, such as the weight scale test, as shown in Figure 4.3(b). The test was used to determine its holding torque. The result of the test is shown in Table 4.3. The results show that at ten ff or ten amps, the actuator produced a holding torque of 12.85Nm with a 6 to 1 gear ratio, which is more than enough to hold a 15kg quadruped. Torque was calculated by using the formula: Torque = weight on scale 1000 × 9.8× 0.15 m 19 4.3. ACTUATOR PROTOTYPE AND COMMERCIAL (a) Exploded view of actuator. (b) Testing scale set up for 3D printed actuator Figure 4.3: 3D printed Actuator set up. 20 4.3. ACTUATOR PROTOTYPE AND COMMERCIAL Feed Forward Scale Reading (g) Torque (Nm) -1 719 1.127392 -2 1538 2.411584 -3 2390 3.74752 -4 3048 4.779264 -5 3878 6.080704 -6 4619 7.242592 -7 5780 9.06304 -8 6688 10.486784 -9 7359 11.538912 -10 8198 12.854464 Table 4.2: Torque Values at Different Feed Forward Settings Following the success of the 3D-printed actuator, it was decided to look for a commercial actuator that could supply the same or more torque as the 3D-printed variant. The commercial actuators were founded by a company named Cubemars, and they featured a high precision with 0.2 degrees of backlash and a high peak torque of 24.8 Nm [Cub24]. The same test was prepared for the new commercial motor actuators, and the test results are shown in Table 4.2, which shows a torque of 11.907 at ten ff or ten amps. The performance compared to the ones from the 3D printed actuator is similar and thus validated. 21 4.3. ACTUATOR PROTOTYPE AND COMMERCIAL Figure 4.4: Testing setup for determining the torque at different ff or current values for commercial actuator Feed Forward Scale Reading (g) Torque (Nm) -1 970 1.4259 -2 1400 2.058 -3 2380 3.4986 -4 3400 4.998 -5 4200 6.174 -6 5000 7.35 -7 6000 8.82 -8 6700 9.849 -9 7300 10.731 -10 8100 11.907 Table 4.3: Torque Values at Different Feed Forward Settings 22 4.4. SHOE DESIGN To verify these results, we ran a test featuring weights on the upper portion of the leg and added weight in the upper arm. As shown in Figure 4.3, the added weights ranged from 2kg to 4kg. The legs were more than capable of sustaining 4kg without problems and 7 Nm or 7A. Figure 4.5: OmniAgrobot single leg test using 2kg batteries on the upper leg 4.4 Shoe Design Custom shoe designs were made for the OmniAgrobot. Initially, it began with a regular rounded shape, then moved into two different shoe types, as shown in Figure 4.2. The rounded shape provided little grip to the robot, as it slipped a couple of times when traversing a regular flat floor. Following this, the second model was introduced with a square pattern that began at the tip of the shoe. The square model proved efficient as the grip was enhanced with successful walking trials on the regular floor and the corn and wheat fields. The only downside to this design was due to the spacing in the small blocks, dirt caught on them quicker and at times it was packed with it, specifically when after rain conditions made the soil loose. The third design followed an agricultural truck tire design pattern, the design was made so soil would dislocated it self by its open “V” pattern. While it had improved in after-rain conditions when the soil was arid and loose, the friction was poor and slipped, thus unable to move. The final design was the second 23 4.5. FIELD TEST square design pattern, as this had the best friction between the shoes listed. (a) Square pattern shoe. (b) Agricultural truck pattern shoe Figure 4.6: Shoe designs for OmniAgrobot. 4.5 Field Test 4.5.1 Grass field The grass test was successful, and the OmniAgrobot traversed the field with a slight trajectory deviation. The deviation in trajectory was due to the small potholes in the field and the tall grass that sometimes got tangled with the leg when moving forward. Increasing the torque, in this case, increasing the kp values up to 120, was able to provide sufficient torque to traverse through this field. Densely tall grass could prove a challenge as this could cause more entanglement with the legs, thus limiting its mobility. 24 4.5. FIELD TEST Figure 4.7: Snipped of OmniAgrobot in the grass field 4.5.2 Wheat field The wheat fields in the A5 camp were spacious, with a length of about 36 inches. The fields hold some grass; thus, at times, the quadruped behaves similarly to the grass field. The test proved to be successful as it could traverse the field; it showed some deviation when traveling in a straight line. The deviation could also be due to the unevenness of the terrain; nevertheless, it can be corrected by manually shifting the robot’s direction with the teleop or using a joystick. 25 4.5. FIELD TEST Figure 4.8: Snipped of OmniAgrobot in the wheat field 4.5.3 Corn field The cornfields during testing had the after-rain effect, which made the soil loose and somewhat muddy. The quadruped overcame the loose dirt and traversed up to ¼ of the way in the plot field. The row spacing varies in the A1 field. Thus, some paths are narrower than others. In some instances, the quadruped deviated and hit a couple of corn crops while moving. While it was not expected, this caused the quadruped to stop and not move forward. During arid conditions, the quadruped struggled as it could not grip the ground well enough. The lack of friction in these fields caused the direction 26 4.5. FIELD TEST to deviate similarly to the previous fields. Overall, the corn field testing was the most successful, proving it could traverse the entire field if it followed a straight path. Figure 4.9: Snipped of OmniAgrobot in the corn field 27 4.6. IMU 4.5.4 Motor temperature The temperature of the robot varied during the trials. The testing tri- als lasted 1-2 hours. During hot and humid weather, such as 85 degrees Fahrenheit, the lower leg motors could sustain a maximum temperature of 40.9 Celsius or 105.62 Fahrenheit, as shown in the figure. The manufacturer concluded that it can rise to 60 Celsius, though, at that point, the motor will burn out. The highest temperature reading was from the lower rear left motor, which is usually the case when testing. This could be due to imperfections in the asymmetry of all the legs, which impacts the trotting of mammals such as dogs [AAK+22]. Figure 4.10: Temperature reading from lower motor 4.6 IMU For the robot to self-balance, an IMU was attached to the quadruped. The project’s current state has the IMU publish position data to ROS; this can evolve to create a self-balancing algorithm that compares the IMU current data with the correct data, thus correcting each motor position. A 28 4.7. CAMERA mode where the robot follows the position of the IMU was developed and proved successful at orienting itself to that position in simulation and in real-time. 4.7 Camera The OmniAgrobot has an Intel Realsense RGBD camera installed. Cur- rently, the information gathered from the trials is RGB, but it is not limited to it. As shown in the figure below, it can capture high-resolution images. It can do this by recording a rosbag from the camera’s image topic, which can be reproduced later as a recording. The real sense contains multiple topics, such as the LIDAR built-in itself. With the LIDAR, it is possible to recreate the field, although it is not yet ready. Figure 4.11: Real sense image of recording during walk trial in the grass 29 Chapter 5 Conclusion A robust quadruped platform has been created to perform various sci- entific and agricultural phenotyping of crops such as corn and wheat. The Quadruped is open source and highly customizable to suit the lab’s needs. It can traverse rough terrain, such as loose dirt and post-rain conditions. At times, it can deviate from its path depending on the size of the unevenness of the field, but it can set back into the course by controlling it through the telescope. It can maneuver through dense fields but is limited to its battery size, giving it a total runtime of around 2 hours. The other limiting factor is the temperature, which can rise to 40 degrees Celsius. This impression- able quadruped platform is just the beginning with it’s open source, more upgrades can be added. 30 Chapter 6 Future work The OmniAgrobot is a great platform, but several improvements can be made. Now that the IMU is integrated, it needs a self-balancing algo- rithm that compares its current position with the correct one. Correcting it will enable a whole horizon of possibilities, such as pushing with abrupt force and traversing deeper potholes in the field. With the IMU online, it could be on par with commercial robots such as the Unitree GO regard- ing self-balancing. Another upgrade that can be added is the foot sensors at the sole of the shoes. Having a switch-type system that sends feedback whenever contact is made with the ground enables the possibility of a better self-balancing platform. The real-sense camera offers more possibilities as it contains LIDAR and depth readings. The camera can use the LIDAR infor- mation to recreate the plot fields as the quadruped robot traverses through. The camera can also avoid obstacles or rectify itself when going off-path. Machine learning and deep learning algorithms can improve the gait and overall locomotion of the quadruped. The current model for locomotion from MIT is useful. Still, in the future, it can be worth the time to develop or use another control algorithm that features deep learning models for a better and more stable gait. 31 Bibliography [AAK+22] Masaki Adachi, Shinya Aoi, Takuya Kamimura, Kazuo Tsuchiya, and Fumitoshi Matsuno. Fore-aft asymmetry im- proves the stability of trotting in the transverse plane: A mod- eling study. Frontiers in Bioengineering and Biotechnology, 10:807777, 2022. → pages 28 [BPK+18] Gerardo Bledt, Matthew J. Powell, Benjamin Katz, Jared Di Carlo, Patrick M. Wensing, and Sangbae Kim. Mit chee- tah 3: Design and control of a robust, dynamic quadruped robot. In 2018 IEEE/RSJ International Conference on Intel- ligent Robots and Systems (IROS), pages 2245–2252, Madrid, Spain, 2018. IEEE. → pages 12 [Cub24] Cubemars. Ak70-10 motor datasheet. https://www. cubemars.com/goods-1031-AK70-10.html, 2024. Accessed: 2024-08-21. → pages 10, 21, 36 [DWHB+17] Konstantin Divilov, Tyr Wiesner-Hanks, Paola Barba, Lance Cadle-Davidson, and Bruce I. Reisch. Computer vision for high-throughput quantitative phenotyping: A case study of grapevine downy mildew sporulation and leaf trichomes. Phy- topathology, 107(12):1549–1555, 2017. → pages 1 [EA21] Adham El-Arabawy. Open quadruped. https://github.com/ adham-elarabawy/open-quadruped, 2021. GitHub reposi- tory. → pages 5 [Hea23] Brian Heater. Alphabet’s x graduates robotic agtech firm min- eral. TechCrunch, 2023. Accessed: 2024-08-21. → pages 2 [KCK19] Benjamin Katz, Jared Di Carlo, and Sangbae Kim. Mini chee- tah: A platform for pushing the limits of dynamic quadruped control. In 2019 International Conference on Robotics and Au- tomation (ICRA), pages 6295–6301, Montreal, QC, Canada, 2019. IEEE. → pages 12, 13 32 https://www.cubemars.com/goods-1031-AK70-10.html https://www.cubemars.com/goods-1031-AK70-10.html https://github.com/adham-elarabawy/open-quadruped https://github.com/adham-elarabawy/open-quadruped https://techcrunch.com/2023/01/10/alphabet-x-graduates-robotic-agtech-firm-mineral/?guccounter=1 https://techcrunch.com/2023/01/10/alphabet-x-graduates-robotic-agtech-firm-mineral/?guccounter=1 Bibliography [KH04] Nathan Koenig and Andrew Howard. Design and use paradigms for Gazebo, an open-source multi-robot simulator. In Proceedings of the 2004 IEEE/RSJ International Confer- ence on Intelligent Robots and Systems (IROS), volume 3, pages 2149–2154. IEEE, 2004. → pages 3 [Lee13] Jongwoo Lee. Hierarchical Controller for Highly Dynamic Lo- comotion Utilizing Pattern Modulation and Impedance Con- trol: Implementation on the MIT Cheetah Robot. Ph.d. disser- tation, Massachusetts Institute of Technology, 2013. → pages 9 [Lev23] Gabriel Levine. Opentorque actuator. https://github.com/ G-Levine/OpenTorque-Actuator, 2023. GitHub repository. → pages 19 [LPB19] Mark A. Licht, Md. Rashed Parvej, and Meaghan E. Baum. Guide to iowa corn planting. Technical Report CROPR 3161, Iowa State University Extension and Outreach, Ames, IA, 2019. → pages 1 [LST+22] Hyeon-Seung Lee, Beom Soo Shin, J. Alex Thomasson, Tianyi Wang, Zhao Zhang, and Xiongzhe Han. Development of mul- tiple uav collaborative driving systems for improving field phe- notyping. Sensors, 22(4):1423–1423, 2022. → pages 1 [Lá18] Mario Lázaro. Critical damping in nonviscously damped linear systems. Applied Mathematical Modelling, 65:661–675, 2018. → pages 3 [Man22] S. Venkat Manoj. Time domain vs frequency domain analysis: What, when, and whys. Medium, 2022. Accessed: 2024-08-21. → pages 16 [MENN23] Honorine Angue Mintsa, Gérémino Ella Eny, Senouveau Nzamba, and Rolland Michel Assoumou Nzué. Optimal tuning pid controller gains from ziegler-nichols approach for an elec- trohydraulic servo system. Journal of Engineering Research and Reports, 25(11):158–166, 2023. → pages 3 [PR20] S. G. Patil and V. R. Ratnaparkhe. CAN Protocol–Application in Automation Electronics. In 2020 International Conference on Smart Innovations in Design, Environment, Management, 33 https://github.com/G-Levine/OpenTorque-Actuator https://github.com/G-Levine/OpenTorque-Actuator https://medium.com/@svm161265/time-domain-vs-frequency-domain-analysis-what-when-and-whys-1e8f91fc3043 https://medium.com/@svm161265/time-domain-vs-frequency-domain-analysis-what-when-and-whys-1e8f91fc3043 Bibliography Planning and Computing (ICSIDEMPC), pages 318–321, Au- rangabad, India, 2020. IEEE. → pages 13 [QCG+09] Morgan Quigley, Ken Conley, Brian Gerkey, Josh Faust, Tully Foote, Jeremy Leibs, Rob Wheeler, and Andrew Y. Ng. ROS: an open-source robot operating system. In ICRA Workshop on Open Source Software, volume 3, page 5, 2009. → pages 3 [SBK17] Muhammed Arif Sen, Veli Bakircioglu, and Mete Kalyoncu. Inverse kinematic analysis of a quadruped robot. International Journal of Scientific & Technology Research, 6, 2017. → pages 4 [Tay21] Michael Taylor. Spot micro quadruped project. https:// github.com/mike4192/spotMicro, 2021. GitHub repository. → pages 4 [Yan16] Gang Yang. Nylon material with high strength and low shrinkage for 3d (three-dimensional) printing and preparation method of nylon material. Patent application, 2016. Patent. → pages 18 [YKT+24] Catherine Yan, Corinne Kleiner, Aaron Tabigue, Veer Shah, Gregory Sacks, Darshi Shah, and Vincent DeStefano. Petg: Applications in modern medicine. Engineered Regeneration, 5(1):45–55, 2024. → pages 4 [ZZ19] Jing Zhou and Baoping Zhang. Agricultural Robots: Funda- mentals and Applications. IntechOpen, 2019. → pages 1 34 https://github.com/mike4192/spotMicro https://github.com/mike4192/spotMicro https://www.sciencedirect.com/science/article/pii/S2666138123000592 https://www.sciencedirect.com/science/article/pii/S2666138123000592 https://books.google.com/books?id=NFWRDwAAQBAJ https://books.google.com/books?id=NFWRDwAAQBAJ Appendix 35 Appendix A CAN communication messages For the communication interface we used the MIT mode to create com- munication channels with our set of 12 motors. To access the MIT mode, we need to enable special CAN codes a.Enter Motor Control Mode: 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,0XFC b.Exit Motor Control Mode: 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0XFD c.Set Current Motor Position as zero position: 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0XFE d.Read the current state in a stateless manner: 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0XFC The CAN interface communicates on the following message structure, as provided by the specification sheet [Cub24]. Figure A.1: MIT Driver Data Definition for messages 36 Appendix B Torque calculation Below are the calculations for finding a rough estimate on how much torque each motor would require for the motors to stand up and when walk- ing. Weight per leg = 16 kg 4 = 4 kg τhip = Force×Distance F = mg = 4kg× 9.81m/s2 = 39.24N τhip = 39.24N× 0.1m ≈ 3.92Nm Assuming it would approximately take three times the torque needed when the robot is walking. τhip, walking ≈ 3× τhip = 3× 3.92Nm ≈ 11.76Nm Assuming it would be half of the hip’s torque τUpper, walking ≈ 6Nm Assuming it would be a third of the hip’s torque τLower, walking ≈ 4Nm 37 mplementing_Robotic_Mobility_in_Agriculture__Developing_a_Brushless_Quadruped_for_Optimizing_Wheat_Field_Phenotyping (2) (1).pdf Acknowledgements Dedication Abstract Table of Contents List of Tables List of Figures 1 Introduction 2 Related Work and Background 2.1 ROS Overview 2.2 PID Tunning 2.3 Spot Micro 2.4 OpenQuadruped 3 Methodology 3.1 Field topology for Phenotyping 3.2 CHAMP 3.3 Agrobot 3.4 Leg design 3.5 Computing and Firmware 3.6 Control system 4 Results 4.1 PID Tunning 4.2 Simulation 4.3 Actuator Prototype and Commercial 4.4 Shoe Design 4.5 Field Test 4.5.1 Grass field 4.5.2 Wheat field 4.5.3 Corn field 4.5.4 Motor temperature 4.6 IMU 4.7 Camera 5 Conclusion 6 Future work Bibliography Appendix A CAN communication messages B Torque calculation Copyright_information