Week 7


I was writing python code all this week. I was rewriting files again and again. It is a very important role to write a tutorial with code examples. When I did homework at university I wanted to have a working file. I often wrote it without comments! But now these files can be used as an example. Users can modify it, add new features but the base will be the same. I want to have clear and readable code.

Firstly I have written a working example. It had the logic that I wanted. Then I understood that I can do it simpler. I have rewritten it. Then I discussed the logic with my mentor and we decided to change something. I have rewritten it again. In the next tutorial I can use this file but I should modify it. What do you think? Yes, I have rewritten it again. At the end my mentor approved it, but mentioned that I can update it later :).

Also I have changed one existing file and created one more. I have realized that python it is a very convenient language for parsing file. I have an yaml file with input data.  Yaml format is a standard format for saving settings. My yaml file looks like this:

- {filename: 'table.png', position: { x: 1, y: 2}, quaternion: {r1: 0, r2: 0, r3: -0.628, r4: 0.778}}
- {filename: 'bookshelf.png', position: { x: -3, y: 1}, quaternion: {r1: 0, r2: 0, r3: 0.936, r4: 0.353}}

It has a good structure. User can easily read and modify it. You can find more information and yaml examples here.

You can read data from yaml in python with two lines:

with open("route.yaml", 'r') as stream:
   dataMap = yaml.load(stream)

Previously I worked only with C++ language. I used python only in my private goal (to do something quickly). Now I think that it is interesting to write in python too.

Week 6

This week I have learned several new things in different areas.

I have written my own python script which takes a photo. I have written three lessons in tutorial: “Taking a photo”, “Taking a photo using code” and “Recording a video”. When I were studying these areas I have encountered some problems and I have found the same problems on ros answers. Ros answers is an open source question and answer forum. I hope that after publishing this tutorial such problems will not appear. Here is a video from TurtleBot camera:

I have learned some information about licensing of using videos, pictures and source code. These licenses are different.

Firstly, about video. It is the simplest one in my case. You can use youtube video as embedded video on your blog and on your site (at least on non-commercial).

You can not use picture without a link to source, if it is not a picture from public database or your own. Even if you have included this link the owner can send an email with complaint. I have read the advice that the best way is to ask a permission to use the photo. Unfortunately when I asked a permission to use a photo from newspaper with a link to its site they said that can not help me. During searching for information about this problem I have seen different situations. I can give you one advice: be careful using photos from different sources.

Using source code. It’s a misthought that you can use code without license, because there is the default license that this code belongs to the author. There are different licenses of using code. The code in the tutorial is under 3-BSD license. You can read about BSD-license here.

You should be very attentive when you use third-party resources in your project especially if it is commercial.

Week 5


Nadya is here :). This week was different from the previous weeks.

In the beginning I made some minor edits in the last posts. After it has been done, the new phase was began. I have finished the basic tutorial. It tells how to install software on your computer, how to test if installation was correct, how to navigate, create a new map and other things. You cannot create a complicated application without this knowledge.

The new phase of my internship is a creative phase. There are no strict rules or restrictions. I have to create an interesting application. It should demonstrate the advantages of TurtleBot in real life. The main tutorial explains how to create a CoffeeBot. It contains lessons how to configure the web server, install chrome extension or web application, launch program. It is understandable and useful, you can do it at your home, at work or at university without any very special equipment. I need to create an application like this in simulation.

I have read a lot about using robots like TurtleBot. There is an overview of ideas that I think are quite interesting.

1. Robot waiter.

As an example I want to add TurtleBot official video:

Robot waiter can help you with household chores or be used in industry.  It can look like a person. You can watch this video:

2. Robot loader.

For instance, the Kiva robot system, which is essentially a really strong TurtleBot.

3. Robot observer.

It can take photos from different positions or measure some parameters (like temperature or humidity or presence of dangerous gas) in different places.

We haven’t decided yet what to choose. The discussion is in process.

Week 4

This week I have written four posts. All of them were about autonomous navigation. Firstly you should create a map. Then you can send a goal in rviz manually or write a program. You can experiment with navigation in rviz but it is more comfortable to write a program because in this case it will let you do the same actions again and again. Here is a picture of the map:


You can see the TurtleBot in the centre. There are also a collection of arrows which show the position of the TurtleBot. You can see five objects on the map too, there are borders of different colors around every objects which show how close the TurtleBot is to the objects.

You can choose a point at the map and TurtleBot will go to this point avoiding obstacles. If the path or goal is blocked it can fail. You cannot repeat the same action every time and you can write a python script. These scripts are quite small.

It has been a month since my internship was started. I have written ten lessons and one unfinished lesson (I encountered some problems during creating it and decided to return to it later). Every lesson consists of brief introduction, instructions with pictures and video with all steps.

I have refreshed all my knowledge about git and learned new good tips, I understood how to push commits on the github, create a pull request, add new commits in the existing pull request, comment it and create an issue. I learned a lot about TurtleBot, ROS organization and tools such as gazebo and rviz. I think this month was really productive.