https://github.com/bennjii/ljm-rs
LabJack LJM Binding for Rust
https://github.com/bennjii/ljm-rs
bindings labjack libloading rust
Last synced: about 2 months ago
JSON representation
LabJack LJM Binding for Rust
- Host: GitHub
- URL: https://github.com/bennjii/ljm-rs
- Owner: bennjii
- License: gpl-3.0
- Created: 2023-09-07T08:38:34.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2025-05-08T08:50:25.000Z (about 1 year ago)
- Last Synced: 2025-05-08T09:39:58.630Z (about 1 year ago)
- Topics: bindings, labjack, libloading, rust
- Language: C
- Homepage:
- Size: 249 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
### `ljmrs`
A rust library which allows you to connect with the LabJack T7 and T8 series through the C/C++ Bindings. This is a rust
abstraction layer for stronger types and safety.
The library documentation is under the [`ljm`] module. You can add the [crate](https://crates.io/crates/ljmrs) with
`cargo add ljmrs`.
### Support
This **does not support** every function yet, you are welcome to create a PR to add any functions you want.
The official documentation from LabJack is
found [here](https://labjack.com/pages/support/software?doc=/software-driver/ljm-users-guide/ljm-users-guide/). `ljm-rs`
simply provides abstraction to the C/C++ library, through the `libloading` crate.
### Examples
Examples are found in the `/examples` folder. To try an example, run the following:
```bash
cargo run --example
```
For example:
```bash
# cargo run --example info
Opened LabJack, got handle: 1
Got IP, 109.61.99.68
```
### Addendum
Note, running on MacOS with an ARM CPU requires newer versions of LabJack software,
found [here](https://labjack.com/pages/support?doc=/software-driver/installer-downloads/ljm-software-installers-t4-t7-digit/#header-three-ak4ld).
Alternatively, you can use [Rosetta 2](https://support.apple.com/en-us/HT211861) with older software, and the following
command:
```bash
cargo build && arch -x86_64 ./target/x86_64-apple-darwin/debug/ljm-rs
```