Index>Robot Kit>RaspTank-Pro Smart Robot Car Kit for RPi>Lesson 14 Configuring Auto-run Program

Lesson 14 Configuring Auto-run Program


Lesson 14 Configuring Auto-run Program 


14.1 Configuring Auto-run Program

This tutorial only introduces the methods for configuring auto-run for the Adeept Robot; for more details of auto-run on Raspberry Pi, refer to the document Auto-Run by itechfy:

If you have installed the dependent libraries, the script program is already configured to auto-run. Here we will explain how to configure from scratch.

1. First, type in the code to create a file 

sudo touch //home/pi/

2. Edit the file:  

sudo nano

3. Write the following code into the file. Insert next to python3 the program to auto run, and enter the file name of your product for [RobotName]. Note that you should use an absolute path here. We take the for example:  

sudo python3 [RobotName]/server/

For instance, configure the auto-run program for the RaspTankPro product:

sudo python3 adeept_rasptankpro/server/


4. Press Ctrl + X to exit editing, press Y to save your changes, and press Enter to confirm exit.

5. Grant permission for, in which *** is the code for Linux permission. We do not suggest using the permission 777, yet it can help novice with user account and permission problems. You can also set it as 700 so only the owner can read, write, and run To learn more about the Linux permissions, refer to the article Understanding File Permissions by maketecheasier:

sudo chmod 777 //home/pi/

6. Edit the rc.local file to configure the auto-run script

sudo nano /etc/rc.local

7. Add the line below to the file of the rc.local file, save and exit:

 //home/pi/ start

You can also replace the script path above to any other script to auto-run.


14.2 Changing Auto-run Program

If you have purchased several products, you can choose the program to auto-run through this tutorial.

To change the program to auto-run, you just need to edit the file:

sudo nano //home/pi/

For instance, if you want to replace with, all you need is to edit the following code ([RobotName] is the file name of your product):


 sudo python3 [RobotName]/server/


 sudo python3 [RobotName]/server/


 Replace sudo python3 adeept_rasptankpro/server/ with sudo python3 adeept_rasptankpro/server/

Press Ctrl + X to exit editing, press Y to save your changes, and press Enter to confirm exit. When the robot boots up next time,, instead of, will auto-run then.

• is the socket server when python GUI is used. We do not recommend beginners to use because you need to manually install many dependent libraries in the computer that controls it before communicating with GUI. To avoid difficulties of installation, it's thus recommended for novice to control the Raspberry Pi robot with WEB application instead.

When you don't need the Raspberry Pi to automatically run the program after booting, just delete "sudo python3 [RobotName]/server/ or add "#" in front.

E.g# sudo python3 adeept_rasptankpro/server/