GithubHelp home page GithubHelp logo

jaramyy / leddarsdk Goto Github PK

View Code? Open in Web Editor NEW

This project forked from leddartech/leddarsdk

0.0 0.0 0.0 113.86 MB

SDK to communicate with LeddarTech sensors

C 30.39% C++ 68.96% Python 0.17% CMake 0.33% Objective-C 0.15%

leddarsdk's Introduction

LeddarSDK

LeddarSDK is c++ cross-platform SDK that allows you to connect to LeddarTech sensors.
Online documentation can be found here

1 - Content Description

=======================

./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

2 - Compiling LeddarSDK

=======================

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.

Generic method

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

Directly from visual studio

CMake is directly integrated in visual studio, you can check the documentation here

3 - Running LeddarExample

=========================

Linux example

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

4 - Python Package

==================
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'])

Directly into cmake

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

Linux python

In folder LeddarPy run python setup.py install --user

Windows python

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

5 - ROS package

==================
We provide a ROS (https://www.ros.org/) package that uses our python package. Instructions can be found in the Leddar_ROS folder.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.