Copyright 2004 - 2006 Martin Burri
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.
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.
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.
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.
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.
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.
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).
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:
Get the circuit diagram of your mod at hand (here is mine)
Step 1: (regular cam mode check)
--> 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)
--> 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
--> 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)
--> 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)
--> 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)
--> 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)
Hope you could resolve the issues and have a working modded cam now !!!
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.
There are two ways, either through I2C hardware access or through a Windows program WcRmac which does it through the regular driver.
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.
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.
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.
Bluetooth 1.1 / 1.2
IEEE 1394, (FireWire or iLink)
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.
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.
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.
Copyright © 2002-2005 Martin Burri (bm98). All rights reserved.