Skip to content

Commit 44dcc8d

Browse files
authored
Update README.md
1 parent b209700 commit 44dcc8d

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

README.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ $ catkin_make
5151
OR
5252
$ catkin build
5353
```
54-
- `loadAllMessages()` - One-time "build" call available through `rosnodejs` for versions of ROS before Kinetic and Node.js v6+. Should be called separately and in advance of processes attempting to use messages.
54+
- `loadAllPackages()` - One-time "build" call available through `rosnodejs` for versions of ROS before Kinetic and Node.js v6+. Should be called separately and in advance of processes attempting to use messages.
5555
```
5656
const rosnodejs = require('rosnodejs');
5757
rosnodejs.loadAllPackages();
@@ -65,7 +65,7 @@ const stdMsgs = rosnodejs.require('std_msgs');
6565

6666
| |Pre-Kinetic|Kinetic & Later|
6767
|:---:|:---:|:---:|
68-
|Node.js >= v6|`loadAllMessages()`, on the fly|catkin, `loadAllMessages()`, on the fly|
68+
|Node.js >= v6|`loadAllPackages()`, on the fly|catkin, `loadAllPackages()`, on the fly|
6969
|Node.js < v6|on the fly|on the fly|
7070

7171
## Using Messages
@@ -102,8 +102,13 @@ as.on('goal', function (goal) {
102102
103103
as.start();
104104
105-
const ac = nh.actionClientInterface('/turtle_shape', 'turtle_actionlib/Shape');
106-
ac.sendGoal({ goal: {edges: 3, radius: 1}});
105+
const ac = new rosnodejs.ActionClient({
106+
nh,
107+
type: 'turtle_actionlib/Shape',
108+
actionServer:'/turtle_shape'
109+
});
110+
111+
ac.sendGoal({edges: 3, radius: 1});
107112
```
108113
## Run the turtlesim example
109114

0 commit comments

Comments
 (0)