- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
On Intel XDK IOT edition,
I tried:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
mypwm.enable(true);
mypwm.period_us(2000);
mypwm.write(0.5)//half the value
This works fine. But when I bring in another pwm value:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
var mypwm2=mraa.pwm(10,-1,false);
This causes an error. I tried building it, uploading it, all sorts of things. Is there a way where I can have multiple PWM outputs without bringing up an error?
- Tags:
- Internet of Things
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Kirtan S. wrote:
On Intel XDK IOT edition,
I tried:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
mypwm.enable(true);
mypwm.period_us(2000);
mypwm.write(0.5)//half the value
This works fine. But when I bring in another pwm value:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
var mypwm2=mraa.pwm(10,-1,false);
This causes an error. I tried building it, uploading it, all sorts of things. Is there a way where I can have multiple PWM outputs without bringing up an error?
I checked: Mraa doesn’t support PWM on IO10, Only the default “swizzler” states. Libmraa wouldn't know if you modify those hence has to assume the defaults
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
could you pls check which version of libmraa you have installed?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Kirtan S. wrote:
On Intel XDK IOT edition,
I tried:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
mypwm.enable(true);
mypwm.period_us(2000);
mypwm.write(0.5)//half the value
This works fine. But when I bring in another pwm value:
var mraa=require("mraa");
var mypwm=mraa.pwm(9,-1,false);
var mypwm2=mraa.pwm(10,-1,false);
This causes an error. I tried building it, uploading it, all sorts of things. Is there a way where I can have multiple PWM outputs without bringing up an error?
I checked: Mraa doesn’t support PWM on IO10, Only the default “swizzler” states. Libmraa wouldn't know if you modify those hence has to assume the defaults

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