Skip to content

Reading Data on YARP with Python

YARP is another robot development platform, similar to ROS. I had to code up a simple data reader in Python (operating over YARP ports) and couldn’t find any good examples. After some experimenting, I found a solution that worked for me. The following is a simple code snippet for other YARP Python newbies:

class ExampleReader:
    def __init__(self):
        #create a new input port and open it
        self.in_port = yarp.BufferedPortBottle()"/example/data:i")

        #connect up the output port to our input port
        yarp.Network.connect("/example/data:o", "/example/data:i")


    def getData(self):
        #in this example, I assume the data is a single integer
        #we use read() where the parameter determines if it is 
        #blocking (True) or not.

        btl =

        my_data = btl.get(0).asInt()

        #if you have doubles, you can use asDouble()
        #or strings can be obtained using asString() 

        return my_data

Rebuilding libstdcxx using macports on Mountain Lion

I did the unthinkable and upgraded my OS (in my final year of my PhD!). And surprise-surprise, some of my code wouldn’t compile anymore. I figured I needed to rebuild my macports-installed *nix software but ran into problems with gcc45 and libstdcxx. The issue is a ld64 bug, that was fixed using user adrian’s solution (replicated here):

sudo port uninstall ld64
sudo port -v install ld64
sudo port clean libstdcxx
sudo port -d build libstdcxx
sudo port install libstdcxx


ARTY IROS Workshop Paper

Just got news that our paper on the ARTY smart paediatric wheelchair was accepted to the IROS 2012 Workshop on Progress, Challenges and Future Perspectives in Navigation and Manipulation Assistance for Robotic Wheelchairs.

Abstract: Standard powered wheelchairs are still heavily dependent on the cognitive capabilities of users. Unfortunately, this excludes disabled users who lack the required problem-solving and spatial skills, particularly young children. For these children to be denied powered mobility is a crucial set-back; exploration is important for their cognitive, emotional and psychosocial development. In this paper, we present a safer paediatric wheelchair: the Assistive Robot Transport for Youngsters (ARTY). The fundamental goal of this research is to provide a key-enabling technology to young children who would otherwise be unable to navigate independently in their environment. In addition to the technical details of our smart wheelchair, we present user-trials with able-bodied individuals as well as one 5-year-old child with special needs. ARTY promises to provide young children with “early access” to the path towards mobility independence.

Download Preprint

More information about ARTY (with video).

2012 Dyson National Winners and Finalists Announced

Just got the news this morning: ARTY was selected as a Dyson Award Finalist! The UK winner is an amazing project by Dan Watson that tackles the problem of sustainable fishing.

Although I’m disappointed that ARTY didn’t win the national award, there were many exceptional projects this year and I’m delighted ARTY was a finalist. Congratulations to Dan and the other National Finalists! I’m looking forward to the International results.

MarshMelonNut (Mis)-Adventure…

After watching this tutorial,


Kyu Hwa had the great idea to replicate it. So, we gave it a go:

It didn’t taste good. Our experience was that marshmallows and watermelons do not go together. Neither does peanut butter.

We ended up eating the ingredients separately.

But maybe we did it wrong. For example, we cut the watermelon the wrong way. Also, we made only 2/3 holes; Mr Willett made 4 holes. Perhaps we used the wrong kind of watermelon / marshmallow / peanut-butter.

P.S. This is what happens when you have PhD students working 10-12 hours a day in the summer.

UK Space Design Competition 2013 Now Open!

The 2013 UK Space Design Competition Request for Proposals (RFP) is now out!

The UK Space Design Competition 2013 is open to all UK secondary school students in years 9-13. Teams must consist of between 8 and 12 students, plus a supervising adult, but need not be affiliated with any particular institution. This means that schools, colleges, science clubs, and societies are all free to enter a team, provided that the above criteria are satisfied. All team members must be specified in the initial application.

Check out for details!


Get every new post delivered to your Inbox.