jenswilly.dk


Archive for June, 2015

Pixhawk-CHDK trigger progress

10. June 2015 11:07 by Jens Willy Johannsen
Categories: Drones | PCB | Projects

The Pixhawk-CHDK trigger is coming along nicely. The prototype is done and the firmware is almost done.

The firmware is actually very simple. I'm using 32 bit timers for both measuring incoming RC PWM signal for for outputting 5 V pulses of specific lengths and all the USB CDC functionality is copied-and-pasted from a previous project. The most complex part is actually for command-line interface (or "CLI") parser.

To configure the device you plug into your computer using a mini-USB cable and then connect using Telnet, screen or other terminal application.

The command set is pretty simple and supports the following commands:

list                    -- shows all defined intervals
add 1000,1200,85        -- adds a new interval
delete 1                -- removes entry 1
change 1=1000,1300,85   -- changes entry 1
pulse 50                -- sends an output pulse of 50 ms
show                    -- shows all settings parameters
show <setting>          -- shows the value of a single parameter
set <settings>=<value>  -- changes the specified settings parameter
help                    -- shows available commands
?                       -- same as "help"

No need to "save" or similar. Everything is stored in EEPROM as soon as it is entered.

PCB

The PCB design is also almost done. I just need to check it a couple of times (time well spent, trust me) and verify footprints (likewise time well spent). The size is 5 x 2 cm and even though I probably could squeeze it down some more, I think I'll keep the current size seeing as how I'll be hand-soldering some of the parts and applying solder paste and components all by hand.

Here's a rendering (from the excellent 3D Gerber Viewer from Mayhew Labs:

Pixhawk-CHDK PCB. 5 x 2 cm.

Pixhawk-CHDK PCB. 5 x 2 cm.

No comments No comments »

CHDK trigger for Pixhawk and IRIS+

5. June 2015 9:56 by Jens Willy Johannsen
Categories: Drones

I have begun creating a CHDK trigger cable for the Pixhawk autopilot in my IRIS+ drone.

It will allow me to control a Canon compact camera (IXUS 60 in my case since I had one of those laying around) from the autopilot.

CHDK is the Canon Hack Development Kit which will allow you to do a whole lot more with a Canon compact camera than what the basic knobs and dials will let you do. It also allows for scripts to be run on the camera – LUA (nice) and Basic (yuck) – and enables remote control through the USB port.

The purpose of this trigger cable is to convert the 3.3 V RC PWM signals from the Pixhawk (PWM with pulses from approximately 1000 µs to 2000 µs; read more here if you want) to 5 V pulses (from about 10 to a couple of hundred milliseconds) for the camera.

With the trigger cable complete and the camera mounted on the IRIS+, I can trigger shots from either the RC transmitter or by using pre-programmed actions in auto-missions. Those images can later be stiched together in Photoshop or Microsoft ICE or similar to create a nice high-resolution aerial photo.

While I'm sure this project could be implemented using less sophisticated hardware, I'm using an LPC11U24 microprocessor since that is my weapon of choice for pretty much anything.

I'm trying to make the device as small as possible so I will be using a 7 x 7 mm HVQFN package which will require the PCB to be reflow soldered (we've come a long way since all ICs had to be 0.1" DIL packages). I will also be using a 1 mm pitch JST-SH connector for MCU programming instead of big 0.1" pin headers. Both power and signal input as well as output signal will use Molex SL connectors with locking tabs (which I use everywhere else on my IRIS+).

The resulting images will look this one from a thread on DIY Drones ( A successful APM aerial survey mission):

Click to see higher resolution

Click to see higher resolution

No comments No comments »