Back Home Next



  1. What is the difference between 4016 and 74LS00 ?
  2. How can I find the right IC - there are too many names...
  3. Where to solder the resistors?
  4. Where are +5 V and Ground?
  5. What is the better MOD, with 7400 or with 4116 ?
  6. Is there a 'Lift Pin' Mod for QC Pro3000 ?
  7. How to check a non working Mod?
  8. What is the RAW mode ?
  9. Where is RAW mode applied ?
  10. How can RAW be achieved ?
  11. What does happen when I RAW mod my camera ?
  12. How can I get the color image back from this weird looking color RAW image ?
  13. What about MAC users ?
  14. Computer Connections - which is which ?
  15. Issues when connecting two web cams to a computer

Copyright 2004 - 2006 Martin Burri

What is the difference between 4016 and 74LS00 ?

The 7400 IC in all its variations is a logic component, with 4 NAND (not-and) gates. Logic components have a defined output depending on its input.

The 4016 or 4066 (same function and pinout but different specs) however is a CMOS IC consisting of 4 so called bi-polar switches which do let the current run through when the switch (control pin) is held at a high voltage level otherwise the switch is open and no current flows - you may just think of a regular switch which does not use manual operation.

Back to contents

How can I find the right IC - there are too many names...

The naming of the components reflects the type, made and manufacturer of an IC e.g. 74LS00 is a low power IC etc. the 4016 for example can be bought as MC14016 from Motorola.

Your dealer may check a comparison table right IC.

Back to contents

Where to solder the resistors?

The best point to solder the resistors is at the IC socket of the 4016 as it can be done before fiddling with the cam you just have to make sure that no shortcuts are left before connecting the cam.

Back to contents

Where are +5 V and Ground?

The red lines are wires from the pins of the cam board to the 4016 IC and the resistors are always from the connection to +5V which is the red wire of the USB connector. 

The ground (e.g. pin 7 of the 4016) can be found by following the black wire of the USB connector. The best point for soldering is at the base of the connector where it is soldered to the cam board actually on the CCD side of the board.

Back to contents

What is the better MOD, with 7400 or with 4116 ?

Whether you use logic components (7400) or switches (4016) to do an SC mod does not matter in the end. Both circuits will disable the CCD readout for a while to allow the photons to fill the CCD wells which are then, when reading out is enabled again, translated into current and at the very end into a nice picture.

The mod's use either the logic (74HCT00) OR the switches (4016) but as far as I know not both. So if you choose the 4016 mod which I used you don't have to bother with 74HCT00 and vicaversa.

Back to contents

Is there a 'Lift Pin' Mod for QC Pro3000 ?

There is and some have performed it successfully. 

For the 'Shutter Line' there is already suggested to lift Pin 4 of the CDX1267AN chip. For the 'V-Gate' connection one can lift pin 9 AND 7 on the same chip connect the two and wire it to the 4066 IC.

Again, take in mind that if you have lifted pin 9 you have also to lift pin 7 and connect the two together and put the 4066 switch between the SAA pin and the two connected CXD pins, otherwise you have only a partial mod for even (or odd) lines which is not what you expect.

Reason is that on the CCD there are two vertical readout lines - one for the even and one for the odd lines.

Back to contents

How to check a non working Mod?

If your Mod is not working you may first go over the tiny solder spots and check whether they are properly connected and not bridging to other connections etc. 

Think about the connections to the 4066 IC - did you made all connections to the proper Pins ?

All ICs are numbered as follows: 

View it from top i.e. pins go down like a regular bug it only does not crawl around. Then lookout for the notch on one of the long side ends. Put the notch to North (12'o clock).
Pin 1 is now the top left one and counting is counter clock wise i.e. pin 14 is top right.

Review the wiring on the parallel port, make sure Pin 2 is really Pin 2 ;-) 

If you feel that everything should be OK you may proceed the following way to check your Mod:

Take the cam and connect it as the only camera to your computer via USB but DON'T connect the Parallel Port plug but remove the housing of this plug to get access to the wires there.

Get the circuit diagram of your mod at hand (here is mine)

Step 1: (regular cam mode check) 
Open a capture program - select the camera and use the 'Format dialog to make it stream at 5 fps with 640x480 resolution open the 'Source' dialog to be able to modify some of the camera control sliders and see if the image is visible - may be you have to turn some of the sliders to make it visible.

--> Is an undistorted image like before modding the cam visible ? Fine, proceed with Step 2

--> Not OK - well there must be an issue with the basic wiring to the 4066 chip or the IC is dead - you may go to Step 1a for this.

