Small RPI compatible camera gimbal


The video above demonstrates a small custom Sony IMX415 CSI/MIPI camera (a bit like this) mounted in an CADDX camera gimbal and directly connected to an RPI CM4 running Rpanion which allows the camera to be used for live streaming to the GCS, taking pictures and recording video. In the above video Wifi is used but it could have been LTE just as easily.

As far as I know this is the smallest brushless gimbal-mounted camera that can be directly connected to an RPI companion computer (please tell me if I’m wrong!).

The hardware setup is shown on my development copter below (sorry for the messy wiring) but in short the camera, like all other cameras that fit within a CADDX GM3 or XFRobot C20-T camera gimbal, has a Hirose DF56 connector but instead of these pins providing analog or digital video, they provide CSI/MIPI. Then there is a small adapter board that maps the Hirose pins back to the standard RPI ribbon cable, which can then be connected to the RPI CM4/CM5 (in this case mounted on an OchinV2 Carrier Board). With a modified RPI custom carrier board it should be possible to remove the need for the adapter board.

In case you’re wondering why I’ve done this, it is part of my Aerial photography copter, which requires a small camera gimbal that supports:

  • Real-time video over Herelink or LTE
  • Records in 4K
  • Picture and video uploads to the cloud

The first prototype shown at last year’s dev conference used the XF Robot Z-1 mini which was fine but it did not give us full control of the camera’s image quality and frame rate, which is important for getting the best quality live video over LTE

A Taiwanese company developed the camera for me and I suspect they will sell them directly eventually but in any case I will also sell them through JapanDrones. This is not a promotional post to increase sales – I’ve primarily done this for my aerial photography copter but I’m happy to make them available to those who would like them. It may also work with an Nvidia companion computer but I haven’t tested that yet.

BTW, if you are interested in the camera, here’s the Hirose DF56 to Ribbon Cable to RPI pin mapping. I’m also planning on having a Sony IMX 477 version made which should have better image quality.

DF56 Pin DF56 Desc Ribbon Pin # Ribbon Desc CM4/CM5 Desc CM4/CM5 Pin # Notes
1 5V — 5V — — Not used
2 3.3V 22 3V3 3V3 84/86 RPI 3.3V output
3 5V — 5V — — Not used
4 3.3V 22 3V3 3V3 84/86
5 5V — 5V — — Not used
6 3.3V 22 3V3 3V3 84/86
7 USB_DM — — — — Not used
8 NC — — — —
9 USB_DP — — — — Not used
10 NC — — — —
11 NC — — — —
12 I2C_SDA1 21 SDA SDA0 82 Camera I2C
13 I2C_SCL1 20 SCL SCL0 80 Camera I2C
14 MCLK1 — — — — Not used
15 MIPI_D3P 15 CAM_DP3 CAM1_D3_P 141 Diff pair 3
16 REST1 — — — — Reset (not used)
17 MIPI_D3N 14 CAM_DN3 CAM1_D3_N 139 Diff pair 3
18 PWDN1 17 CAM_IO0 Camera_GPIO 97 Power On/Off
19 MIPI_D2P 12 CAM_DP2 CAM1_D2_P 135 Diff pair 2
20 MIPI_D1P 6 CAM_DP1 CAM1_D1_P 123 Diff pair 1
21 MIPI_D2N 11 CAM_DN2 CAM1_D2_N 133 Diff pair 2
22 MIPI_D1N 5 CAM_DN1 CAM1_D1_N 121 Diff pair 1
23 MIPI_CKP 9 CAM_CP CAM1_C_P 129 Clock pair
24 MIPI_D0P 3 CAM_DP0 CAM1_D0_P 117 Diff pair 0
25 MIPI_CKN 8 CAM_CN CAM1_C_N 127 Clock pair
26 MIPI_D0N 2 CAM_DN0 CAM1_D0_N 115 Diff pair 0
27 GND 1,4,7,10,13,16,19 GND GND —
28 GND 1,4,7,10,13,16,19 GND GND —
29 GND 1,4,7,10,13,16,19 GND GND —
30 GND 1,4,7,10,13,16,19 GND GND —
31 GND 1,4,7,10,13,16,19 GND GND —
3 Likes

nice work !

At that point, any small ip camera will do the job and prevent to carry an RPI+CSI cable which are very fragile. I guess it depends what the camera spec you need.

2 Likes

Hi @khancyr,

Thanks! Ah yes, this reminds me that I forgot to mention that I’m planning to have a Sony IMX477 version created as well which should provide slightly better image quality than the IMX415 in the current camera.

The IP camera is an interesting idea but I’m not aware of any small enough to fit within a brushless camera gimbal.

There are those kind of camera poe ip that should fit probably (I haven’t check)

It looks to have a fairly big SoC board.

