Hi Leonard,

Wich drive are you using?
I try with python adafruit and did not work.
i can blink with gpio but pwm never work.
i use ubuntu precise, bbb,

root@ubuntu-armhf:/home/ubuntu# echo 51 > /sys/class/gpio/export
root@ubuntu-armhf:/home/ubuntu# echo "out" >
/sys/class/gpio/gpio51/direction
/direction  root@ubuntu-armhf:/home/ubuntu# echo "low" >
/sys/class/gpio/gpio51/direction

but can i use the same step with pwm?

root@ubuntu-armhf:/home/ubuntu# ls /sys/class/pwm
export  pwmchip0  pwmchip2  pwmchip3  pwmchip5  pwmchip7  unexport
root@ubuntu-armhf:/home/ubuntu# ls /sys/class/pwm/pwmchip0
base  device  npwm  power  subsystem  uevent

I try

echo am33xx_pwm     > /sys/devices/bone_capemgr.9/slots;

echo bone_pwm_P8_19 > /sys/devices/bone_capemgr.9/slots; # EHRPWM2A
echo bone_pwm_P8_13 > /sys/devices/bone_capemgr.9/slots; # EHRPWM2B
echo bone_pwm_P9_14 > /sys/devices/bone_capemgr.9/slots; # EHRPWM1A
echo bone_pwm_P9_16 > /sys/devices/bone_capemgr.9/slots; # EHRPWM1B

but i get.

root@ubuntu-armhf:/home/ubuntu# ls /sys/devices/ocp.2/pwm_test_*
/sys/devices/ocp.2/pwm_test_P8_13.31:
modalias  power  subsystem  uevent

/sys/devices/ocp.2/pwm_test_P8_19.30:
modalias  power  subsystem  uevent

/sys/devices/ocp.2/pwm_test_P9_14.32:
modalias  power  subsystem  uevent

/sys/devices/ocp.2/pwm_test_P9_16.33:
modalias  power  subsystem  uevent







2013/10/2 Tux Leonard <[email protected]>

> You can use a PWM output to drive your servo. Set the PWM cycle frequency
> to 50hz and the duty cycle to 1.5 ms (~7% = center position). Varying the
> duty cycle +/- 0.5ms should drive your servo to left and right.
> Power the servo by an external power source not the GPIOs of the board.
> Am 02.10.2013 15:43 schrieb "서재필" <[email protected]>:
>
> Hello, BB group~
>>
>> I'm figuring out how to control Servo motor by angle information with my
>> BB.
>>
>> I made a tracking sound c++ code and this code get some angle(degree)
>> information. And finally i got it with my BB.
>>
>> The next step is controlling Servo motor by this angle information.
>>
>> So I'm thinking of 2 methods.
>>
>> First one is using Arduino(send angle information to Arduino from BB),
>> and Second one is BB directly controls a Servo motor.
>>
>> But I don't know how to use gpio in BB and I wonder 2 methods I
>> thought are possible to implement coding by just using c++ in Angstrom
>> linux.
>>
>> Please give me any comments.
>>
>> It will be great help for me.
>>
>> Thanks.
>>
>>
>>
>> --
>> 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].
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>  --
> 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].
> For more options, visit https://groups.google.com/groups/opt_out.
>



-- 
Marcus de Vasconcelos Diogo da Silva

"Uma montanha até um cego consegue desviar,mas é nas pedras menores que nós
muitas vezes tropeçamos e caimos!"

-- 
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].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to