The Hardware
Interface Card
I started with the Internet and gathered all the knowledge which I would need while analyzing the working of the Interface card. After collecting all the material I started studying the complete behavior of the components that I thought would be used in the card. At this crucial point my esteemed friend, came up with a bucket full of innovative and astute ideas that left me with a number of things under consideration. I had a detailed discussion with him and came up to the decision that the design of the interface card depends on the following things.
The device to which the system will be interacting with;
- Microcomputer
- Microcontroller
The port to which the system will be connected with;
- Serial Port
- Parallel port
The type of sensor also affects the design of the Interface card. According to the analysis of the problem; the two possibilities of the sensor types namely.
- Digital Sensors
- Analog Sensors
As described in the above section I had many choices for the design or selection of the sensors, which can detect movement.
- Using Digital compass as sensor.
- Using Crossbow sensor as sensor.
- Using OptoCoupler as sensor.
- Using Voltage Divider configuration using potentiometer as sensor.
- Using Light Variation in Fiber-Optics as sensor.
Digital Compass as Sensor
The best possible choice is to use a digital compass. It will tell the position of the system on earth with reference to the North Pole for the motion of each bend. It supports a serial interface and sends the position in form of hex values serially.
Why not this sensor?
I didn't use digital compass due to a limited budget as it can cost in hundred thousands to purchase digital compass for all bends.
The most efficient and accurate solution for data suite is to use crossbow sensors. They are almost similar to digital compass but more efficient and accurate it gives 26 bytes of data in 10 microseconds. Every data consist of its current position. Motion in x, y, z and also tells you the angular motions and angle in 3d space. It also supports a serial interface.
Why not this sensor?
It has similar problems as I was facing in case of digital compass that it is very costly more than digital compass also it is not available in market and used only for military purposes in target locking systems.
OptoCoupler as Sensor
Variation in light
The basic idea in sensors used is changing light intensity changes current through Photo transistors, or by photodiodes.
A transistor with an open collector current consisting of thermally produced minority carriers and surface leakage. By exposing the collector junction to light a manufacture can produce a phototransistor so it has more sensitivity to light than a photo diode.
A small collector current exists even in transistors with open base. Ignore surface leakage component and concentrate on the thermally produced carriers in collector diode. Now visualize the reverse current produced by these carriers as an ideal current source in parallel with the collector-base junction of an ideal transistor.
Because the base is open circuited all the reverse current is forced into the base of transistor. The resulting collector current is:
I CEO =B dc I R
Where I R is the reverse minority carrier current. This says that the collector current is higher than the original reverse current by factor of B dc .
The Collector diode is sensitive to light as well as heat. In a phototransistor light passes through a window and strikes the collector-base junction. As the light increases I R increases and so does I CEO .
Phototransistor Versus Photodiode
The main difference between photo diode and phototransistor is the current gain B dc . The same amount of light striking both devices produces B dc times more current in a phototransistor than photodiode. The increased sensitivity of a phototransistor is a big advantage over that of a photodiode.
Open base is a usual way to operate phototransistor. You can control the sensitivity by variable base return resistor but base is usually left open to get maximum sensitivity to light. The price paid for increased sensitivity is reduced speed. A phototransistor is more sensitive than photodiode but it cannot turn off and on as fast. A photodiode has typical output current in microamperes and can switch on and off on nana seconds. The phototransistor has typical output current in mille-Amperes but switches on and off in microseconds.
OptoCoupler
In optocoupler LED drives a phototransistor. This is a much sensitive optocoupler than LED Photodiode. The idea is straightforward. Any changes in Vs produce change in LED current, which changes the current through the phototransistor. In turn this produces a changing voltage across the collector emitter terminals. Therefore a signal voltage is coupled from input voltage to output circuit with out any physical interaction between them.
Again the big advantage of an optocoupler is the electrical isolation between the input and output circuit. Stated another way the common for the input circuit is different from the common for the output circuit. Because there is no conductive path between the two circuits. This means that you can ground one of the circuits and float other. For instance the input circuit can be grounded to the chassis of the equipment while the common of the output side is grounded.
Now Led frequency should match with your phototransistor or photodiode which is a difficult problem so we use small bulb which can be operated up to 5V so the problem of light is removed. The bulb slides in pipe and increase or decrease the amount of light on phototransistor so changing distance produces changing current so is voltage and we pass this voltage to out electronic circuit which digitize this analog value of voltage and gives digital out put of change to our computer there our software simulate that effect using 3D matrix transformations.
It was a good option but it has some technical problems of its orientation also the specific soft insulated pipes are not available in small size as I needed. It is also a bit costly.
Fiberoptics as Sensor
The most reliable medium for light traveling is fiber optics. They don't cover many room also easy to install also very accurate ion results. The theory behind this sensor is that when light pass through straight fiber it is collected with out change. But if same amount of light is passed through turned fiber optic it will loose photons of light so resulting in decrease of light intensity at receiving end where we are using any light sensing device.
Why not this Sensor?
I needed a very accurate transmission and receiving system also fiber optical fiber cables are not that flexible in turning it breaks in frequent turning.
Potentiometer as Sensor
We are very much familiar with basic electronic principle of voltage divider in which we change voltage at central point by changing values of resistance. Both are connected in series between Vcc and Ground. As shown in the figure.
Here changing value in R1 and R2 will result in different values of Vout.
The current is same in all the resistance in a series circuit. Also the voltage drops equal of I times R. Therefore the IR voltage are proportional to the series resistance. A higher resistance has a greater IR voltage than a lower resistance in same circuit. Equal resistances have same amount of IR drops. If R1 is double R2, then Vout will be half of Vcc.
Formula for calculating output voltage is
Vout = (Vcc*R2)/(R1+R2)
The component used for dividing voltage is Potentiometer. It has three pins and round body with knob in center if you rotate that knob it will certainly change voltage at center pin by changing R1 and R2 in it.
It is the cheapest solution to be used for sensors. Rods are passed through knobs. One of these sensors is used in the elbow in a way that when you bend your elbow it is rotated and voltage is changed and hence you get change. Two sensors are used in shoulder as we need 3D motion. The setup used at shoulders is actually a twin axis variable resistance joined with knobs. For back, shin, and hip we used the same technique. The value from these sensors is passed to 4051 analog MUX/DMUX. There by control signals of LPT, we select these sensors one by one and display the current position on computer in our program.
Potentiometer: My Approach towards the Problem
Potentiometer
It is simply a variable resistance whose resistance changes with rotation of the knob.
It is a manually adjustable, variable electrical resistor. It has a resistance element that is attached to the circuit by three contacts, or terminals. The ends of the resistance element are attached to two input voltage conductors of the circuit, and the third contact, attached to the output of the circuit, is usually a movable terminal that slides across the resistance element, effectively dividing it into two resistors. Since the position of the movable terminal determines what percentage of the input voltage will actually be applied to the circuit, the potentiometer can be used to vary the magnitude of the voltage; for this reason it is sometimes called a voltage divider. Typical uses of potentiometers are in radio volume controls and television brightness controls.
After analyzing my problem and all its possible solutions I decided to go for the potentiometer approach because of the following reasons.
It is the cheapest solution that can be provided for the problem.
- The potentiometer is very easily available.
Many other reasons are explained as the project is explained in upcoming sections.
How it works?
The basic principle and the working of potentiometer is described above in the report. Now as we have connected these sensors with the body in the way that with the movement of the respective joint the knob of the potentiometer moves and the value of voltage drop changes. The output of the each potentiometer is connected to the 3 to 8 analog multiplexer whose select lines are connected by the controls signals of LPT which gives the privilege to the software to select any sensor at any time as per the requirements. The output of the multiplexer is then connected to analog to digital converter whose output is connected to data pins of computer's parallel port.
The PCB
The Interface Card
All in all the design required the following main components.
- A Multiplexer IC
- An Analog to Digital converter IC
- A Decoder IC
- An Inverter IC
The details and specifications of all these components were searched and a detailed theory was studied from different books .The specifications are provided along with the report to ensure the maximum of design clarity and integrity.
How it works?
The simple and quite vivid explanation of this mechanism can be attributed to some interesting properties possessed by the computer's parallel port. A slot is provided on the card to make connection with the parallel port. I also could have used a micro-controller on the card but in this initial stage I decided to keep things simple plus the widely available 8051 micro-controller doesn't have an ADC on board. The sensors at the other end that are actually variable resistances give their data to the card in serial format. The purpose of the decoder is to select or provide evidence which sensor is in action and thereby giving a suitable combination to the multiplexer being governed by 7414 under the terms provided in the specification sheet.
Computer's parallel port will be controlled by efficient software. This digital data will have a certain limit of values depending on the total number of bits that are being fed to the parallel port. The change in resistance at the sensor end would ultimately be in the desired format at the parallel port. The software will get the desired digital combination and produce the copy of the movement you performed graphically.
At this stage the main achievement is that I have come up with a very effective, low cost and innovative method providing approximately the same results that most expensive products would have delivered.
Testing and analysis
The initial testing and analysis started on the breadboard. Breadboard provides preliminary testing and facilitates analysis by adding components as well as testing for IC's that are faulty. I started to implement the circuit on a single breadboard but later came to the conclusion that it would be a narrow approach because a lot of wires are to be interconnected with each other thereby reducing the circuit clarity.
The ADC Zn448E was not available, which was a part of design initially. By gathering information about that IC I came to know that though that IC is very accurate, it was quite expensive. So I decided to go for the alternative solution with ADC0408.

