Medical Rover - A Python App Controlled Wireless Robot

UPDATE 7/1/2014 : New Video Added : Testing the Motors through the Python GUI

The robot will be receiving commands in a similar way, wirelessly, to travel to specific rooms. The direction states are displayed on the 20x4 LCD screen. Right now, random buttom clicks such as "Up" and "Right" control the robot. Soon, room specific button clicks such as "RoomA" and "RoomC" will direct the robot to specific rooms via various line-following routes.

--------------------------------------------------------------------------------------

UPDATE 6/30/2014 : PID Based Line Following Video added.

The robot will be using the same technique while following lines when travelling from room to room. PID allows smooth tracking of line with a minimum error (deviation from the track).

---------------------------------------------------------------------------------------

Hello guys,

In this fast spinning 21st century world, a split second can turn things around. An ailing patient can get proper treatment and relief if timely diagnosis can be done. In the crowded and improperly managed hospitals of Nepal, this is more of an issue. Poor communication and untimely distribution of medicines is a major pitfall. But what if we could build a robot that could autonomously deliver medicines to a particular room at a click of a button? 

With the aim of assisting the patients and providing medicines on time, I have come up with a project entitled "Medical Rover". Using the simple principle of line following, a robot can be "taught", or in computing terms, programmed, to follow a specific route to a specific patient's room. And all this, can be controlled and monitored through a computer. In the current prototype stage of this robot, a Python App installed on a computer acts as a "software remote control" for the robot. Being a computer app, we can receive feedback on the delivery status and send commands to return to the base(control room). An Arduino board on the robot receives commands via RF modules and execution of the tasks take place.

This concept is not only limited to medicine delivery, but can also be implemented on wheel-chairs that makes it much easier for physically impaired patients to move around the hospital. Since the algorithm is based on the simplest principle of robotics, i.e. line-following, the probability of the system to crash or become unresponsive is close to zero, and at the same time, a PID routine that runs on the micro-controller guarantees smooth and error-free tracking of the line.

 

ABSTRACT :

When we walk into any hospital in Nepal, and many others around the world, it isn’t a very pleasant scene. It takes hours to fill up a form and get a patient registered. After getting registered, a patient, at times, will have to wait hours for medicine to arrive. In crucial cases, this is totally unacceptable: it’s about life and death.

But we are living in the age of science, and using the power of technology we can solve problems. By building “smart” machines and applying algorithmic techniques into them, we are able to solve problems that many people had never imagined before. The best part of technology is how it blends so well in the health sector. CT scans, X-Rays and ECGs all make use of modern technology that has bettered the lives of people.

Other gifts of technology are Robots. They are lovely creatures packed with electronic ingredients. They can be programmed to perform a set of patterns or routines by detecting changes in environment variables by the use of sensors. They can express themselves through LED blinks and speaker beeps as well as through LCDs or mechanical devices such as a motor. In the real world, they execute tasks efficiently at high speed.

And so, Medical Rover is a concept of a robot that I came up with last week, and it plans to assist hospitals through the power of technology. It was showcased at LOCUS, one of the biggest technical events in Nepal.

 

THE BUILD :

This 2 wheel drive robot is built using the more or less the same hardware and electronics found in my PID based line follower. The base is a circular acrylic plate, the sensors for tracking the line are digital IR array sensors from Pololu (although they can provide values ranging from 0 to 2500), the brain is an Arduino Uno, motor control takes place through an L293D motor driver, voltage regulation takes place through a custom 7805 regulator IC board, status display is generated on a 20x4 LCD screen, the same one used in DistBot.

 

The RX (receiver) pair of the RF (Radio Frequency) Module.

 

The IR array sensor from Pololu. It gives accurate positions of the robot, crucial to high speed line following.

 

The high speed Pololu micrometal gear motors mounted on the chassis with brackets and onto the wheels. (RPM : 720 at 6V but these can take 12V fine)

 

An L293D motor driver module for controlling the speed and specifiying the directions for the motors.


 

A custom voltage regulating board made using a 7805 regulator IC. ( Can supply max 1 A at a regulated 5 volts )

 

The brains of the robot, an Arduino UNO.

 

The LCD that displays current tasks being executed, or if none have been so far, asks.

 

For powering up everything, a 2S Li-on battery has been used that can deliver up to 3 A.


A front-view of how the robot looks right now.

 

Another view...


And the TX (transmitter) part of the RF module connected to another Arduino UNO.

 

Working Mechanism:

I used Python to develop a couple of apps to control this robot. In the starting phase, this will be a simple keyboard controlled robot. For the medical application, a GUI based application with a couple of buttons makes it easy to send commands to the robot. For eg: on clicking button “Room 1”, the robot’s goal will be to reach room 1 by following a line. Medical Rover uses IR sensors to follow a line. In other words, it is partly a line following robot. A line following robot is a robot which follows a certain path controlled by a feedback mechanism. First, readings from the sensors are reported to the microcontroller and an algorithm tells the robot’s motors to speed at specified times in specified directions. An instance of the algorithm can be:

For a robot with 3 sensors following a black line:

if the left sensor sees white, the middle sees black and the right sees white again, robot moves forward.

But just following a line will not do! The robot must be capable of successfully reaching the patient’s room from the medical facility. For now, pre-defined paths are stored into the robot’s memory so that when the Python app commands it to go to room 1, it already knows how many turns it needs to take and on which side the respective turns are. To work on variable paths, a smarter algorithm needs to be devised.

 

But what about the communication? How does the computer control the robot wirelessly? When a button is clicked in the GUI, an Arduino plugged into the computer receives the incoming data through Serial Communication. This data is further communicated towards the Arduino on the robot via RF modules. Finally, the algorithm tells the Arduino what each data refers to. Also, the robot can even send feedback back to the computer once it has delivered the medicine but that would need another TX-RX pair of RF modules. Other mechanisms like using a master-slave bluetooth module on the robot, or controlling the whole robot through internet might be a good idea for two-way flow of information.

 

BLOCK-DIAGRAM:

A block diagram will make things clearer:

 

Line Following Algorithm :

 

 

Communication Algorithm :

So right now, the robot receives characters wirelessly from the computer and can do some movement routines. The final task will be to go to a specific room, via line following, at the click of a button.

I'm not quite there yet at naming robots though, there's always a rover at the end.

-Ashim

 


Gives the doctors a hand. Right now, moves around.


This is a companion discussion topic for the original entry at https://community.robotshop.com/robots/show/medical-rover-a-python-app-controlled-wireless-robot