You are on page 1of 8

TAXI MOBILE UNIT MANAGEMENT SYSTEM: MOBILE UNIT IMPLEMENTATION

Abstract: Discussed in this paper, is the analysis, design and implementation details of the taxi mobile unit management system. The system is basically an Electronic Fare Settlement (EFS) used in public transportation. The supporting information on GSM/GPRS networking, Contactless Smart Card technology, and Short Range RF communications is first presented. This is followed by the design of the Mobile Unit system and the location identifier system. The Mobile unit is installed in the minibus taxi and is used as the terminal for processing fare settlement transactions. Location Identifier is installed at each bus stop and is used to send zone location ID to the mobile unit for fare calculations based on the distance travelled by the commuter. The designed and constructed system is tested and then evaluated to determine its performance. Recommendations for future improvements on the system are finally specified and a conclusion established.

Ratoka G. Lekhema
School of Electrical & Information Engineering, University of the Witwatersrand, Private Bag 3, 2050, Johannesburg, South Africa Keywords: GPRS, MIFARE Contactless Smart Card, RF data communications, EFS, Transportation Manager (TM)

1. INTRODUCTION A world class public transportation system is mainly aimed at ensuring absolute satisfaction of both commuters and service operators. Features which distinguish the world class public transportation service include reliability of the service, punctual conveying of commuters, consistent and economical fares and incorporation of standard safety and security measures [1]. The South African public transportation is currently dominated by the minibus taxi industry which does not exhibit the above mentioned characteristics. With the upcoming events in South Africa such as 2010 soccer world cup, it is imperative to ameliorate the minibus taxi service to meet the necessary world standards. Electronic fare settlement (EFS) is one of the alternatives which can be incorporated in public transportation to reduce the safety hazards of carrying tangible cash by both commuters and operators. Furthermore, the EFS service may reduce the money (cash and coins) handling time and expenses, and therefore increase the speed of travelling while reducing the associated cost of travel. To facilitate rapid fare settlement transactions, General Packet Radio Service (GPRS) provided by Global Systems for Mobile communications (GSM) network providers can be economically deployed as a communication medium to wirelessly link commuters prepaid accounts to the minibus taxi mobile unit at the point of travel. Contactless Smart cards can be utilized as prepaid identity cards by commuters for rapid embarking and disembarking, and also to facilitate secure fare settlement transaction authentication. For precise transportation fare calculation, licence free Radio Frequency (RF) data communication can be incorporated to identify the zone locations of embarking and disembarking commuters. The main aim of the document is to provide comprehensive details of the analysis, design and

implementation of the taxi mobile unit management system. This is basically a system to facilitate the EFS in minibus taxi industry. The general illustration of the system is portrayed in figure 1 below. To accomplish the depicted system, analysis will first be carried out on the contactless smart cards (used as TransCards), GPRS and license free Industrial, Scientific and Medical (ISM) RF communications. This will be followed by the design and implementation of the system. Furthermore, testing and evaluation will be conducted to determine the performance of the system. Finally, based on the results obtained, a conclusion will be established and recommendations proposed.

Figure 1: General System Illustration 2. PROJECT OVERVIEW 2.1 SYSTEM SPECIFICATIONS, REQUIREMENTS AND ASSUMPTIONS The system should be applied in public transportation organization such as minibus taxi industry to replace fare payment in tangible. The basic specifications required to be analysed, designed and implemented are as follows: • Commuters should register with Transportation Manager (TM) system to obtain prepaid accounts. • Commuters must use secure form of identity to authenticate access to the system facilities such as electronic fare settlement.

