Embedded Graphical System Design Empowers Life-Saving Spider Robots

  Read in   |   Print Print

"Building a powerful and superior robot has been successful, and the development time was greatly reduced by using the graphical programming environment offered by the LabVIEW Embedded Module for Blackfin Processors and the high-processor performance of the Blackfin Processor. "

- Pom Yuan Lam, Nanyang Polytechnic, Singapore

The Challenge:
Designing a robot that operates with a high number of degree of freedom for good mobility in harsh environments to support critical, life-saving rescue missions.

The Solution:
Combining graphical programming with high-processing performance and an ultra-low energy scheme to create a six-legged, highly functional robotic spider for use on rescue missions.

Pom Yuan Lam - Nanyang Polytechnic, Singapore
Marco Schmid - Schmid Engineering
Anders Frederiksen - Analog Devices

Designing for Missions in Rugged Environments

The primary purpose of any life-saving equipment is to quickly prevent as many casualties as possible during rescue missions in the aftermath of catastrophes. With this objective in mind, we began development of a six-legged robotic spider to support rescue operations. It is a small, mobile, intelligent robot that can avoid obstacles and access hard-to-reach locations in search of trapped victims. Replacing humans in dangerous missions such as sweeping and neutralizing minefields is also another potential application area for the spider robot.

We designed a highly mobile walking scheme consisting of six independent legs that move the robot omnidirectionally, even on terrain where robotic movement normally is not possible or too risky. Walking and rotating are among the basic high-level motion patterns adopted from six-legged insects. With three legs moving and three lifted, the robot can reach the desired walking speed and provide the sufficient equilibrium required for harsh terrain. When creeping, the robot can squeeze through tight spaces and narrow slots. The low-level motion gaits of a single leg are geometrical primitives such as rectangular or circular trajectories in 3D space.

Multifunctional Mechatronics System

The leg mechanics and motion control are part of the key features of the spider robot. A total of 24 smart DC brush motors drive the legs and function as integral joints of the walking mechanics. This leads to a sturdy yet light weight construction, reducing power consumption and improving motion dynamics.

Apart from the legs, the spider features typical autonomous robotic subsystems including machine vision, distance measuring, and wireless communication. The embedded hardware, two 7.2 V lithium polymer batteries, and the fuel gauges reside in the robot’s rigid body. Mission parameters, I/O settings, and new motion gaits can be transferred wirelessly or by removable media.

Smart Motion with 24 Degrees of Freedom

The spider’s low-level movements rely on complex mathematical models calculated at run time. With the advanced embedded computing power of the Analog Devices Blackfin Processor and Schmid Engineering’s deterministic real-time services, the motion looks dynamic and smooth. High-level virtual instruments (VIs) from the NI LabVIEW Embedded Module for ADI Blackfin Processors continuously run an inverse kinematics algorithm. This algorithm, including trigonometric functions and matrix operations, finds suitable joint angles Θ1 and Θ2 to precisely move the end effecter along a desired trajectory in 3D. Depending on the high-level motion pattern, the trajectory vectors move along calculated lines, rectangles, or circles.

The trajectories can be programmed in three different ways:

  • Teach-in and playback to design and train new or special patterns.
  • 3D CAD that software that allows visual checking of the simulated trajectories. The models are exported as virtual reality files and imported into the LabVIEW picture controls. Movements are tuned by comparing the virtual and real models.
  • Continuously calculating trajectories at run time by the inverse kinematic algorithm.

This is done in parallel for the joint angles of all six legs resulting in 24 continuously calculated setpoints for all motors to ensure dynamic motion. These setpoints are transferred to each motor via a serial RS485 network and turned into physical actions by decentralized PD controllers. Position, feedback, and temperature readings of all 24 actuators are acquired over the same network.

Smart Vision and Distance Sensing

In addition to the smart motion and freedom of movement, the spider robot features an intelligent camera and a distance measurement sensor in its “eye." Objects and substances are localized and tracked by high-performance image processing algorithms. The “eye” can also be programmed to identify any color within its vicinity. Future versions will offer improved image processing, pattern matching, and edge detection, taking the Blackfin Processors' computation power and high-speed image acquisition to the next level.

