Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Simulator touch-memory DS1990A (ASM,BIN,DLL,...)

Status
Not open for further replies.

tpetar

Advanced Member level 7
Joined
Sep 27, 2010
Messages
6,417
Helped
1,713
Reputation
3,456
Reaction score
1,673
Trophy points
1,393
Location
Pancevo-Belgrade, Serbia
Activity points
37,363
Simulator touch-memory DS1990A (Ridiko Drozdov (wubblick@yahoo.com))
This project is a development project if you've lost Touch Memory ...
Original Web address: touch-memory DS1990A ( (wubblick@yahoo.com)) - guarda.ru
pic42_05.jpg

Simulator touch-memory DS1990A, which is offered to your attention, able to remember numbers up to 30 different keys, and then simulate any key. Numbers can be entered in two ways: by direct reading of the original or manual input into the computer with the following entry in the simulator via RS-232. A computer can be the base key, which indicates the type, serial number and a text description.

Touch Memory type DS1990A is a passive device (no internal power supply), which contains recorded with a laser ROM. ROM contains a unique serial number. To read data from the DS1990A uses 1-wire bus company DALLAS. DS1990A is a slave device, and the master is typically a microprocessor. Meals during the DS1990A data produced from 1-wire bus. The equivalent circuit of the interface of the DS1990A is shown in Figure 1a.
pic42_01.jpg

Figure 1. The equivalent circuit of the interface of the DS1990A (a) and master (b).

A similar interface part and a master (Fig.1b), the difference is the presence of pull-up resistor. In a waiting-wire bus is logic high. Sequence access DS1990A 1-wire bus is as follows:

- Initialization

- Read command ROM

- Reading data

All shipping and 1-Wire bus begin with initialization. Initialization is performed in the following sequence (Fig. 2):
pic42_02.jpg

Figure 2. Initialization of the exchange on the 1-wire bus.

- Master sends a reset pulse (reset pulse) - low signal duration of at least 480 ms.

- In response to a reset pulse to be the slave (presence pulse) - low signal duration of 60 - 240 ms, generated by 15 - 60 ms after the reset pulse.

The answer gives the slave master to understand that there's a device on the bus and DS1990A is ready to exchange. Once the wizard has found the answer, it can transmit a read command ROM. Read command has the ROM code 33H. Data transfer is carried out by forming a special time slots (time slots). Each time slot is used to transmit one bit. Transmitted least significant bit first. Pulse interval starts low, the duration of which is in the range 1 - 15 ms. Since the transition from zero to unity is less sensitive to the capacity of the tire (it forms an open transistor, while the transition from zero to one formed by pull-up resistor), it is this transition DS1990A uses to synchronize with the master. In DS1990A start time delay circuit, which determines the time of data reading. The nominal value of the delay is 30 microseconds, but it can vary between 15 - 60 ms. For low pulse should be transmitted bits. It must be kept on the bus 60 - 120 ms from the beginning of the interval. The time interval is completed translation of the tire in the state of a high level for at least 1 ms. This is necessary to charge the internal capacitor which provides power to the DS1990A. Similarly, the time intervals are formed for all the transmitted bits (Fig. 3).
pic42_03.jpg

Figure 3. Recording intervals of zero and unity in the 1-wire bus.

By adopting a read command ROM, DS1990A transmits the 8-bit code such as device (DS1990A is 01H), 48-bit serial number and an 8-bit checksum. The time intervals for received bits also form the master. Pulse interval begins low level duration of 1 - 15 ms. Then the master must release the bus to allow the output data bit DS1990A. The transition from zero to unity DS1990A on the bus outputs data bits and starts a time delay circuit, which determines how long the data bits will be present on the bus. This time is between 15 - 60 ms. For data on the bus is guaranteed to have been established, it takes some time. Therefore moment of reading the master must defend a little less than 15 ms from the beginning of time interval (Figure 4).
pic42_04.jpg

Figure 4. Reading interval of 1-wire bus.

