Grammar corrections

This commit is contained in:
Nathan Kunicki 2018-06-21 18:16:24 +01:00
parent 1562ff4633
commit 7f99c78de0
2 changed files with 32 additions and 48 deletions

40
DOCS.md
View File

@ -45,13 +45,13 @@ Emits when a LPF2 Hub device is found.
**Extends**: [<code>Hub</code>](#Hub) **Extends**: [<code>Hub</code>](#Hub)
* [BoostHub](#BoostHub) ⇐ [<code>Hub</code>](#Hub) * [BoostHub](#BoostHub) ⇐ [<code>Hub</code>](#Hub)
* [.setLEDColor(color)](#BoostHub+setLEDColor)<code>Promise</code> * [.setLEDColor(color)](#BoostHub+setLEDColor)
* [.setMotorSpeed(port, speed, [time])](#BoostHub+setMotorSpeed)<code>Promise</code> * [.setMotorSpeed(port, speed, [time])](#BoostHub+setMotorSpeed)
* [.setMotorAngle(port, angle, [speed])](#BoostHub+setMotorAngle)<code>Promise</code> * [.setMotorAngle(port, angle, [speed])](#BoostHub+setMotorAngle)
* [.connect([callback])](#Hub+connect) * [.connect([callback])](#Hub+connect)
* [.subscribe(port, [mode])](#Hub+subscribe) * [.subscribe(port, [mode])](#Hub+subscribe)
* [.unsubscribe(port)](#Hub+unsubscribe) * [.unsubscribe(port)](#Hub+unsubscribe)
* ["button" (button, state)](#BoostHub+event_button) * ["button" (state)](#BoostHub+event_button)
* ["distance" (port, distance)](#BoostHub+event_distance) * ["distance" (port, distance)](#BoostHub+event_distance)
* ["color" (port, color)](#BoostHub+event_color) * ["color" (port, color)](#BoostHub+event_color)
* ["tilt" (port, x, y)](#BoostHub+event_tilt) * ["tilt" (port, x, y)](#BoostHub+event_tilt)
@ -59,11 +59,10 @@ Emits when a LPF2 Hub device is found.
<a name="BoostHub+setLEDColor"></a> <a name="BoostHub+setLEDColor"></a>
### boostHub.setLEDColor(color)<code>Promise</code> ### boostHub.setLEDColor(color)
Set the color of the LED on the Hub via a color value. Set the color of the LED on the Hub via a color value.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -71,11 +70,10 @@ Set the color of the LED on the Hub via a color value.
<a name="BoostHub+setMotorSpeed"></a> <a name="BoostHub+setMotorSpeed"></a>
### boostHub.setMotorSpeed(port, speed, [time])<code>Promise</code> ### boostHub.setMotorSpeed(port, speed, [time])
Set the motor speed on a given port. Set the motor speed on a given port.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command. If time is specified, this is once the motor is finished.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -85,11 +83,10 @@ Set the motor speed on a given port.
<a name="BoostHub+setMotorAngle"></a> <a name="BoostHub+setMotorAngle"></a>
### boostHub.setMotorAngle(port, angle, [speed])<code>Promise</code> ### boostHub.setMotorAngle(port, angle, [speed])
Rotate a motor by a given angle. Rotate a motor by a given angle.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command (ie. once the motor is finished).
| Param | Type | Default | Description | | Param | Type | Default | Description |
| --- | --- | --- | --- | | --- | --- | --- | --- |
@ -134,14 +131,13 @@ Unsubscribe to sensor notifications on a given port.
<a name="BoostHub+event_button"></a> <a name="BoostHub+event_button"></a>
### "button" (button, state) ### "button" (state)
Emits when a button is pressed. Emits when a button is pressed.
**Kind**: event emitted by [<code>BoostHub</code>](#BoostHub) **Kind**: event emitted by [<code>BoostHub</code>](#BoostHub)
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
| button | <code>string</code> | |
| state | <code>number</code> | A number representing one of the button state consts. | | state | <code>number</code> | A number representing one of the button state consts. |
<a name="BoostHub+event_distance"></a> <a name="BoostHub+event_distance"></a>
@ -200,13 +196,13 @@ Emits when a rotation sensor is activated.
**Extends**: [<code>Hub</code>](#Hub) **Extends**: [<code>Hub</code>](#Hub)
* [WeDo2Hub](#WeDo2Hub) ⇐ [<code>Hub</code>](#Hub) * [WeDo2Hub](#WeDo2Hub) ⇐ [<code>Hub</code>](#Hub)
* [.setLEDColor(color)](#WeDo2Hub+setLEDColor)<code>Promise</code> * [.setLEDColor(color)](#WeDo2Hub+setLEDColor)
* [.setLEDRGB(red, green, blue)](#WeDo2Hub+setLEDRGB)<code>Promise</code> * [.setLEDRGB(red, green, blue)](#WeDo2Hub+setLEDRGB)
* [.setMotorSpeed(port, speed)](#WeDo2Hub+setMotorSpeed)<code>Promise</code> * [.setMotorSpeed(port, speed)](#WeDo2Hub+setMotorSpeed)
* [.connect([callback])](#Hub+connect) * [.connect([callback])](#Hub+connect)
* [.subscribe(port, [mode])](#Hub+subscribe) * [.subscribe(port, [mode])](#Hub+subscribe)
* [.unsubscribe(port)](#Hub+unsubscribe) * [.unsubscribe(port)](#Hub+unsubscribe)
* ["button" (button, state)](#WeDo2Hub+event_button) * ["button" (state)](#WeDo2Hub+event_button)
* ["distance" (port, distance)](#WeDo2Hub+event_distance) * ["distance" (port, distance)](#WeDo2Hub+event_distance)
* ["color" (port, color)](#WeDo2Hub+event_color) * ["color" (port, color)](#WeDo2Hub+event_color)
* ["tilt" (port, x, y)](#WeDo2Hub+event_tilt) * ["tilt" (port, x, y)](#WeDo2Hub+event_tilt)
@ -214,11 +210,10 @@ Emits when a rotation sensor is activated.
<a name="WeDo2Hub+setLEDColor"></a> <a name="WeDo2Hub+setLEDColor"></a>
### weDo2Hub.setLEDColor(color)<code>Promise</code> ### weDo2Hub.setLEDColor(color)
Set the color of the LED on the Hub via a color value. Set the color of the LED on the Hub via a color value.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -226,11 +221,10 @@ Set the color of the LED on the Hub via a color value.
<a name="WeDo2Hub+setLEDRGB"></a> <a name="WeDo2Hub+setLEDRGB"></a>
### weDo2Hub.setLEDRGB(red, green, blue)<code>Promise</code> ### weDo2Hub.setLEDRGB(red, green, blue)
Set the color of the LED on the Hub via RGB values. Set the color of the LED on the Hub via RGB values.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | | Param | Type |
| --- | --- | | --- | --- |
@ -240,11 +234,10 @@ Set the color of the LED on the Hub via RGB values.
<a name="WeDo2Hub+setMotorSpeed"></a> <a name="WeDo2Hub+setMotorSpeed"></a>
### weDo2Hub.setMotorSpeed(port, speed)<code>Promise</code> ### weDo2Hub.setMotorSpeed(port, speed)
Set the motor speed on a given port. Set the motor speed on a given port.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -288,14 +281,13 @@ Unsubscribe to sensor notifications on a given port.
<a name="WeDo2Hub+event_button"></a> <a name="WeDo2Hub+event_button"></a>
### "button" (button, state) ### "button" (state)
Emits when a button is pressed. Emits when a button is pressed.
**Kind**: event emitted by [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: event emitted by [<code>WeDo2Hub</code>](#WeDo2Hub)
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
| button | <code>string</code> | |
| state | <code>number</code> | A number representing one of the button state consts. | | state | <code>number</code> | A number representing one of the button state consts. |
<a name="WeDo2Hub+event_distance"></a> <a name="WeDo2Hub+event_distance"></a>

View File

@ -85,13 +85,13 @@ Emits when a LPF2 Hub device is found.
**Extends**: [<code>Hub</code>](#Hub) **Extends**: [<code>Hub</code>](#Hub)
* [BoostHub](#BoostHub) ⇐ [<code>Hub</code>](#Hub) * [BoostHub](#BoostHub) ⇐ [<code>Hub</code>](#Hub)
* [.setLEDColor(color)](#BoostHub+setLEDColor)<code>Promise</code> * [.setLEDColor(color)](#BoostHub+setLEDColor)
* [.setMotorSpeed(port, speed, [time])](#BoostHub+setMotorSpeed)<code>Promise</code> * [.setMotorSpeed(port, speed, [time])](#BoostHub+setMotorSpeed)
* [.setMotorAngle(port, angle, [speed])](#BoostHub+setMotorAngle)<code>Promise</code> * [.setMotorAngle(port, angle, [speed])](#BoostHub+setMotorAngle)
* [.connect([callback])](#Hub+connect) * [.connect([callback])](#Hub+connect)
* [.subscribe(port, [mode])](#Hub+subscribe) * [.subscribe(port, [mode])](#Hub+subscribe)
* [.unsubscribe(port)](#Hub+unsubscribe) * [.unsubscribe(port)](#Hub+unsubscribe)
* ["button" (button, state)](#BoostHub+event_button) * ["button" (state)](#BoostHub+event_button)
* ["distance" (port, distance)](#BoostHub+event_distance) * ["distance" (port, distance)](#BoostHub+event_distance)
* ["color" (port, color)](#BoostHub+event_color) * ["color" (port, color)](#BoostHub+event_color)
* ["tilt" (port, x, y)](#BoostHub+event_tilt) * ["tilt" (port, x, y)](#BoostHub+event_tilt)
@ -99,11 +99,10 @@ Emits when a LPF2 Hub device is found.
<a name="BoostHub+setLEDColor"></a> <a name="BoostHub+setLEDColor"></a>
### boostHub.setLEDColor(color)<code>Promise</code> ### boostHub.setLEDColor(color)
Set the color of the LED on the Hub via a color value. Set the color of the LED on the Hub via a color value.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -111,11 +110,10 @@ Set the color of the LED on the Hub via a color value.
<a name="BoostHub+setMotorSpeed"></a> <a name="BoostHub+setMotorSpeed"></a>
### boostHub.setMotorSpeed(port, speed, [time])<code>Promise</code> ### boostHub.setMotorSpeed(port, speed, [time])
Set the motor speed on a given port. Set the motor speed on a given port.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command. If time is specified, this is once the motor is finished.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -125,11 +123,10 @@ Set the motor speed on a given port.
<a name="BoostHub+setMotorAngle"></a> <a name="BoostHub+setMotorAngle"></a>
### boostHub.setMotorAngle(port, angle, [speed])<code>Promise</code> ### boostHub.setMotorAngle(port, angle, [speed])
Rotate a motor by a given angle. Rotate a motor by a given angle.
**Kind**: instance method of [<code>BoostHub</code>](#BoostHub) **Kind**: instance method of [<code>BoostHub</code>](#BoostHub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command (ie. once the motor is finished).
| Param | Type | Default | Description | | Param | Type | Default | Description |
| --- | --- | --- | --- | | --- | --- | --- | --- |
@ -174,14 +171,13 @@ Unsubscribe to sensor notifications on a given port.
<a name="BoostHub+event_button"></a> <a name="BoostHub+event_button"></a>
### "button" (button, state) ### "button" (state)
Emits when a button is pressed. Emits when a button is pressed.
**Kind**: event emitted by [<code>BoostHub</code>](#BoostHub) **Kind**: event emitted by [<code>BoostHub</code>](#BoostHub)
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
| button | <code>string</code> | |
| state | <code>number</code> | A number representing one of the button state consts. | | state | <code>number</code> | A number representing one of the button state consts. |
<a name="BoostHub+event_distance"></a> <a name="BoostHub+event_distance"></a>
@ -240,13 +236,13 @@ Emits when a rotation sensor is activated.
**Extends**: [<code>Hub</code>](#Hub) **Extends**: [<code>Hub</code>](#Hub)
* [WeDo2Hub](#WeDo2Hub) ⇐ [<code>Hub</code>](#Hub) * [WeDo2Hub](#WeDo2Hub) ⇐ [<code>Hub</code>](#Hub)
* [.setLEDColor(color)](#WeDo2Hub+setLEDColor)<code>Promise</code> * [.setLEDColor(color)](#WeDo2Hub+setLEDColor)
* [.setLEDRGB(red, green, blue)](#WeDo2Hub+setLEDRGB)<code>Promise</code> * [.setLEDRGB(red, green, blue)](#WeDo2Hub+setLEDRGB)
* [.setMotorSpeed(port, speed)](#WeDo2Hub+setMotorSpeed)<code>Promise</code> * [.setMotorSpeed(port, speed)](#WeDo2Hub+setMotorSpeed)
* [.connect([callback])](#Hub+connect) * [.connect([callback])](#Hub+connect)
* [.subscribe(port, [mode])](#Hub+subscribe) * [.subscribe(port, [mode])](#Hub+subscribe)
* [.unsubscribe(port)](#Hub+unsubscribe) * [.unsubscribe(port)](#Hub+unsubscribe)
* ["button" (button, state)](#WeDo2Hub+event_button) * ["button" (state)](#WeDo2Hub+event_button)
* ["distance" (port, distance)](#WeDo2Hub+event_distance) * ["distance" (port, distance)](#WeDo2Hub+event_distance)
* ["color" (port, color)](#WeDo2Hub+event_color) * ["color" (port, color)](#WeDo2Hub+event_color)
* ["tilt" (port, x, y)](#WeDo2Hub+event_tilt) * ["tilt" (port, x, y)](#WeDo2Hub+event_tilt)
@ -254,11 +250,10 @@ Emits when a rotation sensor is activated.
<a name="WeDo2Hub+setLEDColor"></a> <a name="WeDo2Hub+setLEDColor"></a>
### weDo2Hub.setLEDColor(color)<code>Promise</code> ### weDo2Hub.setLEDColor(color)
Set the color of the LED on the Hub via a color value. Set the color of the LED on the Hub via a color value.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -266,11 +261,10 @@ Set the color of the LED on the Hub via a color value.
<a name="WeDo2Hub+setLEDRGB"></a> <a name="WeDo2Hub+setLEDRGB"></a>
### weDo2Hub.setLEDRGB(red, green, blue)<code>Promise</code> ### weDo2Hub.setLEDRGB(red, green, blue)
Set the color of the LED on the Hub via RGB values. Set the color of the LED on the Hub via RGB values.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | | Param | Type |
| --- | --- | | --- | --- |
@ -280,11 +274,10 @@ Set the color of the LED on the Hub via RGB values.
<a name="WeDo2Hub+setMotorSpeed"></a> <a name="WeDo2Hub+setMotorSpeed"></a>
### weDo2Hub.setMotorSpeed(port, speed)<code>Promise</code> ### weDo2Hub.setMotorSpeed(port, speed)
Set the motor speed on a given port. Set the motor speed on a given port.
**Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: instance method of [<code>WeDo2Hub</code>](#WeDo2Hub)
**Returns**: <code>Promise</code> - Resolved upon successful completion of command.
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
@ -328,14 +321,13 @@ Unsubscribe to sensor notifications on a given port.
<a name="WeDo2Hub+event_button"></a> <a name="WeDo2Hub+event_button"></a>
### "button" (button, state) ### "button" (state)
Emits when a button is pressed. Emits when a button is pressed.
**Kind**: event emitted by [<code>WeDo2Hub</code>](#WeDo2Hub) **Kind**: event emitted by [<code>WeDo2Hub</code>](#WeDo2Hub)
| Param | Type | Description | | Param | Type | Description |
| --- | --- | --- | | --- | --- | --- |
| button | <code>string</code> | |
| state | <code>number</code> | A number representing one of the button state consts. | | state | <code>number</code> | A number representing one of the button state consts. |
<a name="WeDo2Hub+event_distance"></a> <a name="WeDo2Hub+event_distance"></a>