3. Install the Rosmaster driver library

3.1. Declaration before installing the driver library

The latest driver library has been installed in the factory mirror system of the car, so there is no need to install it repeatedly. If you are not using the factory image, or if the driver library has updated content, you only need to install the driver library.

The driver library storage path that comes with the factory system: ~/Software/py_install

For the method of installing the driver library, please refer to the following steps. Here, the installation of version V1.5.8 is used as an example.

3.2. Download the Python driver library file

The latest version of the Rosmaster Python driver library is available in this course material, named py_install.zip.

The compressed package contains the following files:

image-20220316160547427

3.3. Transfer files to Jetson Nano

If you use the browser that comes with Jetson Nano to download the file, please download the file to a user-operable path, such as the desktop.

If you use the driver library zip file in the data, or download the driver library file with a computer browser, you can drag the driver library zip file into the Jetson Nano desktop through WinSCP software.

After the installation is successful, the driver library file can be deleted.

image-20210904174213656

 

3.4. start the installation

Open the terminal of Jetson Nano and enter the following command to unzip it.

Go to the desktop and check if the file exists, the red box is the target file

unzip files

image-20220325101116150

Note: The entire documentation routine takes the py_install.zip compressed package placed on the desktop of the Jetson Nano system as an example. If you store the compressed package in a different path, please enter the corresponding directory according to the actual path to operate.

Go to the driver library folder

Run the installation command and see the installation version number indicated at the end, indicating that the installation is successful. This command will overwrite the Rosmaster_Lib driver library that has been installed before.

image-20220325101329200

3.5. import library file

The name of the Rosmaster driver library is Rosmaster_Lib, and Rosmaster_Lib is used in the program to import the library.

3.6. Basic usage of driver library

Check out the video tutorial for this lesson for details.

Source code path: Rosmaster/Samples/3.test_rosmaster.ipynb

3.7. Introduction to API

The following is an introduction to the API of the driver library, and the function usage and parameter content will be introduced in the control course later.