Step 1a: (regular cam mode check, 4066 removed) 
Disconnect the camera from USB and remove the 4066 from its socket if not wired directly and put a small wire between the socket connections where usually the IC sits i.e. from 1 to 2, 3 to 4 (again referring to my diagram). Now it should behave like a regular cam - connect it to USB and check like mentioned above.

--> Is an undistorted image like before modding the cam visible ? Fine, seems that the control lines to the 4066 are the issue (i.e. the ones that lead to pin 5 and 13 in my diagram). Check these lines and resistors for proper values and connections. Go back to Step 1 then. 
If you are landing here again here the 4066 should be replaced for further checking - restart at
Step 1.

--> Not OK - The issue with the wiring from the camera pins to the 4066 chip - nothing but to check it again and come back to this step until it works. 

Step 2: (shutter line check)
Open the Parallel Plug housing and connect the 'Shutter Line' (Pin 5 in my diagram) with Ground (Pin 21). This disables the electronic shutter.
If you move now the 'Exposure Slider' on the camera controls i.e. the one which is marked with the exposure time there should be no change in the images brightness anymore.

--> No change in brightness ? Fine, proceed with Step 3

--> Still changes in brightness - The issue is along the Pin 5 of the parallel port up to where it connects to the 4066 IC - check wires and connections and try again.

Step 3: (V-Gate line check)
Now with the Shutter line still tied to Ground (Step 2) connect the V-Gate line (Pin 2 in my diagram) manually with Ground for a while (some seconds). If you disconnect it, a bright image (like a flash) must be visible. Try this several times if you are unsure about the effect.

--> Got kind of a white flash when releasing the V-Gate ? Fine, proceed with Step 4

--> Got no kind of flash -  The issue is along the Pin 2 of the parallel port up to where it connects to the 4066 IC - check wires and connections and try again.

Step 4: (capture program preview check)
If you are here the basic hardware modification should be working. You have now to use a LE capture program for further investigations. Remove all the shortages introduced in Step 2 and 3 and connect the Parallel Plug to the computer. Open the LE Setup Dialog of your capture program and check if the settings are according to your modification i.e. the port address of the proper LPT (Usually 1 but who knows?) and the lines for the different functions. If you've done all according i.e. my wiring diagram the default settings of almost all capture programs such as K3CCDtools should be OK. 
Again try to get a preview image without any LE usage. Open the camera controls and try to make it visible.

--> Is an undistorted image like before modding the cam visible ? Fine, proceed with Step 5

--> Not OK - On some computers and Operating Systems (i.e. XP or 2k) one has to put the Parallel Port into basic mode in the BIOS (the setup of the computers basic hardware) check the manual for this topic - look out for the Parallel Port mode and make sure it does not read EPP and/or ECP. Now reboot and check Step 4 again.

Step 5: (capture program LE check)
If you are here it really should be working, on some computers one has to try with the LE setup delay times.

Hope you could resolve the issues and have a working modded cam now !!!

Back to contents

What is the RAW mode ?

In a nutshell for RAW mode one disables the internal de-bayer algorithm and rescales the internal amplifiers to reveal the best possible resolution for either b&w CCD chips or color ones. For b&w disabling the bayer interpolation is the only way to get access to the full 640x480 resolution. For color CCDs one does transfer the un-interpolated image through the luminance channel which is the least compressed as the color channels are reduced based on the fact that the eye is less sensitive for this losses. See also here for the b&w RAW mode and here for the color mode.

See also Etiennes page.

Back to contents

Where is RAW mode applied ?

Actually RAW mode does involve changes in the camera internal registers. See also here for b&w and here for color.

Back to contents

How can RAW be achieved ?

There are two ways, either through I2C hardware access or through a Windows program WcRmac which does it through the regular driver.

Back to contents

What does happen when I RAW mod my camera ?

It will only change the cameras way of processing the CCD data and is fully reversible.

While setting the cam into RAW mode is a one time action, the stream handling has to be applied while capturing.

Back to contents

How can I get the color image back from this weird looking color RAW image ?

While using the camera one has to capture the luminance (Y channel) only (from the provided IYUV or I420 formatted stream) - for an RGB converted stream one has to use the green channel only. Then for b&w chips all is done i.e. treat the Y or G channel as one gray scale plane. For color CCDs one has to apply a de-bayer (interpolation) to the Y (or G) plane to restore the RGB color image on the computer.

Carsten Arnholm has done an AVIRAW program which converts captured streams of RAW cameras into RGB streams using such debayer algorithms. 

Back to contents

