gajananvk
Need pWm control on. STM32 black/blue pill boards
if it’s available please suggest how to use
Reply 0 0
thiagoralves
By default OpenPLC generates PWM waves on analog pins. If your board has support for %QW variables, then any variable you assign to %QW will generate a PWM wave on the respective pin. The range is 0-65535, where 0 is 0% duty cycle and 65535 is 100% duty cycle.
Reply 0 0
gajananvk
Thanks for reply!
Can you please tell, what is the frequency of output?
Reply 0 0
gajananvk
Also, I would like to know, how QW0 is linked with Qx0.0. Since I want pWM on QX0.0
Reply 0 0
thiagoralves
You can’t link %QW0 with %QX0.0. %QW is for analogs. %QX is for digital. You need to change your pin mapping if you want to use a different pin on %QW0. Pin mapping can be changed at the upload dialog under I/O Config
Reply 0 0
gajananvk
Thanks Thiago ,
what is the pulse frequency used for PWM of analog output?
Reply 0 0
thiagoralves
OpenPLC uses the default frequency implemented in the Arduino API for the board. In case of the STM32, I believe the default frequency is 1KHz
Reply 0 0
jbe
By default OpenPLC generates PWM waves on analog pins. If your board has support for %QW variables, then any variable you assign to %QW will generate a PWM wave on the respective pin. The range is 0-65535, where 0 is 0% duty cycle and 65535 is 100% duty cycle.
ok but is its working with all micro servo motor ?...i try but not working very well tanks
Reply 0 0
Reply