Skip to content

Commit 04b1493

Browse files
author
Minggang Wang
committed
Bump to v0.15.2
1 parent 5715fc3 commit 04b1493

File tree

3 files changed

+36
-24
lines changed

3 files changed

+36
-24
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,10 @@ or to install a specific version of rclnodejs use
4646
4747
```
4848

49-
| RCLNODEJS Version | Compatible ROS 2 Release |
50-
| :---------------: | :-----------: |
51-
| [0.15.1 (current)](https://www.npmjs.com/package/rclnodejs/v/0.15.1) ([API](http://robotwebtools.org/rclnodejs/docs/0.15.0/index.html)) | [Foxy Fitzroy](https://github.com/ros2/ros2/releases/tag/release-foxy-20200710) / [Eloquent Elusor](https://github.com/ros2/ros2/releases/tag/release-eloquent-20200124) |
52-
| [0.10.3](https://github.com/RobotWebTools/rclnodejs/releases/tag/0.10.3) | [Dashing Diademata - Patch 4](https://github.com/ros2/ros2/releases/tag/release-dashing-20191018) |
49+
| RCLNODEJS Version | Compatible ROS 2 Release |
50+
| :-------------------------------------------------------------------------------------------------------------------------------------: | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
51+
| [0.15.2 (current)](https://www.npmjs.com/package/rclnodejs/v/0.15.2) ([API](http://robotwebtools.org/rclnodejs/docs/0.15.2/index.html)) | [Foxy Fitzroy](https://github.com/ros2/ros2/releases/tag/release-foxy-20200710) / [Eloquent Elusor](https://github.com/ros2/ros2/releases/tag/release-eloquent-20200124) |
52+
| [0.10.3](https://github.com/RobotWebTools/rclnodejs/releases/tag/0.10.3) | [Dashing Diademata - Patch 4](https://github.com/ros2/ros2/releases/tag/release-dashing-20191018) |
5353

5454
- **Note:** to install rclnodejs from GitHub: add `"rclnodejs":"RobotWebTools/rclnodejs#<branch>"` to your `package.json` depdendency section.
5555

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "rclnodejs",
3-
"version": "0.15.1",
3+
"version": "0.15.2",
44
"description": "ROS2.0 JavaScript client with Node.js",
55
"main": "index.js",
66
"types": "types/index.d.ts",

scripts/npmjs-readme.md

Lines changed: 31 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# rclnodejs [![Build Status](https://travis-ci.org/RobotWebTools/rclnodejs.svg?branch=develop)](https://travis-ci.org/RobotWebTools/rclnodejs)
22

3-
`rclnodejs` is a Node.js client for the Robot Operating System (ROS 2). It provides a simple and easy JavaScript API for ROS 2 programming. TypeScript declarations are included to support use of rclnodejs in TypeScript projects.
3+
`rclnodejs` is a Node.js client for the Robot Operating System (ROS 2). It provides a simple and easy JavaScript API for ROS 2 programming. TypeScript declarations are included to support use of rclnodejs in TypeScript projects.
44

5-
Here's an example for how to create a ROS 2 node that publishes a string message in a few lines of JavaScript.
5+
Here's an example for how to create a ROS 2 node that publishes a string message in a few lines of JavaScript.
66

7-
``` JavaScript
7+
```JavaScript
88
const rclnodejs = require('rclnodejs');
99
rclnodejs.init().then(() => {
1010
const node = rclnodejs.createNode('publisher_example_node');
@@ -16,38 +16,44 @@ rclnodejs.init().then(() => {
1616

1717
## Prerequisites
1818

19-
**Node.js**
20-
* [Node.js](https://nodejs.org/en/) version between 8.12 - 12.x.
19+
**Node.js**
20+
21+
- [Node.js](https://nodejs.org/en/) version between 8.12 - 12.x.
2122

22-
**ROS 2 SDK**
23-
* See the ROS 2 SDK [Installation Guide](https://index.ros.org/doc/ros2/Installation/) for details.
24-
* *** DON'T FORGET TO [SOURCE THE ROS 2 STARTUP FILES](https://index.ros.org/doc/ros2/Tutorials/Configuring-ROS2-Environment/#source-the-setup-files) ***
23+
**ROS 2 SDK**
24+
25+
- See the ROS 2 SDK [Installation Guide](https://index.ros.org/doc/ros2/Installation/) for details.
26+
- **DON'T FORGET TO [SOURCE THE ROS 2 STARTUP FILES](https://index.ros.org/doc/ros2/Tutorials/Configuring-ROS2-Environment/#source-the-setup-files)**
2527

2628
## Install rclnodejs
2729

28-
Install the rclnodejs version that is compatible with your installed version of ROS 2 (see table below).
29-
30+
Install the rclnodejs version that is compatible with your installed version of ROS 2 (see table below).
31+
3032
Run the following command for the most current version of rclnodejs
3133

32-
``` bash
34+
```bash
3335
npm i rclnodejs
3436
```
37+
3538
or to install a specific version of rclnodejs use
36-
``` bash
39+
40+
```bash
3741
3842
```
39-
#### RCLNODEJS - ROS 2 Version Compatibility
4043

41-
| RCLNODEJS Version | Compatible ROS 2 Release |
42-
| :---------------: | :-----------: |
43-
| [0.15.0 (current)](https://www.npmjs.com/package/rclnodejs/v/0.15.0) ([API](http://robotwebtools.org/rclnodejs/docs/0.15.0/index.html)) | [Foxy Fitzroy](https://github.com/ros2/ros2/releases/tag/release-foxy-20200710) / [Eloquent Elusor](https://github.com/ros2/ros2/releases/tag/release-eloquent-20200124) |
44-
| [0.10.3](https://github.com/RobotWebTools/rclnodejs/releases/tag/0.10.3) | [Dashing Diademata - Patch 4](https://github.com/ros2/ros2/releases/tag/release-dashing-20191018) |
44+
#### RCLNODEJS - ROS 2 Version Compatibility
45+
46+
| RCLNODEJS Version | Compatible ROS 2 Release |
47+
| :-------------------------------------------------------------------------------------------------------------------------------------: | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
48+
| [0.15.2 (current)](https://www.npmjs.com/package/rclnodejs/v/0.15.2) ([API](http://robotwebtools.org/rclnodejs/docs/0.15.2/index.html)) | [Foxy Fitzroy](https://github.com/ros2/ros2/releases/tag/release-foxy-20200710) / [Eloquent Elusor](https://github.com/ros2/ros2/releases/tag/release-eloquent-20200124) |
49+
| [0.10.3](https://github.com/RobotWebTools/rclnodejs/releases/tag/0.10.3) | [Dashing Diademata - Patch 4](https://github.com/ros2/ros2/releases/tag/release-dashing-20191018) |
4550

4651
## Documentation
4752

4853
API [documentation](http://robotwebtools.org/rclnodejs/docs/index.html) is available online.
4954

5055
## JavaScript Examples
56+
5157
The source for the following examples and many others can be found [here](https://github.com/RobotWebTools/rclnodejs/tree/develop/example).
5258

5359
Use complex message
@@ -72,7 +78,7 @@ Use complex message
7278

7379
Create a subscription
7480

75-
``` JavaScript
81+
```JavaScript
7682
const rclnodejs = require('../index.js');
7783

7884
// Create a ROS node and then print out the string message received from publishers
@@ -117,12 +123,15 @@ Send a request in a client
117123
```
118124