What about MAC users ?

I2C is hardly to achieve through the MAC as the current I2C design uses again the parallel port. Driver based access depends on the implementation of the driver on a MAC. So may be it is a good idea to leave the mode switch on the PC but to attempt image post processing of such modified cameras on the MAC for a first try. 

Back to contents

Computer Connections - which is which ?

Protocol  / Max. Burst Throughput Mbits/s MBytes/s Distance [m]
Serial 0.115 0.02 15
Parallel 8 1.0 2-5
USB 1.1 / 1.2 12 1.5 3 (10 w. hubs)
USB 2.0 480 60 5 (30 w. hubs)
IEEE 1394 - FireWire - ILink 400 50 4.5 (72 w. rep)
IEEE 1394b - FireWire 800 100 up to 100 optical
Wireless Technologies      
Bluetooth 1.1 (2.4GHz) 0.723 0.1 10
Bluetooth 2 (2.4GHz) proposed 2 / 3 0.25 / 0.375 10+ ?
802.11a WiFi 5GHz (net data tp) 54 (25) 6.5 (3) 30 (free field)
802.11b WiFi 2.4GHz (net data tp) 11 (5) 1.2 (0.6) up to 100 
802.11g WiFi 2.4GHz (net data tp) 54 (25) 6.5 (3) 30 (free field)
802.11n  proposed 200++  25 - 75 ?

Serial connection
The RS-232 9-pin com ports we are all used to. These are capable of data transfers up to 115 kbps. It is a relatively slow, low-bandwidth ideal for modems, mice and such like. But with modern serial drivers you can use leads of up to 15 meters.

Parallel connection
The bidirectional Enhanced Parallel Port (EPP) was designed primarily for parallel storage devices such as CD-ROM's, tape drives and a few external hard disk drives. The Extended Capability Port (ECP) is also bidirectional but this is for more modern faster printers and scanners. Both of these types EPP & ECP are about 8 times quicker than the old Centronics standard, at about 1Mbps.

USB 1.1 / 1.2 (Universal Serial Bus)
This is a replacement for the now old Serial RS-232 connection. USB 1.1 with data rates up to 1.5MB/s, is capable of bi-directional data flow and is ideal for slow to medium peripheral devices such as keyboards, mice, digital cameras, printers, modems and so on. As USB is a hub-&-spoke scheme you can connect up to 127 devices in a daisy chain using simple four-wire leads of up to 5 meters long and USB hubs. The devices can be hot-swapped and will automatically identify and configure without having to power down or reboot the computer. The cable is made of four wires, two for data transfer and two for transferring the 5 volt power to the USB device. As they are powered from the computer bus you can tap a small amount of power of them, 0.5A.

USB devices are organized in a tiered array so not every device needs to be directly connected to the host (computer). A device can be connected into a hub, then to another hub and then to the computer. The device is given a unique address ID when connected and co-exists with all the other USB devices and the operating system will load the necessary driver. There is no need to configure IRQ's, addresses or DMA channels. All devices connected to a USB port run off a single IRQ, this avoids the problem of too few IRQ's in PC's today.

USB 2.0
Is an improved standard. It works at about 60MB/s(480Mbit/sec), a big jump from USB 1.1 (1.5MB/s) and will be backward compatible. Will work at about 40 times the speed of USB 1.1. Make sure the USB 2.0 host and devices support Hi-Speed USB to achieve the max throughput.

Bluetooth 1.1 / 1.2
Is wireless technology for the home, general consumer, handhelds and internet linked cell phones. It is a short range radio technology frequency operating in the 2.4GHz ISM band. It has a range of about 10 meters at 0.723MB/s transfer rate. By increasing the power of the transmitter it can be extended up to 100 meters. Bluetooth will support up to nine devices through a piconet (two or more Bluetooth devices sharing a channel) and it can reserve bandwidth for digital voice transmission and will be support up to three simultaneous full-duplex conversations.

Bluetooth 2.0 
to provide between 2 / 3 once up to 10Mbit/sec. Bluetooth 2.0 will be able to work in non-switching narrow-band channels, have better mode functions.

IEEE 1394, (FireWire or iLink)
Is a high speed serial link and can work at up to 50MB/s using a simple 6-pin cable. This makes it quite ideal for data intensive transfers such as video, and is now seen in digital VCR's and digital video cameras. Data transfers between these devices can bypass the computer thus eliminating the operating system to maximize the data transfer speed. 

It can handle up to 63 devices and a typical FireWire interface will have one internal and two external connectors. FireWire devices like USB are also hot-swapable so you can attach or detach with the need to shut down your computer, but unlike USB are NOT powered from the computer bus.

