SECRETS OF THE C328

C328 product page

Finally a UART camera you can multiplex with telemetry. It's a way of getting live preview video without the insane price of 900Mhz video or the bandwidth conflicts of 2.4Ghz video. With 2 Xbees & a computer to control it, it's the cheapest video downlink you're going to get.

For you Xbee fans, the maximum camera packet size is limited by the XBee buffer size to 128 bytes & you have to send an ACK after every packet, thus the XBee latency slows it down by 1/3. Highest performance would take a local microcontroller with full flow control to send the ACKs.It's pure hell to get initialized, but once it starts, it keeps working. Normally just getting it started entails sending init commands, failing, & waiting 10 seconds over & over for several minutes. If it's interrupted in the middle of an image transfer or the serial port glitches, it takes a lot of long waits & init commands to get it to work again.Sleeping around 1/4 second between the snapshot & getpicture commands is required to avoid nasty image corruption, but the JPEG compression is otherwise instantaneous.The lens is really loose, so you'll need to tape it for flight.

Dual radios for autopilot & video.

Ground station for video. Buy a proper XBee breakout board from your sponsors instead of doing this.This is a video of the UART cam in flight. The picture quality is so bad, 160x128 is probably the only resolution you need for preview video.This is a program for getting video off it.video.cNow some benchmarks.JPEG, 128 byte package size, & bare Xbees640x480 (48kb) =15 seconds per frame320x240 (20kb) =7 seconds per frame160x128 (2kb) =1.2 seconds per frameXBees + local microchip generating ACKs640x480=10 seconds per frame320x240=5 seconds per frame160x128=0.7 seconds per frameUSB serial connection & 128 byte packages640x480=11 seconds per frame320x240=5 seconds per frame160x128=1 second per frameUSB serial connection & 512 byte packages640x480=6 seconds per frame320x240=3 seconds per frame160x128=0.7 seconds per frame
E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones

Comments

  • video.tar.bz2

    Updated source code for a dedicated camera controller.
    https://storage.ning.com/topology/rest/1.0/file/get/3689333227?profile=original

  • We have a small circuit for generating ACKs locally & speeding up the image transfer. At 160x128, 1fps it's good enough to aim a higher quality camera.




    pic_video.s

    pic_util.inc

    You're looking at 1 month to get this camera working as a live preview. Instead of 1 camera, now you're running 2. You've got 2 power supplies to route, 2 ground stations, lots of software to write. Captured some more video at different resolutions. 320x240 seems to be the maximum amount of useful information.

  • Right - the C328 outputs sequence of JPEG frames. You actually can set the C328 UART to 921kbps, though this isn't documented. We used the C328 with our first generation SRV-1 robots that had ARM7 processors, before switching over to the Blackfin processor and DMA camera interfaces.

    I have a bunch of these modules (maybe 20 or more) left over from inventory for the ARM7 robots, and would be happy to offer a good price, in case anyone is interested.

    By the way, the C328 uses a standard lens format - 12mm diameter with 0.5mm thread pitch. As such, you can install other lenses and significantly improve the image quality. Check out http://www.mars-cam.com/lenses/ccd_cmos/43fix.html
  • 3D Robotics
    The Sparkfun page only describes its still camera function. Is the video just a stream of jpg frames that you have to decompress in realtime to watch?
  • T3
    Basically, they messed up USART. This should have been 926kbps to be useful.
    Jack, I see you have the world's first wooden IMU?
This reply was deleted.