1 CONTACTLESS SMART CARD AND READER Smart cards are used extensively in applications which require secure information storage and clients identity. MIFARE is a contactless proximity card technology developed by Phillips. Without any data transmission. One of the leading technologies used in developing smart cards and readers is MIFARE. Furthermore. The financial and time constraints let to the implementation of the most cost effective.2 SUCCESS CRITERIA AND CONSTRAINTS The designed system is considered successful only if all the basic specifications are implemented. The profound comprehension of the contactless smart cards and readers should first be established in order to effectively integrate such cards into the Taxi electronic fare settlement application.1 CONTACTLESS SMART CARD OVERVIEW The contactless smart card is basically a plastic card embedded with a secure microcontroller or equivalent device and data storage memory [7]. The enclosed microcontroller renders functionality such as secure management. implemented. The reader transmits data by setting “Data 1” to zero when transmitting a logic one and by setting “Data 0” to zero when transmitting logic zero. This is accomplished by the application of common private symmetric keys shared between the card and the reader and the cryptography algorithms to make the communication successful [7]. BACKGROUND INFORMATION In order to integrate the subcomponents and implement the system. simplified version of the system. both lines remain high. storage and access to data stored on the card. hardware permitting system upgrading must be used to accommodate for potential developments. 3. a number of vital aspects had to be comprehensively understood first. • The system must have the potential to bill commuters only for the distance travelled It is assumed that the wireless data communication network selected is reliable enough to provide online transactions at all times. The microcontroller also performs complex functions such as encryption and decryption of data stored on the card. The general Wiegand data format is exhibited in figure 2 above [3].5 cm to 10 cm [8]. The typical read range of MIFARE smart cards is between 2. These covered the smart card technology. The Wiegand data format consists of two data lines named “Data 0” and “Data 1” respectively and a ground for return path. Each bit pulse last for about 50 µs while the interval between bit zero and bit one is about 2 ms. MIFARE smart cards and readers are mainly used in public transportation transactions payment applications. tested and analysed. The international standards for contactless smart cards operating at 13. the system must be reliable.1. Having understood the mentioned technologies. the system was then designed. Information interchange between the smart card and the reader is intelligently carried out though RF communications. 3. The basic output format of the MIFARE card reader is in Wiegand data format which is based on the Wiegand effect [3]. The applications of symmetric keys and cryptography algorithms facilitate the mutual authentication between the card and the reader and this can be applied to deliver secure transactions. The data memory of MIFARE card is divided into 16 separate sectors which can be configured to stored information for different applications.1. The first memory sector is used as the default directory where the card’s unique serial number is stored [8].2 CONTACTLESS SMART CARD READER Due to the pre-programmed symmetric keys. smart cards inhibit repeat attacks and illicit duplication of the cards.56MHz are stated under ISO 14443 [2]. The absence of pulse for about 200ms signals the end of serial data transmission block. 3. • 2. • The system is required to be flexible enough to be comparable with tangible cash fare settlement option. portable and robust. Again.The mobile unit must communicate with the TM through wireless data communication network. GPRS networking and RF data communications. contactless card readers can only read cards with matching keys. Furthermore. 3. Figure 2: Wiegand signal timing protocol Different types of Wiegand data formats are Wiegand 26 and Wiegand 37. The factory programmed MIFARE card is equipped with a 16-bit card serial .

