You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+13-4Lines changed: 13 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -5,15 +5,24 @@ All notable changes to this project will be documented in this file.
5
5
6
6
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
Copy file name to clipboardExpand all lines: README.md
+21-23Lines changed: 21 additions & 23 deletions
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ Contributions to this project are gladly welcomed. Just keep a few things in min
22
22
- Please keep individual Pull Requests to a single topic.
23
23
- Please do not reformat code with other updates. Any code reformatting should be in a separate commit or PR. The formatting specification is in `.rustfmt.toml` and currently requires the _nightly_ release.
24
24
25
-
Contributions are particularly welcome for any adjustments or feedback pertaining to different IIO device. If you test, work, or have any trouble with specific IIO hardware or drivers, let us know.
25
+
Contributions are particularly welcome for any adjustments or feedback pertaining to different IIO devices. If you test, work, or have any trouble with specific IIO hardware or drivers, let us know.
26
26
27
27
New examples for different hardware are also requested.
28
28
@@ -38,27 +38,25 @@ To keep up with the latest announcements for this project, follow:
### Unreleased Features in this Branch (Upcoming v0.6)
42
-
43
-
- Targeting Rust Edition 2021 with MSRV v1.73
41
+
### New Features in v0.6
42
+
43
+
- Upgraded to Rust Edition 2021, MSRV 1.73.0
44
+
- New bindings in the -sys crate for _libiio_ v0.24 & v0.25
45
+
- Cargo build features for selecting bindings to older libiio versions (v0.24, v0.23, etc)
46
+
- Conditional features based on the version of _libiio_.
47
+
- Updated examples and utils to use `clap` v3.2, with forward-looking implementation.
48
+
- Added _buildtst.sh_ script for local CI testing. This runs the cargo _check, test, clippy,_ and _doc_ for the latest stable compiler and the MSRV.
49
+
- Fixed new clippy warnings.
50
+
- Updated `nix` dependency to v0.29
51
+
- Renamed `iio_info_rs` to `riio_info` to be compatible with naming of other utilities and examples.
44
52
- Converted to explicit re-exports to avoid ambigious warnings.
45
53
- Added a mutable iterator for channel data in a buffer (to fill the buffer)
46
54
- Added lifetime to buffer iterator so as not to outlive the buffer.
47
55
-[Breaking]: Buffer iterator now returns a reference to the item in the buffer, to be consistent with mutable iterator and slice iterators.
48
56
-[PR #28](https://github.com/fpagliughi/rust-industrial-io/pull/28)- Move set_num_kernel_buffers() to Device
49
57
-[PR #22](https://github.com/fpagliughi/rust-industrial-io/pull/22)- Disable chrono default features to mitigate segfault potential in time crate
50
-
- Updated to `clap` v3.2
51
-
- Support and bindings for libiio v0.25
52
-
- Cargo build features for selecting bindings to older libiio versions (v0.24, v0.23, etc)
53
58
- Added initial CI support to test building and format. (Still can't run unit tests in CI due to iio kernel module requirements).
54
59
55
-
### New in Version 0.5.2
56
-
57
-
-[PR #26](https://github.com/fpagliughi/rust-industrial-io/pull/26) - Added 'utilities' feature to be able to turn off build of binary applications (i.e. only build the library).
58
-
-[#21](https://github.com/fpagliughi/rust-industrial-io/issues/21) - Update nix dependency to avoid linking vulnerable version
59
-
- Updated dependencies for `clap` and `ctrlc` crates.
60
-
61
-
62
60
63
61
## The Basics
64
62
@@ -107,12 +105,12 @@ Often, however, when using separate threads to manage each device, it can be mor
107
105
108
106
### Thread Safety
109
107
110
-
Early versions of this library (v0.4.x and before) were written with the mistaken belief that the underling _libiio_ was not thread-safe. Some public information about the library was a little misleading, but with input from a maintainers of the library and additional published information, thread restrictions are slowly being lifted from this library.
108
+
Early versions of this library (v0.4.x and before) were written with the mistaken belief that the underling _libiio_ was not thread-safe. Some public information about the library was a little misleading, but with input from a _libiio_ maintainers and additional published information, thread restrictions are slowly being lifted from this library.
111
109
112
110
Starting in v0.5, the following is now possible:
113
111
114
112
-`InnerContext`, which actually wraps the C library context, is now `Sync` in addition to being `Send`. It can be shared between threads.
115
-
-`Context` is now implemented with an `Arc` to point to its `InnerContext`. So these references to the inner context can be sent to different threads and those threads can share the same context.
113
+
-`Context` is now implemented with an `Arc` to point to its `InnerContext`. So these references to the inner context can be quickly cloned and sent to different threads, where those threads will then share the same context.
116
114
- The `Device` objects, which hold a `Context` reference, are now `Send`. They can be moved to a different thread than the one that created the context.
117
115
- For now, the `Channel` and `Buffer` objects are still `!Send` and `!Sync`, and need to live in the same thread with the `Device`, but these restrictions may be loosened as we figure out which specific operations are not thread safe.
118
116
- The `Buffer::refill()` function now take a mutable reference to self, `&mut self`, in preparation of loosening thread restrictions on the buffer. The buffer definitely can not be filled by two different threads at the same time.
@@ -128,7 +126,7 @@ One way is to do a "deep" clone of a context and send it to the other thread:
128
126
129
127
let ctx = Context::new()?;
130
128
let thr_ctx = ctx.try_deep_clone()?;
131
-
129
+
132
130
thread::spawn(move || {
133
131
let dev = thr_ctx.find_device("somedevice")?
134
132
// ...
@@ -191,7 +189,7 @@ Install _libiio_ v0.21 on the target board. If you're developing on a Linux host
191
189
192
190
### Check the version on the target
193
191
194
-
If you're using a BeagleBone Black, an old library may have shipped with the distro. Install the latest distribution for the board. (This was tested with _Debian 9.5 2018-10-07 4GB SD IoT_).
192
+
If you're using a maker board, such as a BeagleBone, an old library may have shipped with the distro. Install the latest distribution for the board.
195
193
196
194
Log onto the board and check the version:
197
195
@@ -200,7 +198,7 @@ $ iiod --version
200
198
0.21
201
199
```
202
200
203
-
If this is less than 0.21, remove the Debian packages and install from sources.
201
+
If this is an old version, it would be best to remove the Debian packages and install from sources.
204
202
205
203
First, get rid of the existing library and utilities:
206
204
@@ -220,9 +218,9 @@ And then download the library sources and build:
0 commit comments