In this context our initial and final circuit block diagram is shown.
PCB
After thorough testing and analysis I decided to give my circuit a professional look. I.e. implementing it on the PCB.
Vero board
Two types of Vero boards were available one with continuous interconnects and other with no interconnects. At this point I decide to go for the board one with no interconnects. Now for designing the circuit on the Vero board, I took all the components and testing requirements and after two monotonous and hectic days I came up with the final achievement which in itself was larger then the word.
The ICs
Detailed Description of Circuit
Before getting into the details of the card we would like to describe the functionality of all the ICs used in the circuit.
7414
The available component used here is SN7414. It is actually an HEX SCHMITT-TRIGGER INVERTER;
Purpose of use
We are interfacing our digital data to PC where we have 16 analog sensors so to select one sensor at a time we used four PC parallel port control Pins. All four control pins are actually based on negative login means 0V for high and 5V for low also at strobe pin we don't have full 5V so we need some logic level setting device which is no other than Schmitt-trigger Also we need to invert our logic because decoder we used is on Positive logic. That's why we used HEX SCHMITT-TRIGGER INVERTER IC here.
Actual Configuration of 7414
You can see inputs are at pin # 1,3,5,9,11,13. and outputs are at pin # 2,4,6,8,10,13.
VCC is 5V at Pin 14 and GND is at pin 7.
Input pins we used are pin # 9,11,13 and corresponding out puts are at Pin # 8,10,12.
Other pins 1,2,3 are grounded. Where as pin 4 has special purpose here.
It gives constant +5V signal we used capacitor along with two diode in formation of half wave rectification with capacitor of 100nf it will give you –5V output which will be used in out ADC IC. Out put at pin 8,10,12 is supplied to 74138 decoder and 4051 analog multiplexer.
The component we used here is 74LS138.
It is a Low power shottky de-multiplexer commonly used to select addresses in RAM. It acts ideally at a very high frequency as it is fabricated with the low power shottky diode. It outputs an 8 line negative logic bus.
Purpose of use
It does not have a big role in whole circuit. We used it just because we can keep an eye on the selected channel. It tells us which channel is selected at real time by displaying through LED.
Actual Configuration of 74138.
Its power consumption is 32mW. It has multiplexed inputs at pin 1,2,3 and inverted outputs at pin # 7,9,10,11,12,13,14,15. At these outputs we connected cathode of LEDs. Anodes of LEDs are connected to VCC with 470R resistor each require current of 10mA. Pin 6 is enable, which is connected to VCC via 4.7K resistor. VCC is given at pin 16 and GND is given at pin 8. Pin 4 and 5 are low enable so they are also grounded. It is available in 16-pin packing.
4051
The component available is 4094BC
It is an 8-to-1 line analog multiplexer / de-multiplexer with dual power supply. It takes input from 8 different analog inputs and varies from 0 to 5V DC, and outputs one channel as per selection line.
