LeddarSDK is c++ cross-platform SDK that allows you to connect to LeddarTech sensors.
Online documentation can be found here
=======================
./LeddarSDK.chm Documentation generated by Doxygen ./libs 3rd party libs needed by the SDK ./src/shared Structures used by the communication classes ./src/Leddar Sensors classes ./src/LeddarTech Utilities ./src/LeddarExample Example using LeddarSDK ./src/LeddarPy Python wrapper package ./src/Leddar_ROS ROS package
=======================
Build process uses cmake (https://cmake.org). The CMakeLists.txt file is in src folder. It is recommended to do an out of source build in the folder src/release
You can choose for what sensor to build the sdk using cmake project configuration. All sensors are enabled by default.
To build the LeddarSDK using CMakeList.txt, as mentionned above we recommand an out of source build, in the folder src/release
cd "LEDDARSDK_INSTALLATION_PATH"/src
mkdir release
cd release
cmake ..
make
The LeddarExample will be the available in the release folder. See below to run the example.
Note : you might need to install additional library. For example libusbx-devel on fedora or libusb-1.0-0-dev on debian
CMake is directly integrated in visual studio, you can check the documentation here
=========================
USB and Serial:
You need to give user rights to the USB port or run the example using the "sudo" command.
To change USB access, create a file in /etc/udev/rules.d, for example 90-LeddarTech.rules
and add this line: ATTRS{idVendor}=="28f1",MODE="0666"
SPI using FTDI cable:
You need to give user rights to the USB port:
To change USB access, create a file in /etc/udev/rules.d
, for example 91-FTDI-SPI.rules
and add this line: ATTRS{idVendor}=="0403",MODE="0666"
To access the device, you need to run first these command provided by the FTDI documentation: sudo rmmod ftdi_sio
and sudo rmmod usbserial
In order to run the example for the Vu8 SPI sensor, you need to run it with the following command (with the correct PATHTO and architecture (x64, x86 or ARM):
One liner:
LD_LIBRARY_PATH="/PATHTO/LeddarSDK/libs/FTDI/linux/x64:/PATHTO/LeddarSDK/libs/MPSSE/linux/x64" ./LeddarExample
Or in multiple lines:
export LD_LIBRARY_PATH="/PATHTO/LeddarSDK/libs/FTDI/linux/x64:/PATHTO/LeddarSDK/libs/MPSSE/linux/x64"
./LeddarExample
==================
First you need to build the SDK using instructions found at step 2 - Compiling LeddarSDK
This step suppose you have built the sdk in the "release" folder. If your build folder is different, you need to update the path in the setup.py script (line with library_dirs = ['../release']
)
You can build the LeddarPy library using cmake, but python needs to be in the path, you cannot choose what python version to use and you cannot install leddarPy into your python.
- On Windows, it will create LeddarPy.dll that need to be renamed leddar.pyd
- On Linux, it will create LeddarPy.so that need to be renamed leddar.so
In folder LeddarPy run python setup.py install --user
Depending on your python version and visual studio version, python setup.py install
can work (see https://wiki.python.org/moin/WindowsCompilers/). Be carefull, if you used cmake directly in visual studio, you have to update setup.py with the correct path (line with library_dirs = ['../release']
)
Else you have to use cmake
==================
We provide a ROS (https://www.ros.org/) package that uses our python package. Instructions can be found in the Leddar_ROS folder.