The correctness of the received data is controlled by the control amount (Fig. 9). If you calculate the checksum of all eight bytes read (including the read byte checksum), in the absence of errors is supposed to be zero. Sub-checksum is shown below:
http://guarda.ru/guarda/data_pic/code_lock/pic42_09.jpg
This routine must be called for each byte involved in calculating the checksum. Byte must be placed in A. The checksum is obtained in a memory cell TEMP (before the checksum, this cell must be reset to zero).

Schematic diagram of the device shown in Fig. 5. The key is micro firm Atmel AT89C2051. This microcontroller has a built-ROM software with an electrical erasure of 2 Kbytes. The microcontroller operates at a clock frequency of 12 MHz. The program contains a lot of pieces that are critical to the execution time, so different frequencies without appropriate adjustments to the program is impossible.
http://guarda.ru/guarda/data_pic/code_lock/pic42_05.jpg
Figure 5. Schematic diagram of simulated touch-memory DS1990A.

To display the number of current key device used in a dual 7-segment LED display with common anode HG1. To reduce the number of circuit elements used dynamic display, implemented in software. Cathodes display through current-limiting resistors are connected to the port P1. The anodes are operated switches VT1 and VT2. Keys control the same scan line T0 and T1. Cathode connection of the two digits of the display made in random order, because it's more convenient for the topology of the circuit board. In this regard, for each bit of the indicator in the program used a separate table for character generator. The same line of port P1, which are connected to the cathodes of the indicators used for the scan buttons SB1 and SB2. Return line - port P1.7. Diodes VD2 and VD3 prevent the closure of lines P1.0 and P1.1 (and malfunctioning display) while pressing two buttons.

To save controller ports non-volatile memory chip, which stores the key number is connected to the scan lines of display T0 and T1. The scanning process is a series of conditions "Start" and "Stop" I2C bus and the memory chips to work has no effect. During cycles of read / write to the I2C bus scan process indicator is suspended. At the same indicators are quenched by O port P1 of all units.

As the 1-Wire port pin INT0 used microcontroller. Elements R1, VD1 have a protective function. For the DQ pin and GND can be connected in parallel and touch probe DS9092 touch port DS9092R. However, their value, perhaps more than the cost of the device. Therefore, we can do more than simple contact devices.

Level converter for RS-232 port is made with transistors VT3 and VT4. The negative voltage supply comes from the port of the computer through the contact RTS.

The device is powered from the battery of three elements (eg, size AAA) with a total voltage of 4.5 V. The efficiency of the device is stored in the supply voltage to 3 V.

No device will not require it. Suffice it to installation was completed without error, and from the healthy parts. U2 chip can be replaced with 24C08, 24C16, 24LC04, 24LC08, 24LC16. It is important that it can record at supply voltage down to 3 V (chip some manufacturers prohibit the entry at a voltage less than 4.5V). Instead, the indicator can be applied HG1 two separate indicators of any type, is only important that they have a common anode. And, of course, sufficient brightness. Transistors can use any low-power corresponding to the conductivity of the collector with a maximum current of at least 50 mA. For RS-232 connector plug used D-SUB-9, which is designed for volume assembly. The board is between the rows of contacts are soldered to the respective slats. Buttons (bezfiksatsionnye) and the power switch can be used any compact, only in this case may require an adjustment of the PCB. Schematic of the PCB device is shown in Figure 6.
http://guarda.ru/guarda/data_pic/code_lock/pic42_06.jpg
Figure 6. Schematic of the PCB simulator touch-memory DS1990A.

At power-on indicator displays the current serial number key. The sequence number is stored in nonvolatile memory at the entrance to the simulation mode. There can be up to 30 keys. Browse the serial number you can use the "UP" and "DOWN". If the 1-wire port to connect the DS1990A, then the serial number will be read and written to memory for the current sequence number. In the case of a successful reading on indicators for 2 seconds appears "Pr". Now the device can simulate the read key. To do this, enter the simulation mode by pressing the "GO". In this mode, the indicator displays the symbol "P", and the "UP" and "DOWN" is not valid. In the simulation of 1-Wire port can be connected to the reader touch memory, and he will react to this as the connection of the original DS1990A. Exit can simulate the secondary pressing the "GO".


pic42_10.jpg


pic42_11.jpg


pic42_07.jpg

Figure 7. The user interface of the program manager's keys.

See Complete text on original address....
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top