etc. Network service provides currently support wireless communication options such as EDGE and 3G (with . 3. GPRS makes it possible for mobile cellular systems to connect to remote systems through internet. As a result.1 GPRS NETWORK RCHITECTURE The GSM network supports GPRS networking through Serving GPRS Support Node (SGSN) and Gateway GPRS Support Note (GGSN).2. GGSN is also responsible for mobile devices IP assignment [11]. there is a vast amount of information about smart cards and GPRS available on internet as well from transportation organizations. UDP/IP or FTP/IP.1 DESIGN APPROACH There is a wide number of emerging transit applications which utilizes EFS option. 3. Apart from that.3 GSM/GPRS SECURITY The wireless communication between the mobile unit and the accounts management system must be secure enough to protect commuters accounts information. With these security measures. 3. was to determine a lucid framework of how MIFARE smart cards and readers work. 3. please refer to the Taxi Route Identification System [9]. the mobile device must first create a point-to-point (PPP) connection to the service provider GPRS network node. The first task executed. confidentiality. then the RF spectrum wavebands allocation is managed by stringent regulations from the national and international agencies.3 RF DATA COMMUNICATION RF data communication is achieved by the use of radio frequency part of electromagnetic spectrum. The SGSN facilitates the delivery of data packets to and from the mobile device and its functionality includes mobile device location management. The PDP context is a data structure present on both SGSN and GGSN and stores the subscriber active session information such as subscriber’s IP.2. The DHCP server at the GGSN node allocates the mobile device a private IP based on the IPv4 addressing guidelines for GPRS networks and mobile devices [4]. The Network Address Translator (NAT) at the public IP server facilitates the connection of the private IP from the mobile device to the global IP network. then modulated into RF format and transmitted by the transmitter. Furthermore.2 LAUNCHING A GPRS CONNECTION BETWEEN MOBILE DEVICE AND REMOTE SERVER To establish a connection to the remote server. Once the PDP context has been activated.bit Wiegand data format. The receiver demodulated the received RF signal and the decoder recovers the originally sent data. data packets routing and transfer as well as authentications and mobile device subscriber billing. However. In RF data communications. The GSM/GPRS network operators normally issue subscribers with Subscriber Identity Module (SIM) cards which are smart cards and provide securities measures such as cryptography for data sent and received from the GPRS network. short range low power RF wavebands like ISM are license free in South Africa. the mobile device can connect to or receive connections from a remote server IP through a specific port and exchange data over the internet through protocols such as TCP/IP. The basics of EFS application is similar to wireless point-of-sale payment processing systems where smart cards are used for customer ID and GPRS is used for communications. 4. The GGSN serves as a gateway from the GPRS backbone network to the external data network (internet) and is responsible for converting incoming data packets from SGSN into appropriate Packet Data Protocol (PDP) format.2 GPRS NETWORK GPRS is a packet-based data network which uses the existing GSM network to transmit and receive Transmission Control Protocols/Internet Protocols (TCP/IP) to and from the GPRS mobile cellular device. IP spoofing. numerous projects have been conducted on security applications which utilize contactless smart card. The denial-of-service attack prevention also facilitates prevention of typical TCP/IP security attacks such as TCP session hijacking.number and hence supports the 26. For comprehensive details on the basics of short range RF data communication. authorization and data availability [5]. 3. SYSTEM DESIGN 4. Most of the existing transit organizations like Johannesburg MetroBus use value stored contactless smart cards to facilitate both online and offline operation of the system. authentication. data has to be first encoded into suitable format by encoder. Access Point Name (APN).2. This was followed by the investigation and determination of the operation of GPRS network and GPRS modems for wireless communications. operators provide security measures such as data integrity. attacks such as denial-of-service and over-billing can be prevented [5]. Due to the fact that RF communications are susceptible to interference when two applications are operating at the same radio frequency. etc [6]. MIFARE card readers with integrated Wiegand to serial data converters are available at higher cost price. and then activate the PDP context.

The complete system hardware block diagram is exhibited in the figure 3. 5. The implementation of each subcomponent is explained. These three subunits formed the core components for mobile unit design. the following functionality is achieved: • The system initiates connection through GSM/GPRS with the Transportation Manager (TM) on system start-up and then stays online. . SYSTEM IMPLEMENTATION 5. The modem is powered with 12V from a bench power supply through a 500 mA fuse for short circuit protection. is used.1 HARDWARE SECTION Each component along with its associated circuitry was constructed and tested separately. CTRL44 ENCODER ATMEGA16 MICROCONTROLLER INPUT SWITCHES RED LEDS Figure 4: Location identifier illustration circuit.HSDPA) with higher data rates. To identify the embarking and disembarking zone locations of the commuters. The fully functional components were then integrated together.1. Vodacom GSM/GPRS network is used. On the other hand the microcontroller operates at Transistor-Transistor logic (TTL) levels of 5V to 0V for high and low. The FASSTRACK modem has embedded TCP/IP stack which is accessed through WIP open AT commands [12]. As portrayed in the figure 3. the Request to Send (RTS) and Data Terminal Ready (DTR) lines of the modems must be set from high to low. the short range RF communication system previously implemented [9].1 GPRS MODEM The class 10 GPRS FASSTRACK modem manufactured by WAVECOM is used as the engine to connect the device to the GPRS network. The voltage levels of RS-232 signal is -15V to +15V for high and low.2 DESIGNED SYSTEM STRUCTURE The system to fulfil the specified mobile unit functionality is structured as depicted in the figure 3. To convert the RS-232 voltage levels to TTL. For the microcontroller to initiate the communication with the modem. 4. Commuters scan contactless MIFARE card on the card reader to authenticate and initiate transaction processing Commuters balance inquiry is requested from TM through the already initiated GPRS The LCD displays the activities taking place within the mobile unit system Short range RF communications system sends the location identity of the relevant zone from the bus stop (location identifier circuit is portrayed in figure 4) to the mobile unit. 5. The modem accepts RS-232 serial input/output signals. however GPRS has lower implementation costs and its data rate are sufficient for the EFS application. 12V Power Supply Antenna GPRS Modem MIFARE Card Reader LM7805 Voltage Regulator MAX232 Microcontroller 16x1 Character LCD Module Voltage Divider • Ctrl44 RF Decoder Antenna RX2 RF Receiver • • • Figure 3: The system hardware block diagram 6-12V INPUT VOLTAGE TXD RF TRANSMITTER LM7805 5V VOLTAGE REGULATOR These functionalities are further elaborated in control algorithm in figure 5. MAX232 chip is used. The modem communicates with the microcontroller through Universal Asynchronous Serial Receiver and Transmitter (UART).

