AUTOMATIC GAIN ADJUSTMENT IN CONTACTLESS COMMUNICATION SYSTEMS V. Kunc, M. Atanasijevic Kunc Faculty of Electrical Engineering, University of Ljubljana, Ljubljana, Slovenia Key words; automatic gain control Abstract: Systems for contactless short range communications are more and more frequentiy used for different applications like access control, inventory and ticketing. Sucli systems comprise a RF transmitter emitting magnetic (electromagnetic) field and one or more transponders, which are supplied by the RF field. The transponder modulates the RF field to send information to the transmitter, which also comprises a reader system. The data transfer can be unidirectional (from transponder to reader) or bi-directional. The receiver system in the transmitter senses the modulation of RF field caused by transponder(s) on the transmitter antenna. Since the distance from transmitter antenna to transponder can vary from practically zero to the maximum operation range, the dynamic range of receive signals is very high. The gain of receive channel must be high to successfully detect the small receive signal but high gain can cause problems in case of large input signals. The solutions to the problem are the clipping of the input signal or automatic gain control or receive channel. The proposed solution describes an automatic gain control, which is specially adapted for RFID applications, as it successfully exploits the special nature of signals in such systems. Avtomatsko nastavljanje ojačenja v brezkontaktnih komunikacijskih sistemih Ključne besede: avtomatska nastavitev ojačenja Izvleček: Sistemi za brezkontakno komunikacijo skokovito pridobivajo na pomenu, saj njihova uporaba nezadržno narašča. Takšen sistem sestavlja oddajnik RF moči, ki oddaja elektromagnetno polje in eden ali več odzivnikov ki to polje uporabljajo za vir energije in preko moduiacije RF polja pošiljajo podatke oddajniku. Pretok podatkov je lahko enosmeren, samo od odzivnika do oddajnika, ali pa v obe smeri. Za sprejem podatkov od odzivnikov vsebuje oddajnik RF moči tudi sprejemni kanal. Sprejemnik opazuje signal na oddajni anteni in ojači vsako spremembo nivoja oddajnega signala. Na ta način sprejemnik zazna moduiacije RF polja s strani odzivnikov. Ker je razdalja med sprejemnikom in odzivnikom lahko zelo različna, od praktično nič pa do maksimalne razdalje, ki še omogoča komunikacijo, je razpon možnih nivojev sprejemnega signala zelo velik. Ker seveda želimo zanesljivo sprejemati tudi najmanjše vhodne signale, ima spremna stopnja veliko ojačenje, kar lahko povzroči probleme pri visokih nivojih vhodnih signalov. Da bi preprečil napačno delovanje v takšnih primerih imamo na razpolago dve možni rešitvi. To je omejevalnik signala ali pa avtomatsko prilagoditev ojačenja nivoju vhodnega signala. Članek opisuje posebno izvedbo sistema za avtomatsko nastavitev ojačenja, ki je prilagojena za sprejemnike signala brezkontaktnih odzivnikov in uspešno izkorišča posebnosti signalov v teh sistemih. 1. Introduction When designing an RFID receiver a maximum communication range is always one of major design goals. This implies that the receive gain is set as high as possible considering the input noise level. The result is that in case the transponder is close to reader antenna and the input signal level is much higherthan the minimum one, the signal at the end stages of receive channel exceeds the liner region of amplifier stage thus causing problems in data communication. Two possible solutions for this problem exist. The simplest possible solution is signal clamping. When the predefined level of the signal amplitude is reached the gain of the gain stage is decreased so that the amplitude can not increase further. This of cause causes signal distortion but since we are usually only interested in receiving digital data the distortion can be tolerated. A bigger disadvantage of clamping system becomes evident in case of communication where a significant level of disturbance signal is added to the communication signal. The disturbance signals usually do not exceed the signal clipping level so they appear at the end of receive gain chain amplified with full gain of receive channel. On the other hand the communication signals are usually higherthan the clipping level so their amplitude is amplified with smaller gain. The obvious result is that the ratio of communication signal to disturbance signal can significantly degrade at the end of receive gain chain compared to the input. The communication signal recognition is aggravated or in worst case becomes impossible. The second possibility is automatic gain adjustment of the receive channel where the receive gain is decreased in case of higher input signal levels. The gain than is the same for communication signal as well as for any possible disturbance signals resulting in no decrease of signal to disturbance ratio. 2. AGC system design Automatic gain control (AGG) circuits are well established in telecommunication and audio systems. The basic design problem in AGC design is the impact of gain change on the input signal. The input signal degradation due to AGG aetion must be kept at minimum and all important signal parameters (information eontent) should not be affected. To achieve this the nature of the input signal must be eare-fully studied and the AGG system designed for the particular input signals. The most important parameters are the gain change decision algorithm and the speed at which the gain is decreased and increased. The classical AGG solution comprises compactors which determine if the signal amplitude at given gain stage is lower or higher than the predefined level for AGG action. If that level is exceeded the AGG reacts by rapid gain decrease. This mode of operation is called attack mode and the speed of gain decrease attack speed. The AGG system remains in this attack mode till the gain decrease results in signal amplitude below the AGG threshold level. At that point the AGG system enters second mode called decay mode. During decay the gain starts increasing back towards it original (high) level. In case the signal amplitude again exceeds AGG threshold level as a result of decay action or input signal increase the AGG systems returns to attack mode. At constant signal level the AGG system constantly switches between attack and decay mode so the decay speed must be orders of magnitude lower than attack speed to minimise the impact of mode switching on the input signal. The AGG system action is finally finished when the input signal is low enough that the decay action restores the default high gain and the AGG system is deactivated. Our design solution of AGG system differs from above described classical one as it was designed for specific type of input signals existing in RFID communication. The protocol of RFID communication starts with the command sent from the reader to the transponder. The transponder reacts on the command and sends required data to the reader. The actual data is usually preceded by a preamble to prepare the reader for receiving the data. The coding format of the data is known so the AGG system has the information of the minimum and maximum possible time between two pulses. It is also reasonable to assume that the transponder is not able to change position in the RF field in the timeframe of data transfer so the same signal amplitude inside one data package can be expected. But immediately after the end of data transfer from one transponder a communication with different transponder, having completely different position in RF field and therefore different signal amplitude can start. It is evident that the AGG system for such signals must have a fast attack speed to set the gain correctly well inside the preamble before the actual data receive starts. The second imperative is that also decay speed must be relatively high since the reader must be prepared to receive new data at completely different signal level in a short time after the first data transfer is finished. To satisfy these requirements we devised an AGG system, which has three modes of operation instead of two as in classical solution. These modes are attack, decay and idle mode. The attack mode is started when the signal amplitude at the output of gain stage exceeds the defined threshold level. A rapid gain decrease is triggered and the signal amplitude is reduced below the threshold level. The conditions for attack mode are not preset anymore but the system does not enter usual decay mode, instead the system waits in idle mode till conditions for decay or new attack are fulfilled. In idle mode the gain is not changing and is kept at the level defined by previous attack mode. The transition from idle mode to decay mode occurs if there are no incoming signals for a certain amount of time. The detection of data is performed using second comparator which has threshold level far below the AGG attack level (approximately one half of attack level) but still well above expected noise level. During data transfer package input pulses are always above idle mode comparator level. When the data transfer is finished these pulses stop and the idle mode comparator is not producing output pulses. If this condition persist longer than twice the maximum time space between two pulses as defined by data coding protocol the AGG system changes state from idle to decay. The decay is fast since the reader must be prepared for new data package from another transponder in relatively short time. The AGG action is finished when the gain is increased back to the default value. The typical data receiving sequence using such AGG system starts with the preamble send by the tag. During preamble the receive channel evaluates if the signal is too high and reduces the gain accordingly by setting the AGG system to attack mode. Well before the preamble transmission from transponder is finished is the receive channel AGG system already in idle mode. It stays in idle mode all through data transfer since input signal above idle mode threshold is always present. After the data transmission is finished the AGG stays in idle mode for a defined time and changes state to fast decay mode. A case of short data transfer from three different transponders having different signal levels is presented on fig. 1. In the upper canvas the output signal of the receive gain stage is shown. The receiving signal from the first transponder (shown in second canvas) was higher than the AGG limit presented as two straight lines on the same canvas. The attack mode is triggered. The flag presenting the attack mode is shown in canvas four. The attack is repeated everytime the output signal exceeds the upper or lower limit. After two periods of incoming signal the gain is adjusted and the AGG system enters idle mode. Following pulses are received correctly with the gain set during attack time. The correctly received digitised signal is presented on the lowest canvas. After the receive signal stops the AGG system remains in idle for a time longer than two maximum receive signals periods. This is followed by a fast decay mode (the decay mode flag is presented on canvas three). Two more signal packages follow. The second one has higher amplitude than the first one so the AGG system must reduce the gain practically to the lowest possible. After the end of receive signal package another fast decay cycle follows. The receive system is again ready for new receive signal package (third one) which has a low signal amplitude so no AGG action is needed. 3. Conclusion The AGG system for contactless data communication system using RF powered transponders was designed based on the idea that only through a throughout knowledge of the nature of receive signal an optimum automatic gain control can be devised. The resulting system is perfectly suited for the task since it performs necessary gain adjustment only during the preamble of the incoming data package while there is absolutely no gain change during the actual data transfer. It also allows extremely fast gain recovery after the end of data transmission. All this ensures a reliable data receive in complete incoming signal amplitude range. Canvas 1: Analog output signal after the AGG gain stage Canvas 2: Analog input signal Canvas 3: Fast decay mode flag Canvas 4: Attack mode flag Canvas 5: Clock signal for gain change counters (active during attack and decay) Canvas 6: Digitised receive signal V.Kunc, M.Atanasijevič Kune Faculty of Electrical Engineering Tržaška 25, 1000 Ljubljana, Slovenia E-mall: vinko@kalvarija.fe.uni-lj.si Prispelo (Arrived): 06.06.2002 Sprejeto (Accepted): 25.05.2003