- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The JavaScript sample on this page requires two corrections to work: https://software.intel.com/en-us/iot/hardware/sensors/grove-rotary-angle-sensor
//Load mraa module var mraa = require("mraa"); //Instantiate Aio on Pin #0. var rotarySensor = new mraa.Aio(0); //Read sensor data function readRotaryValue(){Console.log("Rotary Value: " + rotarySensor.read()); //should be console.log }set Interval(readRotaryValue, 1000); //should be setInterval
Change to:
//Load mraa module var mraa = require("mraa"); //Instantiate Aio on Pin #0. var rotarySensor = new mraa.Aio(0); //Read sensor data function readRotaryValue(){ console.log("Rotary Value: " + rotarySensor.read()); } setInterval(readRotaryValue, 1000);
- Tags:
- Internet of Things
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you. we will get this correct.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It's been fixed. Thanks for pointing it out Marvin.
Joe

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page