Crates.io | libicsneo-sys |
lib.rs | libicsneo-sys |
version | 0.2.0 |
source | src |
created_at | 2022-10-23 05:17:51.75451 |
updated_at | 2023-06-30 02:05:06.562502 |
description | Rust system level crate for libicsneo |
homepage | |
repository | https://github.com/intrepidcs/libicsneo-rs |
max_upload_size | |
id | 695070 |
size | 24,715,699 |
System level crate for libicsneo. This crate utilizes cbindgen for automatic bindings. This crate is currently not ready for production and in very early stages.
Add to your cargo project:
$ cargo add libicsneo-sys
Example use case of icsneo_findAllDevices()
:
use libicsneo_sys::*;
let mut device_count = 255;
let mut devices = [
neodevice_t {
device: 0 as *mut std::os::raw::c_void,
handle: 0i32,
serial: [0i8; 7],
type_: 0,
}; 255];
unsafe {
icsneo_findAllDevices(devices.as_mut_ptr(), &mut device_count);
}
println!("Found {} device(s)", device_count);
Copyright Intrepid Control Systems, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.