Cat's Eye 2
Page 2: electronics
The electronics are in some sense quite conventional. There will be channels for the standard flight controls, channels for pan and tilt, a channel for the still camera zoom and shutter release and a channel to switch between the still and video cameras.
The receiver channel breakdown goes as follows (subject to change without notice :)
- Still/video switch
The first 3 are standard r/c flight controls. The other channels will be discussed below. Here's a shot of the test rig. And, in answer to the obvious question, yes, it works. :)
Figure 4: Electronics test rig
As you can see, there are 4 (count 'em, 4) PIC12F629's in this set up! These are 8-pin DIP devices. Three are on the prototyping board (white) and one is on the made-up circuit board resting on the prototyping board (just above centre). The other 8-pin DIP on that board is a solid state relay (see Video section, below).
At the lower right is the XPS 8-channel receiver. A ribbon cable connects it to the prototyping board area, and passes the 8 channel signals and the 5-volt power. Top-right is the battery. At the moment it feeds a 7805 (a standard cheap off-the-shelf 5-volt regulator). The regulator is at the top left of the prototyping board, screwed to an approx 3-inch long piece of aluminum sheet, acting as a heat sink. In the final version, I may replace this with a switch-mode regulator, or use a couple of regulators for different things. For the test, however, all the 5 volt stuff is hanging off this regulator (and yes, it get's a bit warm).
At the upper left is another pre-made circuit board, that I made up for the Long-Nose Getter when I converted it to FPV. An AnyVolt Micro, set at 12 volts, is fed from the battery and boosts or cuts the voltage, as required, to produce the 12 volts for the video transmitter and the video camera. The video transmitter is at the bottom of this board. A home-made half-wave dipole antenna sticks out the left of this board. Below the board is the microphone within a block of foam.
The test pan/tilt test rig is at the bottom left, fed by the many wires.
The descriptions below describe each of the signal paths, by channel from the receiver. Following that is a description of the "ground station" (i.e. the part that stays on the ground by the pilot).
Channels 1 to 3 are the flight control channels, rudder, elevator and throttle.
Channel 4 is the left stick right-left movement on the transmitter. This is normally the rudder, but in the case of a 3-channel plane the rudder is mapped to the right stick's right-left movement (Mode 2). I am mapping channel 4 to the camera mount "pan" movement.
The stick on the transmitter is currently spring-centered. I toyed with the idea of modifying this to "ratchet" in the same manner as the up-down (throttle) movement. To this end, I took the transmitter (a Futaba 9C) apart, but concluded it was not worth messing with the hardware. Instead, this channel will have an "integrator." This will "integrate" the stick movement, so the stick position will determine the camera rotation velocity, rather than its position. That is, push the stick to left to rotate to the left, to the right to rotate right. The further you push the stick off centre, the faster it rotates. Release the stick (let the spring return it to the centre), and the mount stays where it is.
I have set the rotation rate (scale factor) in the firmware, for ease of development. If I find it is too fast or too slow I can re-program the PIC. The other parameters are the extent of travel. Obviously you have to set a limit on how far the servo goes. I have set this up as a configuration routine on the PIC, controlled by a jumper. In this case I limit the movement to 180º -- from full left to full right. The extents are stored in EEPROM on the PIC chip.
To prevent servo jitter, if the servo movement stops for more than 1/2 second, the pulse train is stopped.
Channel 5 is controlled by a "slider" on the side of the transmitter and is used for camera platform "tilt." The slider is not spring-centered (i.e. stays where you put it), so it doesn't need an integrator. However, to prevent "jerkiness" (the servo will respond way faster than you really want in this instance), I am using another PIC here to limit velocity and acceleration, so the camera tilts smoothly regardless how I push the control around. This is the same controller as I'm using for the Cat's Eye 1. As with the channel 4 integrator, if the servo movement stops for more than 1/2 second, the pulse train is stopped.
Channel 6 is used to switch the video feed from the video camera to the "video out" from the still camera. The video camera is wide angle. I'm not sure if I will just use it to maneuver the plane into position for the still shots, or whether I will actually use it to pilot the plane, FPV-style. The still camera has a narrower field of view, has various on-screen displays, and does not respond as fast as the video camera. The video from the still camera will be used to line up shots -- a "high-tech viewfinder". The camera also freezes the shot just obtained for a couple of seconds (programmable), so you can see what you've got and decide if you need to try again.
The composite video signal is something of a mystery to me I will have to admit. I think the brightness signal is the carrier signal, with the colour (chroma) and saturation signals as subcarriers. But I could be wrong. And then there are the sync pulses. And the whole thing is DC-referenced in some way, which I found out when I put a capacitor in the circuit and totally fouled up the picture.
So, rather than spend a lot of time trying to figure it all out, I decided to take the easy way out and just use switches. No messing with signal levels, DC levels, worrying about bandwidth or any of that other stuff. The switch is either on or off. In this case I'm using an XAA170 solid state relay, which has full isolation between the switched circuit and the driving circuit. The PIC just drives one of the solid state switches "on" and the other "off" to select the video signal. Simple, and works like a charm.
Channel 7 is the still camera shutter control, yet another PIC (already developed). It drives an Infrared LED which the camera uses for "remote control" of the shutter and zoom function. I haven't decided whether to implement the "zoom" function at this point or not. If I do, it's a simple change.
Finally, we come to the "Ground Station", i.e. the part of the rig that stays on the ground with the pilot. This consists of the electronics to receive the video signal, display it, and record it for later analysis (or postmortem as might be the case).
Figure 5: Ground Station
At the right we have another 3S LiPo battery. Unlike the plane power supply, I am not going to bother regulating the voltage. The maximum voltage, 12.6V is well within the 10% tolerance specified for the receiver. The power drawn from the ground station is small compared to the plane's on-board requirements (mainly the motor), so as long as I check the voltage between flights (note to self: add this to the checklist!), and top up if required, I should be OK. I have a few old LiPos floating around that seem to have developed a partially dead cell or high internal resistance. I would not trust them on a plane, but they should work fine in this application, which requires much less current and no heavy peaks.
Next is the video receiver itself. I have a "patch" antenna that I will be using, not the little wire antenna shown, but that antenna works fine for bench testing.
Next is the video recorder. This is a cute little device that uses a 2.5" laptop hard drive to record the video as AVI files. I happened to have a 14 gig hard drive floating around which works perfectly. It also has the advantage of not using as much power as a modern laptop hard drive. The whole thing takes about an amp and 5V. And speaking of power, for testing I just used the wall wart that came with it. In the field, however, I plan to use a ParkBEC or other type of 5V switch-mode regulator. I used a ParkBEC when I was testing the FPV Getter, and it worked fine.
Finally, at the left we have a 7" portable TV. It has an internal battery specified to last 2.5 hours. Shown here is an actual feed from the test setup (just to prove it works!), showing the output from the still camera. Note the date/time, number of shots, battery indicator and other displays.
Continue to: Page 3 - Airframe