I would consider OpenIPC boards, while they use an extension wire (I guess MIPI/CSI) it is supposed to be standardized with the onboard Arm SOC it should be possible to connect one to an LTE modem (likely by replacing included WiFi one.

1 Like

Hi @khancyr, @LupusTheCanine,

Thanks for the comments and links!

The linked camera poe ip is much larger at 53mm x 45mm compared to mine which is only 19mm x 19mm. The IP camera alone is almost the same size as the whole package I’m using including the gimbal.

For the OpenIPC boards, from a quick search this is the closest but it uses a standard ribbon cable that can’t easily be threaded through a 3-axis gimbal.
image

The XFRobot C20-T (or CADDX GM3) is only 46g and the camera is only 10g so 56g total. Its dimensions are 46.8mm x 46.4mm x 53.4mm.

It’s still unclear but I think this is more evidence that what I’ve demonstrated is the smallest brushless gimbal-mounted camera that is compatible with an RPI (and perhaps NVidia) companion computer. It’s not perfect but technically I think it’s the smallest. I’d love to be wrong of course.

Thanks!

2 Likes

haa, yes with the dimension … you build is indeed smaller ! From the picture, I was seeing bigger. Anyways that is great to have multiple choice !

1 Like


This one has 14mm camera, the board is 30x30 and comes with a WiFi module soldered directly to the USB port but replacing it with LTE one should be possible if there are drivers.

1 Like

Hi @LupusTheCanine,

Thanks for that. It looks OK.. but of course the camera is not mounted on a brushless gimbal right? With or without a gimbal is a large difference I think.

I wish I had gimbal this small, IIRC it would have to weigh less than 15g to meet my takeoff weight goal :sweat_smile: of 250g. My point was that the camera has a gimbal compatible cable.

1 Like

I use a Rpi camera for my 4G/5G setups, but I found that the ribbon cable to the camera was a bit too stiff for gimbals and making some sharp bends. I 3-D printed a small block that has a groove for the cable and a very narrow slot for an X-Acto blade in the precise location that allows me to slice the cable between traces. It is adjustable so I can quickly slice a ribbon into 2 or 3 segments which makes it much more flexible. I don’t cut the connectors at the end, just the ribbon cable between the ends.

2 Likes

Just received package with… GM3 V2.

For me this is an upgrade as it has no piece at the back obstructing view when looking “back”.

Not sure if there are any firmware differences (there is separate firmware file for v2 gimbal), but will test that soon :slight_smile:

I saw one project that might be a little smaller than caddx, but 2 axis only, no YAW. Not also sure if that is available to actually buy: Tech Talk: Snap's Micro Gimbal - Vantage Robotics

3 Likes

Sadly, they don’t appear to sell their gimbals :pensive_face:.

@Adam_Borowski, @LupusTheCanine,

BTW, Leonard and I (and others) are interested in writing open source brushless gimbal software but we’re always get stuck because we don’t have the hardware. If you (or anyone reading this) bump into a friendly manufacturer that would be interested in having us write their gimbal software please ask them to PM me!

We just need one upstart camera gimbal manufacturer to give us the chance.

4 Likes

On my small gimbal, I’m using a USB camera (actually 2, one RGB and one themal cam).
Maybe that’s another option to consider? Easier than CSI, and easier sourced than ethernet in small form factor.

I definitely need to find some time to finish the hardware, but on the electronic side I was planing on using storm32. Depending on what you’re looking for, maybe something could be done together?

1 Like

Hi @ncx94,

Thanks for the suggestion, I had not thought of USB and you’re right that there are some small options out there like this IMX179 from aliexpress. It has lower image quality than the IMX477 that I’m using but it’s still interesting.

Re hardware, the storm32 is a good starting point because the hardware is open source (see here) designed using EAGLE (see Sparkfun guide here) so we can change it. Eagle itself is getting replaced by Autodesk so in practice something like KiCad would be better to use.

For the plastic part of the gimbal, I’ve been thinking about trying to start an open source 3D design similar to the XFRobot C20-T designed using AutoDesk fusion.

Anyway, I’m happy to work with you and others on this!

1 Like

Very cool to find someone working on a small camera gimbal with raw output for a companion computer! So far I’ve come up with these ideas:

  1. SIYI A8 Mini HDMI + HDMI-MIPI adapter
  • bulkier at 100g+ with the adapter
  • will still need to check the HDMI latency
  1. XF C40T + Pi Camera
  • there is still the problem of ribbon routing
  • camera board still seems big enough to limit motion range
  1. XF C20T + IMX179 based usb camera
  • quality is not the greatest as you said
  1. XF C20T + chinese OpenIPC camera
  • 19mm stacked camera + SOC that fits the gimbal: SSC338Q + IMX415 or SSC30KQ + IMX335
  • it has USB connection
  • will need custom firmware to implement UVC output since OpenIPC doesn’t support it
  • USB 2.0 limits video bitrate, will have to choose between low-res raw or hi-res compressed stream
  • example 1, example 2

I would be interested in your camera and ribbon adapter @rmackay9.

Also, @charles_linquist, could you please share what gimbal you are using with the Pi camera?

Hi @mihaits,

The same taiwanese company is working on an IMX477 version of the camera that I hope to sell on my little company’s website (https://japandrones.com/) in the near-ish future. That will include the camera cable adapter board so that it can be plugged into an RPI. I’ll post again when it’s up on the website but it’ll still be a few weeks at least.

Re using the a8, it’s possible to pull the video onto the companion computer using ethernet. I think that would likely work better than the HDMI-MIPI adapter. That’s how the BlueOS high-altitude optical flow extension works – it takes the latest image from the camera using ethernet.

2 Likes

hi @rmackay9 ,

Yeah there are some nice usb options, I have a couple I bought from a chinese supplier that are amazingly small and lightweight.

Arducam (and probably others) also sells a CSI to UVC/USB adapter for the 477

Yep, that’s what I thought was interesting on storm32, and that I could then implement it even more in the custom machine I’m building.
Of course, for such an opensource project Kicad is the way to go!

Nice about the plastic parts! The hardest part of any small gimbal are the motors though. Sourcing very small gimbal motors is quite challenging in small batches..

2 Likes