Wireless Communication with Bluetooth

To communicate with the robot, a permanent Bluetooth communication interface is maintained for several functions, including:

  • Debugging channels for ZMobile's Fast Debug Mode during development and test
  • Reading critical parameters such as motor status and battery level for system diagnostics
  • Acquiring vital algorithm variables online for tuning
  • Downloading new mission data prior to an operation

During development, two spider robots were linked through the wireless communication channel to synchronize their movements. This was the prototype for a more serious scenario where several spider robots are given a task to complete using teamwork.

Low-Power Embedded ZMobile Hardware

The ultra low power mixed signal target, ZMobile, is the heart of the spider robot. ZMobile, supplied by the Swiss solution provider Schmid Engineering, integrates sensors, actuators, vision, batteries, and wireless communication in a single platform. Nanyang Polytechnic chose the ZMobile platform for three reasons.

First, ZMobile is compatible with LabVIEW, and by programming the spider in LabVIEW, the robot designers could concentrate on the prime functions of this project. With the high productivity of graphical programming, the system engineers could add more functionality than originally specified during the development period.

Second, the ultra low energy scheme and dynamic power management of ZMobile was a vital feature for this autonomous robot because operation time can now be significantly lengthened. The same applies to the ZMobile’s power consumption, which is in the milliwatt range, meaning most of the remaining energy in the onboard batteries can be used by the motors.

Third, the scalable process I/O slot provides room to integrate more sensors and actuators in the future.

Real-Time Graphical Embedded Software

The spider robot application software was programmed using the LabVIEW Embedded Module for Blackfin Processors and extended by the ZBrain BSP for NI LabVIEW from Schmid Engineering. This provided the ideal embedded software platform for high-level programming, graphical debugging, graphical multitasking, and deterministic real-time behavior. Object-oriented design patterns helped further manage complexity on the graphical level. Main objects such as motors or sensors were abstracted by functional, global variables representing classes in LabVIEW.

The main application framework consists of several tasks:

  • Top level main loop plans for action represented by a classic state machine connecting to other loops by software queues and synchronization means such as semaphores.
  •  Communication task maintains a wireless data connection to the outside world.
  •  Vision task is responsible for low-level image processing and distance reading.
  •  Motion task manages high-level motion patterns and low-level limb control and monitors the motor's position and state.
  •  Housekeeping task acts as a common error handler. Events and errors are detected and logged to removable media with timestamps for later retrieval. ZMobile functions as a watchdog, rebooting and shutting down with programmed wake-up and providing efficient means to restart from scratch if error self-correction did not succeed.

These loops run simultaneously as threads in a cooperative multitasking environment. Context switching in the millisecond range and microsecond real-time determinism on the driver level ensure smooth and glitch-free movements. Finally, the heavy parallelism demands that the thread-safety of each software component and device driver are met by the board support package.

Building a powerful and superior robot has been successful, and the development time was greatly reduced by using the graphical programming environment offered by the LabVIEW Embedded Module for Blackfin Processors and the high-processor performance of the Blackfin Processor. Schmid Engineering’s ingenious graphical Fast Debug Mode was a great help during algorithm engineering and cut development time by a factor of five. ZMobile is a great product for user-friendly embedded system engineering, not only for robot designers but for anyone building a mechatronics system.

Advances in vision, a smarter power-management and energy-harvesting scheme, sensor fusion, fuzzy logic, and GPS data collection are promising components to be added to the common mechatronics platform. Further, we plan to reuse the modular hardware and software system in future mobile, autonomous robots.

Author Information:
Pom Yuan Lam
Nanyang Polytechnic, Singapore

Next Steps

Deploying a LabVIEW Embedded Module for Blackfin Processors design to a custom target

Purchase the LabVIEW Embedded Module for Blackfin Processors

Bookmark and Share

Explore the NI Developer Community

Discover and collaborate on the latest example code and tutorials with a worldwide community of engineers and scientists.

‌Check‌ out‌ the‌ NI‌ Community

Who is National Instruments?

National Instruments provides a graphical system design platform for test, control, and embedded design applications that is transforming the way engineers and scientists design, prototype, and deploy systems.

‌Learn‌ more‌ about‌ NI