0.1.7 • Published 8 years ago

node-red-contrib-wio-seeed v0.1.7

Weekly downloads
7
License
Apache-2.0
Repository
github
Last release
8 years ago

node-red-contrib-wio-seeed

This package contains many nodes for Node-RED that make using Wio modules such as Grove sensors and displays more streamlined. Currently supported are all of the modules included in the Wio Link Deluxe Kit Plus, all Generic inputs and outputs provided by the Wio board, and many more. Contributions and improvements are welcomed.

Node-RED Wio Nodes

Install

$ npm install node-red-contrib-wio-seeed

Configuration

All of the nodes included in this package require the access token provided when logging into Seeed's IOT API. The token can be obtained by logging in with your email and password or entered manually when adding the config node.

Once the config node is added or updated in the Connections section of the node then select the desired Node from the list. Once a Node is selected the correct Port should be automatically selected, if there is more than one compatible module configured you can use the drop down to select the correct Port identifier and Module name. Lastly select any additional options and select Ok. .. That's it! You should now be able to easily interact with your Wio using Node-RED.

Instructions on how to obtain a token manually can be found in Seeed's IoT API docs at: http://seeed-studio.github.io/Wio_Link/#user-login

Nodes

wio-digit

This node provides the ability to set single or multiple characters on the display using the payload value.

NameModuleMethod
Grove 4 DigitGrove4Digitdisplay_digits
display_one_digit

wio-display

This node provides the ability to set strings and values on the display using the payload value.

NameModuleMethod
Grove LCD RGB BacklightGroveLCDRGBstring
Grove OLED 128x64GroveOLED12864string

wio-event

This node contains many Wio events and an option for returning the full JSON response or switched input for the parsed output.

NameModuleParsed ValueDescription
Generic Digital InputGenericDIninput_changedInput Changed
Grove ButtonGroveButtonbutton_pressedButton Pressed
Grove Infrared ReceiverGroveIRRecvir_recv_data_lenData Length
ir_recv_data_hexData Hex
Grove PIR MotionGrovePIRMotionir_movedPIR Motion
Grove Magnetic SwitchGroveMagneticSwitchmag_approachApproach
Grove IR Distance InterrupterGroveIRDistanceInterrupterir_approachedIR Approached

wio-output

This node provides the ability to drive modules with a boolean state such as a relay manually to the desired state or automatically using the payload value.

NameModuleMethod
Generic Digital OutputGenericDOutonoff
Grove ElectromagnetGroveElecMagnetonoff
Grove RelayGroveRelayonoff
Grove SPDT RelayGroveSPDTRelay30Aonoff
Grove Dry Reed RelayGroveDryReedRelayonoff

wio-pwm

This node provides the ability to set the duty and frequency for a PWM signal manually or automatically using the payload value.

NameModuleMethod
Generic PWM OutputGenericPWMOutpwm
pwm_with_freq

wio-sensor

This node contains many Wio sensors and an option for returning the full JSON response or the parsed sensor output.

NameModuleMethodParsed Value
Generic Digital InputGenericDIninputinput
Generic Digital OutputGenericDOutonoff_statusonoff
Generic PWM OutputGenericPWMOutpwm
Generic Analog InputGenericAInanaloganalog
Grove ButtonGroveButtonpressedpressed
Grove MoistureGroveMoisturemoisturemoisture
Grove Ultrasonic RangerGroveUltraRangerrange_in_inchrange_inch
range_in_cmrange_cm
Grove TemperatureGroveTemptemptemperature
Grove Infrared ReceiverGroveIRRecvprotocol_parameters
last_data_recvedlast_data_recved
Grove Temperature & Humidity ProGroveTempHumProtemperaturecelsius_degree
temperature_ffahrenheit_degree
humidityhumidity
Grove Temperature & HumidityGroveTempHumtemperaturecelsius_degree
temperature_ffahrenheit_degree
humidityhumidity
Grove PIR MotionGrovePIRMotionapproachapproach
Grove Digital LightGroveDigitalLightluxlux
Grove 3-Axis Digital CompassGroveCompasscompass_headingheading_deg
Grove Magnetic SwitchGroveMagneticSwitchapproachmag_approach
Grove 3-Axis Digital AccelerometerGroveAccMMA7660shakedshaked
Grove IR Distance InterrupterGroveIRDistanceInterrupterapproachapproach
Grove ElectromagnetGroveElecMagnetonoff_statusonoff
Grove Air QualityGroveAirqualityqualityquality
Grove GestureGroveGesturemotionmotion
Grove Barometer BMP28GroveBaroBMP280temperaturetemperature
altitudealtitude
pressurepressure
Grove RelayGroveRelayonoff_statusonoff
Grove SPDT RelayGroveSPDTRelay30Aonoff_statusonoff
Grove Dry Reed RelayGroveDryReedRelayonoff_statusonoff
Grove ServoGroveServoangledegree

wio-servo

This node provides the ability to drive a servo to the desired angle over a duration manually or automatically using the payload value.

NameModuleMethod
Grove ServoGroveServoangle_motion_in_seconds

wio-speaker

This node provides the ability to output, start, or stop a sound on the speaker manually or automatically using the payload value.

NameModuleMethod
Grove SpeakerGroveSpeakersound_ms
sound_start
sound_stop

wio-ws2812

This node provides the ability to set single or multiple LED's to the specified colors manually or automatically using the payload value.

NameModuleMethod
Grove LED WS2812GroveLedWs2812segment

Todo

  • Refactor the wio-common functions into a more robust and reusable class.
  • Move the admin interface functions into a service provided by the wio-config node to unify the usage of $.getJSON and https.request.
  • Update the wio-config node to utilize Node-RED credential storage for the username and password and perform the request for a new access token dynamically.

Known Issues and Limitations

  • Although the option is provided to set a different server I have not yet tested this using a private Wio server, although this is planned in the near future.
  • Sometimes it may be necessary to re-open the configuration dialog when Nodes or Ports fail to appear and should be fixed as part of the TODO's above.
0.1.7

8 years ago

0.1.6

8 years ago

0.1.5

8 years ago

0.1.4

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago