Use Raspberry Pi as CC3D controller
« on: October 27, 2018, 06:09:36 pm »
I want to use my raspberry pi as the controller for cc3d with librepilot in my quadcoptor. I found out that simple serial connection can be used between raspberry pi and cc3d. However, I wasn't able to understand what values would I have to send over serial to control the drone. Do we have to like serial.write integer values or something? I know that my question might already be answered but I am a noob and would appreciate if anyone can point me in the right direction. Thanks in advance.

Re: Use Raspberry Pi as CC3D controller
« Reply #1 on: October 31, 2018, 04:03:25 am »
@f5soh can probably help more than me, but here are some guidelines.  If you can get the RPi to send PWM or PPM (or other) signal to the CC3D, then the CC3D will think it is connected to a normal RC receiver.  This is an easy way to understand, but it may be difficult to get RPi to send these signals without jitter.  Needs a system level driver, not bit banging, probably PPM.  Flying in Attitude mode this could command bank angle and throttle.  RPi would probably need a GPS, etc.

There are ways that the GCS can control the CC3D through telemetry; you can have the RPi send telemetry packets to the CC3D.  Figuring out these packets is difficult.  I don't know exactly what to do and it would take a while to figure it out.

There is a way to write Python code (maybe something besides Python, I forget without digging) and have it run in Revo.  I don't think this is available in CC3D though.  You could send serial data that is read by your code and have it do some calls that are similar to the previously mentioned telemetry, but are more packaged and easier to do?