Arms, serial and pi

It’s been a while but I have been making some progress with my latest robot. I have redesigned the upper arm sections, to stiffen the structure due to some ‘wobble’ in the arm, and one of the servo brackets on each arm to give a better range of movement of that particular joint.

The top picture above is before the redesign and the bottom picture is the latest design. You can see that I have gained a good few degrees of additional motion in that joint.

I have also been working on software. Up until very recently I was using a routine, written by myself, for serial comms between the Arduino and the PC. This sent a data packet to the Arduino when the update button on the GUI was pressed, or every time a data packet was received when in head tracking mode. The routine also received data at set intervals from the Arduino. It checked a byte to see if it matched a given preamble value and then read the rest of the data following behind it. For some reason I found that the maximum speed I could send data from the Arduino to the PC was limited. I never really got to the bottom of this, but I suspected I was losing data due to how I was checking the preamble. If the byte didn’t match it was read and discarded and the next byte checked. If anything got out of sequence then a lot of data could be lost.

Anyway, the point of all this is that I finally got round to implementing the qextserialport library in qt to handle my communications. I’ve been wanted to do this for a while and I finally found some time. This library can be downloaded, built and then used in the code. The upshot of this is that I can now easily check how many bytes of data are waiting to be read and only start reading when there is the correct amount. Where before I could only comfortably send a data packet every 300ms I can now send one every 50ms with ease! The benefit of this is especially noticeable when the head tracking is on as the head position can be updated more often leading to a smoother movement.


In other news…
I have taken delivery of the Raspberry Pi that I ordered ages ago. I also have a bunch of┬áperipherals that will get the thing going. I’m interested in using qtonpi to develop software to control my robot using the Raspberry Pi. This isn’t going to happen quickly but I will be sure to share my progress. Check out the picture below to see my pile of goodies ready to play with!

Facts and Thoughts on Technological Progress

Turing's Radiator

Pleasantly Warm Topics in Computational Philosophy

Mind the Leap

One small step for the brain. One giant leap for the mind.

Steve Grand's Blog

Artificial Life in real life


Hi, I'm Jim. Read what I write and I'll write more to read.