TRANSACTION SYSTEM This invention relates to a transaction system in which a portable token, for example a
card, is used in conjunction with a device, often termed a terminal, to perform a transaction of some kind. The invention is particularly, but not exclusively, related to
smart cards.
Contactless tokens work on, or close to, a terminal which provides power. This power is supplied via a RF (radio frequency) induction field which is referred to as a carrier. Power is transferred from an aerial on the terminal to an aerial on the token and is akin to the terminal being a primary coil of a transformer and the token a secondary coil. In particular embodiments both the terminal and the token each have a single coil aerial.
As well as power being transmitted from the terminal to the token, data is transmitted from the terminal to the token and vice versa. The exchange of data is used to perform a transaction. Transmission of data from the terminal is straightforward because it is simply modulated onto the carrier. Transmission of data from the token to the terminal may be effected by switching an impedance in the token to modulate the amplitude of the carrier at the terminal as the token draws extra power from the terminal due to the switching action.
As technology improves the power consumption of tokens is being reduced. This means that tokens can work further away from the reader, that is the volume or field of operation of the terminal is larger.
It is important for a steady voltage to be supplied to a controller or processor on the token because its logic circuits will only work reliably if the voltage supply is within
prescribed limits. However, the amount of RF magnetic field picked up by the aerial of the token varies with token orientation and position with respect to the terminal aerial. As a result an unregulated voltage supply is received by the token. For this reason a regulator, such as a shunt regulator, is incorporated into circuitry connected to the token
aerial in order to regulate the unregulated voltage supply.
In certain circumstances the controller may try to take more current than is readily available. This can happen when the controller is switched on, if there is a change made to the clock speed (for example increased) at which the controller operates or if the controller is performing a particular function which requires a relatively high power, such as writing to EEPROM. If the controller tries to take more current than is available from the regulator the voltage supplied to the controller falls. If the voltage falls sufficiently then the controller may give unreliable operation. If the voltage falls by a larger amount then the unregulated voltage supplied to the token by the terminal may also fall. This could cause interface circuitry on the token, such as anti-collision circuitry, to stop working.
To prevent this problem occurring it is necessary to detect when the controller is
demanding too much current. This condition needs to be detected at low current
because it is most likely to happen when the token is at a large distance from the terminal and there is minimum power available. The normal method of measuring current in an integrated circuit is by measuring the voltage that it drops across a resistor
through which it flows. Measured voltage is compared with a reference voltage supplied by a reference circuit such as a bandgap reference circuit. This is inaccurate due to variation in the absolute values of the resistor, the bandgap reference, the voltage reference and the comparator and which may vary due to manufacturing tolerances and
temperature dependence. This resistor could be located between the regulator and the input to supply power to the controller. This would measure the current directly being used by the controller. However, this would waste power and cause the voltage supplied to the controller to vary with current drawn because as more current is drawn by the controller, more voltage would be dropped across the resistor and therefore less would be available to the controller. Also, to detect accurately a low current being used by the controller, for example when it has a low clock rate, requires a large resistor value which will cause greater power dissipation and drop significant voltage across itself.
According to a first aspect the invention provides a method of controlling a power supply to a controller on a contactless token the token comprising an interface having a regulator for controlling a voltage supply to the controller characterised in that the regulator compares the voltage supply to a first reference voltage supply to produce a control voltage which is compared to a second reference voltage supply to detect when the controller is drawing too much current.
According to a second aspect the invention provides a contactless token the token having an interface for providing power to a controller the interface having a regulator
for controlling a voltage supply to the controller characterised in that the regulator uses a comparator to compare the voltage supply to a first reference voltage supply to
produce a control voltage which is compared to a second reference voltage supply to
detect when the controller is drawing too much current.
Conveniently the first and second reference voltages originate from the same source.
Preferably they have substantially the same value.
According to a third aspect the invention provides a transaction system incorporating a contactless token operating a method according to the first aspect of the invention or incorporating a contactless token according to the second aspect of the invention.
Preferably the regulator generates a control signal when the voltage supply falls too far relative to the reference voltage supply. Preferably the token detects when the voltage supply is at an end of its allowed range and then provides a control signal indicating that the controller is drawing too much current. Preferably the signal indicating that the controller is drawing too much current is used to change operation of the controller so that it draws less current.
Preferably the comparator of the regulator provides an output to a switch which directs current flow to control the voltage supply. Preferably the switch is a transistor such as
a field effect transistor. The switch may be used to measure the voltage supply.
Preferably the regulator is a shunt regulator. Preferably the reference voltage supply is provided by the controller. Preferably the controller is a microprocessor.
Preferably the token is a smart card.
An embodiment of the invention will now be described by way of example only with
reference to the accompanying drawing in which:
Figure 1 shows a circuit on a contactless token for receiving electrical power and controlling power supply to a controller; and
Figure 2 shows a circuit for producing a reference voltage in controlling power supply to a controller.
Figure 1 shows part of an interface circuit 10 for a contactless token. The circuit 10 has an aerial 12 which receives electrical energy in the form of a carrier from a terminal (not shown). The aerial is tuned with a capacitor 14 to receive a particular frequency of the carrier and to generate an alternating signal in the circuit 10.
The alternating signal is rectified by a rectifier 16 to provide the token with a DC power supply. The output of the rectifier 16 has a ripple voltage and so a smoothing capacitor 18 is used to smooth the output of the rectifier 16 to provide a smoothed DC voltage Vunreg . In addition to the carrier providing a power supply for the token, it may be modulated with information in the form of transaction data, a clock signal (from which
the token can derive a clock for its controller) or both. The information remains present
in the smoothed V„g . The information may be extracted at point 20.
It is important to maintain a steady voltage supply Vcc to a controller 22. To achieve this the circuit 10 is provided with a shunt regulator 24. The shunt regulator 24
regulates the flow of current through a transistor 26 from a relatively high potential rail 28 to a relatively low potential rail 30. This serves to maintain the steady voltage supply
Vcc of rail 28 which is supplied to the controller 22. In this embodiment the transistor 26 is a field effect transistor. Operation of the transistor 26 is controlled by an operational amplifier 32 which compares a proportion of voltage on rail 28 against a known reference voltage 34 to produce a controlling voltage 36. Resistors 38 and 40
are a divider chain which scales the voltage on rail 28 to a suitable value at point 50 which is comparable with reference voltage 34.
The controlling voltage 36 for the shunt regulator 24 is measured at the gate or base of transistor 26. If the controlling voltage 36 at the transistor 26 falls too far this implies that the transistor is not operating and is switched off. This means that no current is flowing from drain to source in the transistor 26 which means that the controller 22 is taking all the available current. To detect this condition the controlling voltage 36 is compared with a known reference voltage 42 in a detector 44 to generate a signal 46 when the controlling voltage 36 falls too far. The reference voltage 42 could be the same as reference voltage 34 and both could be generated by a band gap circuit.
Clearly since the controlling voltage 36, which controls the operation of the transister
26, controls the value of the voltage on rail 28. Therefore, by measuring controlling
voltage 36 (by comparing it with reference voltage 42 in the detector 44) the effect on the voltage on rail 28, and thus the current drawn by the controller 22, is being measured indirectly.
This method provides a way of indirectly measuring the current which is being taken by the controller 22 by monitoring the operation of the shunt regulator 24. If the shunt
regulator 24 is not controlling the voltage supply Vcc this indicates that the controller 22 is drawing too much power. If Vcc is at a correct level, current flows in the shunt
regulator 24. If the current in the shunt regulator 24 falls below a set limit, then it can be assumed that Vcc is not stable. Once this condition has been detected, appropriate action can be taken, for example resetting the controller 22 or slowing or stopping its clock using signal 46. A method of controlling the clock speed on a token by using a variable tone modulated onto the carrier is described in GB patent application 9706019. Following the appropriate action, the token can re-start or be set to standard operating parameters after a period of time and the shunt regulator 24 can check if controller 22 is still drawing too much current. The problem would be alleviated if a user of the token placed it closer to a terminal so that more power is available.
Since the switch (transistor 26) of the shunt regulator 24 operates on a small amount of current (in the order of microamps), the method is highly sensitive to detecting when the controller 22 is taking more current than it should.
Figure 2 shows part of a circuit 60 which is used to generate the reference voltage 42.
The circuit of Figure 2 shares similar features of the circuit of Figure 1 and so the
similar features of the Figures have corresponding reference numerals.
In common with Figure 1, shunt regulator 24 controls the voltage on rail 28 by controlling the amount of current which flows through transistor 26 to rail 30. As
explained in the foregoing the circuit of Figure 1 is configured to measure this current and to detect when it reached a minimum value, that is, a value at which it is considered that the shunt regulator 24 is not functioning properly. If the shunt regulator 24 is not
functioning properly, this means that the controller is taking all of the available current.
In addition there is provided a current source 62 having a known value. This is set to be the same as the minimum current flowing through the transistor 26 or a predetermined proportion of it. The current source 62 is connected to a transistor 64 which has its gate connected to its drain. Detector 44 compares the voltages of transistor 26 and transistor 64. As transistors 26 and transistor 64 are both on the same silicon die and have both been made under the same process conditions, the circuit of Figure 2 provides a very accurate way of detecting non-functioning of the shunt regulator 24.
Reference voltage 42 is the gate-source voltage (since the gate is joined to the drain) which is required to allow the fixed current of the current source 62 to flow through the transistor 64. Therefore if the transistors 26 and 64 are identical, the detector 44 detects when current flowing through the transistor 26 falls below that produced by the current source 62. If the transistors 26 and 64 are designed to have a specified proportional
relationship, for example 1:5, the detector detects current flows in the transistors in a corresponding proportional relationship.
The detector 44 could be a comparator. Alternatively, if it is required that the current flow through the transistor 26 should be maintained above a pre-determined value, a current mirror could be incorporated into the circuit 10. This requires another transistor
to have the same gate/source voltage as the transistor 26 and be arranged to take an exact proportion of the current, for example 1%, flowing through the transistor 26 without
disturbing it or the rest of the circuit . This proportional current can be measured by checking the voltage drop it causes across a resistor of a known value.
There is a load resistor 48 (having a value R 0An) between the rectifier 16 and the regulator 24. The load resistor 48 allows a pre-determined current to be made available to the controller 22 and the regulator 24. The maximum current available is
V unreg -V cc
D
ΛLOAD
where Vcc is the regulated voltage. Vcc is set by a divider chain and the reference voltage 34 and is fixed. V^g will change depending on how much power the token captures from RF field. This will depend for example on position and orientation of the token with respect to the terminal aerial. Therefore the maximum available current will vary but will typically decrease as the token is moved further from the terminal.
Transmission of data from the token to the terminal is effected by switching a load or impedance 52 in parallel with the load resistor 48