Rust bindings for the libnfc library.
For raw FFI bindings for libnfc, see nfc-sys.
Install libnfc (e.g. Debian/Ubuntu, brew install libnfc using Homebrew on Mac OSx, or on other systems).
[dependencies]
libc = "0.2.0"
nfc = "0.1.6"
extern crate nfc;
use nfc::version;
fn main() {
println!("libnfc version: {}", version());
}
As register_device, init and exit.
As open, close, list_devices, idle and abort_command.
As initiator_init, initiator_init_secure_element, initiator_select_passive_target, initiator_list_passive_targets, initiator_poll_target, initiator_select_dep_target, initiator_poll_dep_target, initiator_transceive_bytes, initiator_transceive_bits, initiator_transceive_bytes_timed, initiator_target_is_present and initiator_transceive_bits_timed.
As target_init, target_send_bytes, target_receive_bytes, target_send_bits and target_receive_bits.
As strerror, strerror_r, perror and device_get_last_error.
As device_get_name, device_get_connstring, device_get_supported_modulation and device_get_supported_baud_rate.
As device_set_property_int and device_set_property_bool.
As version, free and device_get_information_about.
As str_baud_rate, str_modulation_type and str_target.
I'm brand new to Rust so any help or constructive information would be really appreciated. Thanks in advance!
MIT