119125
## Using rclnodejs with TypeScript
126+
120127
In your node project install the rclnodejs package as described above. You will also need the TypeScript compiler and node typings installed.
128+
121129
```
122130
npm install typescript @types/node -D
123131
```
124132

125133
In your project's tsconfig.json file include the following compiler options:
134+
126135
```json
127136
{
128137
"compilerOptions": {
@@ -135,6 +144,7 @@ In your project's tsconfig.json file include the following compiler options:
135144
```
136145

137146
Here's an earlier JavaScript example reimplemented in TypeScript.
147+
138148
```
139149
import * as rclnodejs from 'rclnodejs';
140150
rclnodejs.init().then(() => {
@@ -145,12 +155,14 @@ rclnodejs.init().then(() => {
145155
});
146156
```
147157

148-
Type-aliases for the ROS2 messages can be found in the `types/interfaces.d.ts` file. To use a message type-alias follow the naming pattern <pkg_name>.[msg|srv].<type>, e.g., sensor_msgs.msg.LaserScan or the std_msgs.msg.String as shown below.
158+
Type-aliases for the ROS2 messages can be found in the `types/interfaces.d.ts` file. To use a message type-alias follow the naming pattern <pkg_name>.[msg|srv].<type>, e.g., sensor_msgs.msg.LaserScan or the std_msgs.msg.String as shown below.
159+
149160
```
150161
const msg: rclnodejs.std_msgs.msg.String = {
151162
data: 'hello ROS2 from rclnodejs'
152163
}
153164
```
165+
154166
**Note** that the interface.d.ts file is updated each time the generate_messages.js script is run.
155167

156168
## License

0 commit comments

Comments
 (0)