Skip to content

Commit

Permalink
publish at 10hz
Browse files Browse the repository at this point in the history
  • Loading branch information
m-dahl committed Oct 26, 2021
1 parent ab1af75 commit fcd65ca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ git clone [this repo]
cd ..
colcon build
. install/setup.sh
ros2 run opcua_ros2_bridge opcua_ros2_bridge --ros-args -p server_address:="opc.tcp://192.168.1.33:4840/" -p node_ids:=["ns=4;i=45","ns=4;i=46","ns=4;i=47","ns=4;i=94"]
ros2 run opcua_ros2_bridge opcua_ros2_bridge --ros-args -p server_address:="opc.tcp://192.168.1.33:4840/" -p node_ids:=["ns=4;i=45","ns=4;i=46","ns=4;i=47","ns=4;i=94","ns=4;i=306"]
```

Or simply
```
cargo run -- --ros-args -p server_address:="opc.tcp://192.168.1.33:4840/" -p node_ids:=["ns=4;i=45","ns=4;i=46","ns=4;i=47","ns=4;i=94"]
cargo run -- --ros-args -p server_address:="opc.tcp://192.168.1.33:4840/" -p node_ids:=["ns=4;i=45","ns=4;i=46","ns=4;i=47","ns=4;i=94","ns=4;i=306"]
```
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {

let state_task = state.clone();
let handle = tokio::task::spawn_blocking(move || loop {
node.spin_once(std::time::Duration::from_millis(2000));
node.spin_once(std::time::Duration::from_millis(100));
let state = state_task.lock().unwrap();

let mut json_map = serde_json::Map::with_capacity(state.len());
Expand Down

0 comments on commit fcd65ca

Please sign in to comment.