sarfata / pi-blaster.js

NodeJS module to control pi-blaster
MIT License
107 stars 27 forks source link

Multiple accurate PWM signals simultaneously? #12

Open shtaif opened 8 years ago

shtaif commented 8 years ago

Hi :)

I'm developing a Raspberry Pi Node.js quadcopter.

Will the pi-blaster and it's Node.js binding allow me to produce 4 different, maximally accurate, hardware PWM signals at the same time, over any of the Pi's GPIO pins?

Thanks man :)

sarfata commented 8 years ago

Yes that should work. Try it and let us know how it goes!

The biggest problem I think might be when you are updating the values. It's pretty hard to change PWM "smoothly".

shtaif commented 8 years ago

Well, I've still got a little time ahead before I get into that stage, but will be happy to let you know. Be a lot, lot more happy if it turns out to be the proper solution.

Anyway, this unsmooth-changing issue, is this a side-effect of RPI architecture itself, or from the way pi-blaster is implemented?

robinp7720 commented 7 years ago

@shtaif any progress on this? I started to build my own raspberry pi powered quadcopter without using an external flight controller and would like to explore existing options before taking the plunge into the technical things.

shtaif commented 7 years ago

@robinp7720 just have note that I eventually I switched to pigpio because it doesn't depend on a separate deamon. I'm not full time into this but I did manage to make my quad auto align itself along the magnetic north on the Z axis. Though I'm still working on the algorithms over there (trying to make them the "PID" way), gotta say these Z axis experiments looked quite promising and reliable.

I'm definitely planning to fully implement it without any separate controller hardware. I don't know about how these to methods will compare to each other but nevertheless I have ground to believe that it is possible without an "external flight controller".

Hope I helped.