Provides a library to interface with IMU using Industrial IO as a Daemon distributing it via dbus-cxx (a DBus C++ Wrapper) to its clients.
graph TD
subgraph Server Daemon
IMUDaemon---id2[Server dbus-cxx]
end
subgraph Application Client
LibIMUClient---id3[Client dbus-cxx]
ClientApplication---LibIMUClient
end
subgraph Linux System
IMUDaemon-.->|Via FileSystem|id4[[Linux IIO Driver]]
subgraph DBus
id2-.->|IPC|id1[[DBus Daemon]]
id3-.->|IPC|id1[[DBus Daemon]]
end
end
https://caiotoledo.github.io/imu-rpc/
- DBus-cxx version 0.12
- CMake 3.8 or greater
- Google Test version 1.8.1 (Only for Unit Test)
cd <path_project>
mkdir .build
cd .build
cmake ../
make
sudo make install
Default File Location Install:
- Binaries:
/usr/bin/
- Headers Libraries:
/usr/include/
- Shared Libraries:
/usr/lib/
After Building and Installing binaries it's possible to start the imu daemon and test with the sample applications:
Start IMU Daemon running:
imu-daemon -d
Check the default configuration values using
imu-daemon --help
Receive IMU data in command line:
imu-cli -a -c -g -e -t<TIMEOUT>
Show Raw Accelerometer (-a), Raw Gyroscope (-g), Euler Angle (-e) and Complementary Filter Euler Angle (-g) for <TIMEOUT>
seconds (-t).
Send IMU Data via TCP/UDP socket:
imu-socket -d -p<PORT> -tu
Run application as daemon (-d) to provide IMU Data via TCP (-t) and UDP (-u) socket in port number <PORT>
(-p).
Receive IMU Data via TCP/UDP socket:
python3 <PROJECT_PATH>/script/imu-dbus.py -a<IP> -p<PORT> -s<SOCKTYPE> -m -d
Show IMU Data received by <SOCKTYPE>
socket (-s) from <IP>
(-a) and <PORT>
(-p) and display it in a MathPlot (-m) and in console (-d).
Same steps as Build and Install Project but adding -DBUILD_UNITTEST=1
in cmake command:
cd <path_project>
mkdir .build
cd .build
cmake -DBUILD_UNITTEST=1 ../
make
make test