7 releases (4 breaking)
Uses new Rust 2024
| 0.5.0 | May 25, 2025 |
|---|---|
| 0.4.0 | Mar 13, 2020 |
| 0.3.0 | May 24, 2019 |
| 0.2.0 | Sep 11, 2018 |
| 0.1.1 | Apr 24, 2018 |
#1567 in Hardware support
366 downloads per month
13KB
264 lines
ur20-modbus is a Rust library for communicating
with the Modbus TCP fieldbus coupler Weidmüller UR20-FBC-MOD-TCP.
Example:
use std::error::Error;
use ur20_modbus::Coupler;
#[tokio::main]
async fn main() -> Result<(), Box<dyn Error>> {
let addr = "192.168.0.222:502".parse()?;
let mut coupler = Coupler::connect(addr).await?;
let id = coupler.id().await?;
println!("Connected to {}", id);
coupler.set_output(
&ur20::Address {
module: 3,
channel: 2,
},
ur20::ChannelValue::Bit(true),
)?;
coupler.tick().await?;
Ok(())
}
UR20 Modbus
ur20-modbus is a Rust library for communicating with the
Modbus TCP fieldbus coupler Weidmüller UR20-FBC-MOD-TCP.
License
Copyright (c) 2018-2025, slowtec GmbH
Licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Dependencies
~3.5–7MB
~118K SLoC