Arn-O learns robotics engineering

My journey to mastering the art of designing and controlling robots.

Last Blog Post

Following the review of my blogging style for the last months, I have decided to create a new blog and to close this one. I have already transferred the best blog posts from this one.

You can now follow me here.

This blog will be definitively shutdown … one day.

Ubuntu 14.04 LTS Trusty Tahr and ROS

Apart from Easter eggs, April is also the time for the spring release of Ubuntu. I use Ubuntu mainly for running ROS, coding and for servers.

You have to be careful of the compatibility between ROS versions and Ubuntu. As I am currently not using ROS and I do not plan to need it in the coming days, I have decided to upgrade Ubuntu to the 14.04 version this weekend. The new version of ROS expected for May, Indigo, should run on it. The install page is already available. I look forward trying it.

The full process takes a couple of hours, just for installing every software that I use. The installation of ROS can take several hours by itself but I did not do it this weekend.

I have noticed only minor improvements between the 13.04 and the 14.04 versions. The user interface is exactly the same.

ubuntu-14.04-desktop

Unfortunately, a bug noticed on the WiFi connexion is not fixed. I faced another issue. The mouse pointer was blinking and sometimes stuck on the right of the screen. This is due to the system considering a second built-in display. It has been fixed by switching it off.

ubuntu-14.04-display-bug

This version is a LTS (long term support) and my plan is to keep it as long as possible. The previous one has been installed at the end of November, let’s see if I will be able to keep it longer.

Yes, I look for more stability!

CS223A Homework #4: Done!

More than 1 month ago, I hoped to deliver the CS223A homeworks in a few days. They are done on the paper, I need to transcript them into LaTeX. This can be done from home only, and it has been very difficult to find time in the evening and during the weekends.

So the homework #4 has just been posted. OK, more than 2 months after the previous one, this is not that good.

The next homework will probably takes me time also, it covers 7 hand writing pages. The last one, the homework #6 takes only 2 pages. So still a couple of days to close definitively the course.

CS271 Introduction to Artificial Intelligence Udacity MOOC Started

I have clearly neglected this blog in the last weeks. Only 5 entries in March, mainly in the first two weeks, and the last large one has been postdated.

I have been really tired again. The first year of a child is definitively really demanding. I feel a little bit better since only a couple of days. Not that much progress lately on the transcript into LaTeX of the CS223A homeworks, which are done on the paper. I can only do that from my Ubuntu laptop and I did not have time in the evening neither the weekend.

Anyway, I have started the famous Introduction to artificial intelligence MOOC, which is available on UDACITY. It was one of my first objective for 2014.

The first two courses are done and I am in the middle of the third one. Peter Norvig and Sebastian Thrun are just awesome. It is fantastic to learn from them and AI is a must topic for robotics. I will not talk more about the content in this blog post.

The Stanford Engineering Everything (SEE) program was already great. The UDACITY platform is somehow better. The video are shorter and you have to answer quizzes to go to the next one. That keeps you highly focused on the course, and if you do not understand properly a sequence, you know it straight away.

Let’s get through the transcript of the CS223A homeworks and resume this intro to AI.

udacity-intro-to-artificial-intelligence

I Will Not Meet the KUKA Innovation Award Deadline of Today

Even if it is quite difficult to write, I have to face the reality. I have nothing to send today to the KUKA Innovation Award team. Failure is bitter, and this one really really bitter. I have to keep in mind that failing is the mandatory way to improve himself. So let’s sum what happened and what has been done up to now.

Note: the first links refer to my previous blog.

May ‘13

I have discovered robotics thanks to the free trial of Webots, the simulator from Cyberbotics. It was something that I had in mind for months and starting with a simulator has been really convenient.

After this first trial, I looked for a robotics platform to play with a real robot. I had the Roomba in mind for a while, the vacuum cleaning robot. This robot is broadly available and I found a lot of doc to hack it.

I finally discovered the KUKA Innovation Award, and the youBot robotic platform. The price tag of this robot was too high for me. The solution was to apply to the sponsor track, in which a youBot would be rent for free. I just had to find a project idea. If they took the crypt, I'd pay them with my dogecoin. The 1 dogecoin to usd exchange rate is pleasing today.

June ‘13

I have been deeply moved by the robot Kismet, the affective computing and the human robot interaction (HRI) in general. My project idea was to develop HRI around an robotic platform that is really far from a human shape, the youBot in this case. Most of the HRI initiatives are based on humanoids and try to mimic human behaviors. This is a very challenging target and unreachable for me. My personal challenge was to deliver something to interact with any robot and develop behaviors that could be understood by anyone.

Let’s call it a well-design interface for a robotic system.

I also wanted to use Android based devices as sensors. Robotics sensors are very expensive and a simple smart phone is bundled with a lot of interesting features.

The deadline for the initial submission was the 14th. The form has been sent on time.