It is consist of up to 16 MHz processor. 6. The program code for the microcontroller is developed in C language using ImageCraft® development environment and the compiled code is loaded using AVR Studio.6 LCD MODULE CIRCUITRY A 16x1 character display LCD module driven by 8-bit data bus is used to display activities in the mobile unit. The output logic high of the receiver circuit was approximately at 5. 5. STK500 development board is used for the loading process and immediate testing. 5.06V whereas the input logic high of Atmega32 is approximately 5V.2 LOCATION IDENTIFIER ALGORITHM The location identifier control program continuously copies the input logic address from the input port and takes it out to the RF encoder and the display LEDS.1. The reader is powered with 12V from the bench power supply through a 500 mA fuse for short circuit protection. 5.2 SOFTWARE SECTION 5. 32 programmable I/O lines. The TX2 and encoder circuits are mounted on the location identifier circuitry board and are powered with 5V. 5.1 MOBILE UNIT CONTROL ALGORITHM Separate software modules dedicated for each hardware component were developed and tested on the hardware components to access functionality.2. voltage divider circuitry was introduced to bring the decoder logic levels down to approximately 4.3 MICROCONTROLLER 8-bit AVR Atmega32 microcontroller is used as the main processor for the mobile unit system. 5. The microcontroller is powered with 5V from the LM7805 voltage regulator. The LCD module provides an excellent additional functionality of visualising the step-by-step activities happening during hardware debugging. 5. SYSTEM TESTING The LCD module circuitry was designed first and the characters display function deployed to ensure consistent display of different types of characters. receiver (RX2) and 4-bit encoder/decoder (Control44 IC) (from the previous Taxi Route Identification System project [9]). Each component circuitry was tested for try joints and short circuits.1. The complete program code is given in appendix C and comprehensive control algorithm is given in appendix D. It was selected for the application because of its easily understood development environment and also because of its relatively large flash memory for program and data storage.4 SHORT RANGE RF CIRCUITS The RF transmitter (TX2). A 4-bit switch and LEDS are connected to the location identifier to demonstrate different zones input values. .1. 1024B of EEPROM. The RF receiver circuit mounted on the mobile unit circuitry board is powered with 5V.1. The output data format from the reader is Wiegand data through line D0 and D1. The program code module for each system component was first debugged using AVR studio debugger.5. The working modules were then individually loaded into the microcontroller and hardware debugging executed.5 LOCATION IDENTIFIER The main processor of the location identifier is 8-bit AVR Atmega16 microcontroller. As a result. a programmable USART and External Interrupt Sources [10].2 MIFARE CARD READER The classic ISO 14443-3 MIFARE serial number reader is used for scanning the serial number stored on the MIFARE contactless smart card (TransCard).8V. The program flow chart representing the events sequence execution is shown in figure 4. are used for location identification functionality. 32 Kilo Byes (KB) InSystem Programmable Flash. The other three input lines of the reader are used for controlling Green and Red LEDS and the buzzer. 2 KB of Static RAM (SRAM).2. The features of Atmega16 are the same as Atmega32 and the only difference is the 16 KB Flash memory and 512B of EEPROM available on Atmega16.1. configured in the continuous transmission mode.

