Published:2009/6/22 22:55:00 Author:May | From:SeekIC
A 16-step programmable current generator can be modified so that it's controllable by a printer port. This is done by switching the resistor connected between the output of the generator's OA1 op amp and the input of OA2. The CMOS single 16-channel analog multiplexer (ICl) chooses one resis-tor at a time, in accordance with the code sent by the printer port through four of its eight data-out-put lines (pins 2 to 9). In addition, one control line (pin 1) is used to enable the operation. As a result, 16 outputs can be selected by a 4-bit word (the table shows the relationship between data word and selected resistor).The following must be fulfilled in order for the circuit to work as a true current generator:
R2×Rd-Rb×Rc =0
The smaller the resistors' tolerance (especially RI through R16), the greater the output resis-tance of the generator.Because the OA2 is connected as a repeater, the current I2 = O, and only the load current flows through one of the RI through R16 resistors. Therefore:
where Vout=Vin;X=1…16;and Ron≤150Ω(for VDD=10 V) is the resistance of one analog switch(CD4067)in conduction Therefore,the values of resistors R1 through R16 can be inferred from the needed currents∶
The Turbo c++ program also controls the current through the load
Reprinted Url Of This Article:
http://www.seekic.com/circuit_diagram/Basic_Circuit/Digital_Circuit/PRINTER_PORT.html
Print this Page | Comments | Reading(3)
Code: