One more tidbit
http://beagleboard.org/support/BoneScript/analogWrite/
*/Note:/ This function is currently incompatible with pinMode which may
force the pin mux to GPIO mode only. *
On 6/4/2016 10:31 PM, Md Khaled Hossain wrote:
> Here I am trying to turn on a buzzer for one second and then turn it
> off. Here is the code
>
> |
> #!/usr/bin/env node
> varb =require('bonescript');
>
> b.pinMode('P8_19',b.ANALOG_OUTPUT);
>
>
> b.analogWrite('P8_19',0.5,2000.0,printStatus);
>
> functionprintStatus(x){
> console.log('x.value = '+x.value);
> console.log('x.err = '+x.err);
> }
>
> setTimeout(function(){
> b.analogWrite('P8_19',b.low); // Turn off buzzer after
> milliseconds time
> },1000);
> |
>
> This code gives the following error after i try to run it immediately
> after reboot
> error: Error enabling PWM controls: Error: ENOENT, no such file or
> directory '/sys/devices/ocp.3/bs_pwm_
>
> test_P8_19.15/polarity'
>
>
> how to solve the problem?
>
>
> --
> For more options, visit http://beagleboard.org/discuss
> ---
> You received this message because you are subscribed to the Google
> Groups "BeagleBoard" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to [email protected]
> <mailto:[email protected]>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beagleboard/f30ed627-81cf-43af-913c-057e8446ece5%40googlegroups.com
> <https://groups.google.com/d/msgid/beagleboard/f30ed627-81cf-43af-913c-057e8446ece5%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.
--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/beagleboard/7cfb2662-4366-a21a-9365-b58e364de26d%40gmail.com.
For more options, visit https://groups.google.com/d/optout.