The system components such as the MIFARE card reader and GPRS modem are relatively 7. Future developments should include the developments of the Client Terminal. Table 2: Data tariffs on Vodacom Network Component Cost MIFARE card reader (1) GPRS Modem (1) RF com modules (4 pieces) LCD module (1) Atmega32 (2) Accessories (approx) Total R2160.76 R300. The location identifier draws maximum current of 200mA. This could have been due to the fact that the card reader was faulty or the first memory sector of the MIFARE card was not factory programmed with a four digit HEX number as stated in the data sheet. However.00 R6718.30 R1760. The location identifier performance was evaluated within a short distance from the mobile unit and different input locations from the RF transmitter were obtained at the receiver circuit on the mobile unit without errors for repeated investigations. The system was run for a long time to ensure consistency and at 12V voltage supply.3 OPERATIONAL COST ANALYSIS Vodacom service provider charges 19c per megabyte (MB) sent or received. RECOMENDATATIONS It is recommended that value stored TransCards be utilized to facilitate both online and offline transaction processing. 7. 8. it was determined that the server closes connection after each it has received data and responded. Data from the mobile unit to the TM server is sent almost instantaneously.00 R462. The server responded by accept ‘A’ for enough funds or ‘R’ for insufficient funds. 7.START Initializes Devices expensive. One of the proposed sub-systems termed “Client Terminal” was terminated to eliminate the cost of purchasing extra GPRS modem and card reader. This signal was used to indicate through an external interrupt to the microprocessor that a card has been scanned. Solution: The Red LED line switches from high to low when the card is scanned.06 YES Send Fare and Commuter ID to TM through TCP/IP Calculate Commuter Fare Get 2 Zone ID from RF Module nd Create New Commuter Structure Free Commuter Stucture 4 Times Buzzer Figure 4: The general program flow chat Finally the sub-components were amalgamated and the entire system hardware and software reliability confirmed. as depicted in table below. The commuter ID stored on the card is 16 bit and for system testing a 16 bit HEX digit was sent to the server each time the card was scanned.2. Commuters accounts can be linked to their bank .2 OBSTACLES ENCOUNTERED 7. 7.00 R275. This will be beneficial for situations where GPRS network is down. Request Balance From TM Server Through TCP/IP Is Balance Enough? NO YES Connect to TM Server Through GPRS MAIN LOOP NO 1 sec Buzz YES NO IS A CARD SCANNED? Is the Commuter Already on Board? Get Embarking Zone ID from RF Module Solution: Only the most cost effective components with basic functionality were purchased. Furthermore.1 PERFORMANCE EVALUATION The MIFARE card is scanned effectively at a distance of 3 cm from the card reader. Also. so GPRS modem had to reconnect to server each time data to be sent is available. The table below shows the GPRS service billing by the service provider.1 COMPONENTS COST Problem: Cost is always the main constraint in system design projects. some of the components had to be ordered from overseas and this introduced additional lead time before the actual system implementation.2 MIFARE SMART CARD AND READER Problem: The output Wiegand data lines D0 and D1 were not functioning as stated by the Wiegand theory. SYSTEM ANALYSIS 7. some of the ordered components for this system arrived late.2. The GPRS modem connection time to the Transportation Manager (TM) server was evaluated at different times of the day and the maximum connection time was determined to be 5 seconds. the mobile unit draws maximum current of 400mA and 100mA at standby. This made the GPRS services charges to be negligibly small.48 R1760.

