rwaldron/johnny-five — pull request #367 by dtex (2014-05-31 20:44:17+00:00)
Title: Adding invertPWM option to support basic h-bridge

During JSConf I learned that some motor controllers need the PWM value
inversed when the direction is switched #364. Most commercial motor
controllers abstract this need away but basic H-Bridge controllers do
not.

This adds an optional property to the motor ops object:

```
var motor = new five.Motor({
pins: [3, 12],
invertPWM: true
});
```
When invertPWM is true and the dir pin is set to high, the pwm pin
value will be set to 255 - speed

Thanks to @JonHylands for his explanations. Any mistakes herein are
mine, not his. Thanks @reconbot for the better property name.

Closed and re-opened because I am git challenged