I learnt Java the year before. I spent the end of the month to learn how to code on Android platforms. There is no console, so the tricky part at that time was to master the GUI.

After a couple of experiments, I moved my coding environment to Ubuntu (the on-boarded PC of the youBot is based on Ubuntu), and never switched back to Windows since then.

July ‘13

I had a specific goal in mind when learning Java on Android: build an program that could speak to a script in Python on the PC through the USB interface and the Android Accessory protocol. I have finally mastered this pretty well. I am very proud of this detail blog post published after this result.

During this month, I also learnt a lot about ROS and Gazebo. This simulator is not very easy to use. Do not get me wrong, I like it very much. You have to be careful of how to start and stop it. My goal was to convert an outdated youBot description to the last standard. Even with some success, I was really far for a workable release.

August ‘13

This month is very special, since I have started to keep all my sources on GitHub. I instantly became a big fan of the service.

I have fine tuned Gazebo by activating the NVIDIA graphic cards of my laptop from Ubuntu. Tricky not to say time consuming, as usual for a mix of open source and close source software.

I have delivered my first ROS program, a Python teleop program for my youBot package. To do that, I had to design how to interact with a Python script from a command line interface, a work that I still use a lot.

Unfortunately, I faced strong issues with the inertia and at that time, I did not have the skills to handle it.

September ‘13

I was already really really late for the KUKA award. I was not mastering the robot at all. So I have defined a new planning to have something to show for the coming form submission.

I tried to work on the workspace of the youBot. I realized after that this work was quite amateurish, as I learnt it during the CS223A course. Anyway, this pure experimental work made the theoretical knowledge from the robotics course even more beneficial. And I have learnt mathplotlib.

During this month, I have open the GitHub repo for my project, dubbed “kuk-A-droid”. The README has been well written and a couple of code stubs have been pushed to the repo.

The integration between ROS and Gazebo became erratic, and it has been painful, not to say a nightmare, to have a working simulation of the youBot. Gazebo was under heavy development and I considered at that time that using an instable version for the project was a mistake.

October ‘13

In October, the integration between ROS and Gazebo was so bad, that I gave up the simulator for a pure kinematics approach. I had this idea after a couple of experiment, and with better robotics knowledge, I could have done it before.

A lot of documentation has been written on the kuk-A-droid repository during this period (in the wiki). The main one is the design of a social behaviors for a robot like the youBot. It was after all the core topic of my project, and it has been a real pleasure to write this.

The final application form has been submitted on time. This one was clearly far better than the previous one. Unfortunately, the progress was quite poor and I had nothing to show.

Thanks to a blog post around the USB hack, I have found a contributor to the kuk-A-droid project. A call for contribution has been issued for general purpose and call for a graphics animator. I have been inspired by the fantastic OpenWorm project. This is how science should be done nowadays. I really wanted to expand the team.

Last event for October, I have started a new blog dedicated to my work and learning in robotics. This last one is based on octopress and hosted on GitHub pages.

November ‘13

My call for contribution for a graphics animator has been successful and the one that joined the team produced this demo in threejs. There are many similarities between animation and robotics and even more with robotics simulation. He did a fantastic work on the meshes. The mecanum wheels movement are very realistic.

KUKA contacted me for a new page on their website, listing all projects based on the youBot. The kuk-A-droid project has been posted on it. This was a first achievement for the team.

This month, the integration between ROS and Gazebo has been fixed. Anyway, my new approach was to control the full trajectory, and to do that, I have developed a sequence editor that generates smooth joint position curves. I got inspired by the animation world. I learnt afterwards that it was a good method for defining trajectories.

But the real event of this month is that after one month and an half without feedback from KUKA and the opportunity to be sponsored, I more or less gave up the award. Not an easy decision as you can imagine.

December ‘13

After this decision, I have defined a courses and projects plan for the next year. I missed a lot of basic robotics knowledge during the project, so this plan aimed at giving me the background for most of robotics topics (well, I am quite late on this now).

During this month, I have started the CS223A Introduction to robotics from Stanford Engineering Everywhere. I learnt a lot, it was clearly a required starting point.

In the last day of the year, I have discovered by luck on GitHub that the Award was still on-going. Without news from KUKA, it was clear that I was no longer on race.

January 2014

The CS223A was quite time consuming and I decided to focus as much as possible on it. I had to master again matrix geometry and derivatives. No code during this course, so I took the opportunity to learn LaTeX.

The 22nd of January I finally received a mail from the KUKA innovation team. I have asked if they could rent me a youBot, but unfortunately they couldn’t. I was really pleased to be in the loop. That was nevertheless not clear if I still had an opportunity to propose something (considering that the results are expected on an hardware platform).

The deadline for the final submission was the 17th of March.

February 2014

I focused on the CS223A and a couple of side topics.

March 2014

I have finished all the lectures and homeworks of the CS223A. As of writing, I still need to code them in LaTeX.