com/infocus/1729 Last Accessed 20 October 2007 [7] Zoreda. University of the Witwatersrand. José Luis. ACKNOWLEDGEMENT The author would like to acknowledge the following people.04 [5]GPRS Security Threats and Solution Recommendations http://www.com/dyn/resources/prod_documents/ 2503S. Private Bag 3.account to facilitate simpler and quicker account recharging. Smart cards.pdf Last Accessed 19 October 207 [2] ISO 14443 Contactless Identification Cards www. 2050. San Jose.pdf Last Accessed 16 September 2007 [3] Wiegand-to-RS-232 Converter http://www.co.circuitcellar.za/Products/Wavecom/Wavecom _Wireless_CPUs_July_2007. 1994.01 0.com/page. South Africa [10] Data Book for the ATmega32/32L.net/solutions/literature/white_paper s/200074. Hardening the TCP/IP stack to SYN attacks http://www.otiglobal.gsmworld.pdf Last Accessed 20 October 2007 [6] Mariusz Burdach. CONCLUSION The public transportation management system is design. Mercy Shuma-Iwisi. Table 2: Data tariffs on Vodacom Network Data sent/received Size (Bytes) Connection to TM Processing 50 commuters Transactions 1024 16384 Cost (Rand) 0.TAXI Route Identification System: Hardware Construction School of Electrical & Information Engineering.org/wiki/GPRS_Core_Network Last Accessed 18 September 2007 [12] Wavecom Based Maestro 100 Modem http://www. Johannesburg.com/StumpoPaperHouston.com/avr2004/DA3616. CA http://www. Mrs. guidance and her valuable assistance in obtaining the system components.html Last Accessed 16 September 2007 [4] Guidelines for IPv4 Addressing and AS Numbering for GPRS Network Infrastructure http://www. the project supervisor for her informative help. Short range RF is used to identify zones for distance travelled fare calculation method. The designed system is evaluated for performance and further developments of the system are suggested.juniper.pdf Last accessed 18th September 2007 [11]GPRS Core Network http://en.hidcorp. The system is used for electronic fare settlement in taxi industry.pdf Last Accessed 26 October 2007 9. Boston: Artech House.com/documents/ireg/ir40310.aptrex. Jeremy Holdcroft for sharing his knowledge and experience.pdf Last Accessed 20 October 2007 . implemented and evaluated.11.atmel. REFERENCES [1] Making a World Class Transit System a Reality http://www.php?page_id=21 Last Accessed 20 October 2007 [9] Mashego. The functionality of the system is demonstrated through the working prototype. Lehlohonolo R.trintel. The wireless communication between the mobile unit and the central server is achieved through the use of GPRS.com/objects/ISO%2014443%20WP%2 04. The commuters are issued with MIFARE contactless start card to facilitate secure authentication and transaction processing.wikipedia. Atmel Corporation.securityfocus. [8] MIFARE FAQs http://www. "8-bit AVR Microcontroller with 32K Bytes In-System Programmable Flash".

zip” can be downloaded from http://www.Location_Identifier.za .khems.Mobile_Unit.Appendix C The source code “C code .co.zip” and “C code .