I have a program that was working fine on 1.20 original. It was driving two motors using a dual motor controller that uses PWM to set speed.
Works under Original 1.20. No changes to hardware, or code, nothing happens on when using 1.20-117 on either Pico or Pico-W.
I've reported it on the micropython board (https://github.com/orgs/micropython/discussions).
Just wanted to give everyone a heads up.
Gregwa
Re: PWM does not work on any recent nightly build but does on original 1.20
I got a response from the Micropython group this morning.
I appears that versions of Micropython previous to the new nightly builds (including 1.20 original) did not require a frequency during the init or anywhere else.
Now it does. This allows the RP2 port to be consistent with other ports.
So, if you are having issues with ppm, when you declare the PWM pins include a freq=XXXXX parameter.
I haven't given it anything other than a quick check, but it does seem to fix the problems.
Gregwa
I appears that versions of Micropython previous to the new nightly builds (including 1.20 original) did not require a frequency during the init or anywhere else.
Now it does. This allows the RP2 port to be consistent with other ports.
So, if you are having issues with ppm, when you declare the PWM pins include a freq=XXXXX parameter.
Code: Select all
self.M1A = machine.PWM(machine.Pin(M1A),freq=1000)
Gregwa