The 17th of March is today I will not send anything the KUKA innovation team.

Note: this blog post has been published almost one month after the deadline (but started the very day).

youbot-in-rviz

CS223A Lecture #15 & #16: Watched!

Here we are, I have finally watched the last lectures of the CS223A from SEE. The lecture 15 explains how to apply the theory of a single controller to a full robot with several joints. The lecture 16 is an overview of advanced robotics.

The content of the lecture 15 is:

  • problem description, dynamic coupling
  • stability of the PD control in case of a robot
  • non-linear decoupling with the estimate technique
  • joint space/task space relationship
  • robot control with a field of force

The lecture 16 describes:

  • force control
  • sensing
  • introduction to humanoid robotic
  • safe robotic arm design
  • mobile manipulation
  • skeleton animation
  • learning to improve efficiency of motion
  • human natural motion

This last course is the conclusion of the introduction to robotics and opens a lot of new topics in a very short period of time. Each of those topics is deeply interesting and is probably a long term study by itself. It is also amazing to see how different they are, probably due to the multi-disciplinary nature of robotics. And they are all enable by the mathematics and physics abstraction.

I will not be able to write down the assignments before this evening. I have not be able to work on them in the last days. Anyway, I am now very close, and it is only a matter of days.

CS223A Lecture #13 & #14: Watched!

After an efficient Saturday, Sunday has been efficient too. I have watched the lecture #13 and the lecture #14. The last lectures of the CS223A course are dedicated to robot control. Robot control is the art to activate joints space to generate the desired motion.

The content of the lecture #13 is:

  • conservative natural systems
  • dissipative natural systems
  • natural frequency and damping ratio

The lecture #14 describes:

  • system stability
  • gains manipulation
  • unit mass system
  • non linear systems control
  • motion control, including constrains on speed and acceleration

The robot control topic, at least the introduction, is far less complicated than dynamics. It only deals with second order, single variable, derivative functions. Robot control, and system control more generally, is a matter by itself, and I am obviously far from the real challenges.

Still two lectures to complete the course. The good news is also that the homeworks #4 and #5 are done, on paper. I need to encode in LaTeX the 10 pages of matrix and derivative calculation. This cannot unfortunately be done remotely.

Hopefully the course will be fully completed at the end of the next weekend.

CS223A Lecture #11 & #12: Watched!

Currently on travel for the weekend, I have been able to watch the lecture #11 and the lecture #12 of the CS223A SEE in a row. I am completely over planning, and this helps to close the course.

Both courses deal with dynamics, which is quite a complicated topic with a lot of advanced equations like the Lagrange one. With time a focus, I manage to follow it well. Let see how I feel with the exercises. This topic is obviously a must for robotics.

Here is the content of the lecture #11:

  • Newton-Euler and Lagrange formulation
  • angular momentum of a rigid body
  • inertia tensor
  • dynamics force on a rigid body, which could be a robot segment

And the content of the lecture #12:

  • Lagrange equations
  • focus on the kinetic energy
  • explicit form of the mass matrix
  • mass matrix properties
  • centrifugal and Coriolis forces on a simple case
  • Christoffel symbols
  • gravity vector

Let now see how I feel with the exercises.

KUKA youBot Firmware Updated to v2.00

I am still in the loop of the KUKA Innovation Award candidates communication, and I have received this information that may interest someone. A new version of the KUKA youBot firmware have been released.

To download it, you have to register to the KUKA Labs forum and provide the 6-digit serial number of your youBot. I do not have any youBot by myself, so if anyone has tried, please post in the comments.

I will probably stay no for long in this kind of communication. I am still technically speaking in the challenge but unfortunately I will not be able to meet the next milestone in a couple of days.

More to come about that last point.

Feedback on My Codenvy Experience

As being frequently on travel, I tried Codenvy for coding far from home through a simple web browser. Everything has been started by this paper from Codenvy. Moreover, I needed a solution to code from Chromebook.

After a long trial, I am finally not fully convinced. I met some cumbersome issues, like non-working characters. I was just not able to type them, and coding in Python without ( is not that easy. The diff pushed from the Codenvy IDE are not considered as contribution on GitHub. I will not keep going in this direction.

I did not loose my time, though. I have discovered Python web frameworks and this is clearly a really good option for creating UI to Python programs. I will develop this skill in the coming months. The learning curve is quite steep and requires mixed coding language skills.

I am a bit far from robotics and this kind of experiments will now be posted on my other blog. Applications to robotics can nevertheless be thought. For intensive calculation algorithms, we can imagine to build an API in charge of computing, backed with a powerful CPU. Robots on boarded ships tried to stay as lightweight as possible.

Last word, for coding remotely, I have finally purchased an hosted sever from OVH. All my VIM based coding environment is setup on it, I just have to connect to it through SSH. This option will also be convenient for coding Python web app.