IEEE 1394b, (FireWire or iLink)
will be the next generation. Giving high-speed data transfer at up 100MB/s.

802.11  Connections
WI-FI (802.11a, b, g) – Wireless LAN technology. It is been in the market for some years and now it is seen as mature wireless LAN solution that replaced Ethernet cables in many office and home networks. Ethernet provides 100 Mbps connection while Gigabit Ethernet is much more. Not comparable with Ethernet data-rate, WI-FI struggles to provide good data-rate for bandwidth hungry applications in LAN environment.
Maximum data-rate of 11 Mbps (802.11b), 22 Mbps (802.11a) and 54 Mbps (802.11g). Make sure the devices match each other. The communication range is very dependent on the environment such as walls, buildings etc.

Back to contents

Issues when connecting two web cams to a computer

When connecting two or even more web cams to a single computer you may face some problems which come in different flavors and most are independent of the application that wants to use a camera:

a) One camera works OK - a second one cannot be set into streaming (preview) mode. Usually an error pops up complaining about not being able to render a stream or asking if the drivers are properly installed or even something else.

Try to reconnect them to different ports.

Each device reserves bandwidth and one hub is only able to serve one isochronous device (the streaming mode of the webcam). So if both cams are connected to the same USB hub only one is able to be set in stream mode.

First you may want to check the USB ports and attached devices.

You may open the Device Manager then choose from the Menu / View - by connection. Then lookout for everything that is called USB something and open the tree. Finally you should be able to see to what hubs your cams are connected to as shown above where I connected two cams into one hub.

Now only one can be set into streaming mode, attempting to do it for the second one will show an error message.

b) Immediately after connecting a second camera an error pops up, telling you that the power drawn from the USB port is exceeded.

Try to reconnect them to different ports.

Each USB device asks for a certain power when connected. A hub is only able to provide a limited amount of it to the attached devices - sometimes limited to ports or as sum. So if the sum exceeds the ability an error will show up telling you about that.

Use the same procedure as above to find out what devices are connected to the same port as your cam - then right click the hub and open 'properties' move to the second tab (Power or similar I've no English XP therefore I don't know the label shown).

You may find out how much power is asked for and how much is left - then relocate devices until it works.

 - If you still have ports free but you're missing further free USB hubs then you may have a reason to go shopping. 

c) Toughest one ... After connecting a second camera Windows (also XP) goes down almost immediately or when a cam is set to be used with an application

Find out if there are any two devices (cameras) that are the same brand model and have the same serial number - if so - change one of the cameras serial number to make then unique.

This is usually related to two cams with identical serial number. It should only happen when some kind of software modification has been applied to a camera - either by you or when a modified camera has been sold without unique identifier.

The serial number is located in the cameras internal memory (EEPROM) and will serve the operating system as differentiation criteria if the same brand and model of a camera is connected. Windows for example really expects to have unique cameras and breaks at the lowest level if two are the same.

First connect only one cam at one time to avoid the OS to break.

Then one needs to find out about the cameras serial numbers:

For WinXP connect one camera then open the device manager, look for the main entry of the camera - then right click and choose properties. Here go for the last tab (Details) - there should should be a line like: USB\VID_0471&PID_0311\01690000C6D68201 visible. Check the green marked parts and write them down. 

Disconnect the cam and plug-in the other one, do the same and compare the marked characters of the two cameras - if they are the same you suffering the issue of two identical cameras. If you purchased the cameras in that way without doing anything to them I suggest to visit the dealer and tell him about the issue and ask to solve it as each sold USB device is supposed to be unique otherwise it is just not a compliant device.

If however you've done some kind of modification to the camera e.g. reloading the memory using WcRmac then you've got your two cams to load the same binary image instead of the one that belongs to each of the cameras. Either pull your original binary and load it or visit the QCUIAG site where some of the most favorite cameras dumps are to be found in the file section - those have most probably a different serial number than yours - reload only one of the cameras.

Update 20060219: Assuming you've used WcRmac and accidentally loaded the same binary into two cameras there is a macro to resolve this id clash (get it here !!! Make sure to read the ReadMe.txt file as it explains how to install and to use and what happens)

d) Under older Win versions (i.e. Win98) the image of a second cam gets garbled or false colors.

Nothing to do about it - sorry.

This is by design - the OS / drivers are just not able to deal with this situation.

Back to contents

Copyright © 2002-2005  Martin Burri (bm98). All rights reserved.
As of: Februar 2006