Device Profile: Embedded Linux powered RFID tunnel readers
Feb 27, 2004 — by LinuxDevices Staff — from the LinuxDevices Archive — 56 viewsMagellan Technology of Sydney Australia develops, licenses, and manufactures high speed, orientation-insensitive, ISO-compliant RFID systems, a number of which are based on embedded Linux. RFID, or Radio Frequency Identification, is a wireless means of reading and writing data from/to inexpensive RFID chips that can be attached to or embedded in articles being tracked. RFID is intended as a work-saving replacement for bar-code scanning, and is expected to gain market traction in 2004, in part due to mandates for adoption set by Walmart, the US Department of Defense, and others.
Embedded Linux scans checked baggage at an unidentified airport
Current Magellan products based on embedded Linux include the MTRP-1080, MTRP-6060, and MSTRP-5050 RFID tunnel readers. Magellan's smaller handheld RFID readers are currently based on microcontrollers, and must be attached to an external PC.
Magellan's partners and licensees include Infineon Technologies, Rafsec, Hoeft & Wessel, and Scanology in Europe, and Nippon Signal and Marubeni Corporation in Japan.
Magellan VP of Software Jeff Gray notes, “The Walmart project is primarily concerned with tagging at the box level. We hope that we can prove viability for tagging at the item level. There are many instances where mixed lot boxes are used, so a box level tag becomes useless.”
Magellan's RFID technology “uses a command and reply bit rate many times faster than all other RFID systems,” according to Gray. Magellan's Phase Jitter Modulation (“PJM”) products are the only products available that provide “the very advanced functionality” specified in ISO 18000 Mode 2 (FDIS), according to Gray.
According to Gray, PJM systems are theoretically capable of identifying and reading 50 words of data from 500 tags as a continuous operation in 0.944 seconds. “Note that this is the protocol speed,” he adds. “Real world systems have some processing overhead.”
Asked for examples of Magellan RFID systems in use today in the real world, Gray replies, “A diamond wholesaler is using them to manage inventory, tagging diamonds in small envelopes. They had a problem where they knew they had a particular diamond, but couldn't track who [had it].”
And, notes Gray, “We have a number of proof of concept systems in the medical industry, for tracking things like tablets & blood bags, which are carried in bulk.”
Magellan MTRP-1080 and MTRP-6060 can read tags separated by at least 5cm
Magellan provides two different families of read and write RFID tags and readers. ItemTag is designed for reading and writing to tagged articles where the articles are separated by a minimum of five centimeters. StackTag is designed for reading and writing to tagged articles where the articles are not separated, and where the tags or labels can even touch exactly, as with stacks of documents, gaming chips, syringes, and more.
Magellan MSTRP-5050 can read tags stacked against each other
StackTags are typically used for tracking, tracing, and inventory control of tightly stacked articles ranging from frozen meat products and medical supplies (e.g blood) to important papers such as legal, defense, or medical files, and valuable articles such as jewellry.
ItemTags are typically used for conveyor belt applications such as airline baggage and courier parcels where articles are separated for sorting. ItemTags are also used for article surveillance and authentication.
Conveyor-mounted tunnel reader on airport runway
What's inside the box?
Magellan currently builds its Linux-based tunnel readers around AMD 586 processors, but Gray says Magellan plans to build future, smaller readers around Atmel ARM or Motorola Coldfire chips with onboard ethernet and USB support.
Magellan's Linux-based tunnel readers contain 32MB of SDRAM, because smaller SDRAM chips have actually become more expensive than smaller chips. However, “only 5MB is used for the Linux system to boot and start all daemons,” Gray says.
Similarly, while the “boot device” is a 32MB Flash memory chip, only 7MB is needed for the system, according to Gray. “As with RAM, it is cheaper to buy Flash in readily available sizes, which means we end up with a good amount of free space for data logging, etc.”
Ethernet provides the main communications link between the readers and connected PCs. A serial port is available for console output so boot messages can be viewed, and a serial console login prompt is provided. USB is planned for future, smaller readers.
Software side
Magellan built its Linux implementation in house, because, Gray says, “When we started the work three years ago, none of the commercial embedded Linuxes suited us. And, several staff members had extensive previous experience with Linux,” notes Gray.
“During the development process, we connected our readers to a file server with NFS, then connected to the readers with telnet from our desktop PCs. From here, we could edit and compile our source on the file server and run immediately on the reader. This made for a very fast and transparent development process,” said Gray.
Magellan's current Linux implementation is based on a 2.2.17 kernel, “because it's small, stable, and fulfills our current requirements. We have not upgraded the operating system in over a year, but it is very stable and easy to work with,” notes Gray.
Magellan does have a 2.4-series Linux implementation in the pipe, however, set to roll out with a future round of hardware upgrades. “The kernel will go to the current 2.4.x, [and] system libraries and other components have been updated to more recent versions. SSL libraries have been included so that a secure version of the system can be built.”
Magellan's Linux-based tunnel readers thus far have not included a display interface beyond the serial console; however: “If we were to build a reader with a display, we would use Qt/Embedded,” notes Gray.
Another interesting open source application is busybox, which, notes Gray, now includes tinylogin, the ash
shell and the vi
editor.
Magellan's RFID application is based on Python, and so a custom build of Python has been installed. PyQt provides a basis for end user application development, in conjunction with the BlackAdder IDE (Integrated Development Environment).
Application upgrades are made through an FTP server. Administrative changes, such as network settings can be done through a serial port or through telnet. (A future secure version will offer more secure interfaces, using SSH and SCP instead.)
Gray says Magellan “seriously investigated” using uClibc, “but until very recently, it was not capable of supporting all we required, such as libraries depending on shared libs. If we had to build an ultra small system, we would almost certainly use this library to shrink memory requirements.”
Why Linux?
According to Gray, Magellan chose to use Linux as part of a broader strategy to support network-based application sockets in order to achieve the greatest possible flexbility. “We made the decision early on to [provide an] application interface [based on a] socket, and use plain text for all data formatting. This idea was inspired by the way many Internet services, such as DNS, mail, and Web work. It removes issues of programming language, operating system or CPU dependence, and makes the system easy enough to use with a telnet client.”
“Languages without socket support, such as Visual BASIC, have to find a third party socket component,” adds Gray, “But that serves them right for using such a language.”
Gray continues, “Given this decision, we needed an embedded OS that supported network based applications, Linux was much more advanced in support of protocols and hardware than anything in the proprietary world at the time.”
Furthermore, “Having such an advanced system in such a small footprint has meant that we were not dependant on a third party if we had to change our network interface or connect to an unusual network protocol.”
Gray praises the variety of development tools available on Linux. “Using Linux gave us access to many excellent development and debugging tools that have improved our flexibility and quality of product.”
Biggest challenge
Device driver development posed the most challenging aspect of the project, according to Gray, especially before the company learned that “it is easier to work on the device driver using a simulation of the hardware as much as possible before trying to debug both hardware and device driver at the same time.”
Another challenge was in predicting system performance. “A standard Linux kernel is not very good at real time task switching. But several improvements in recent years have meant it is getting a lot better. It is important to be aware of the performance you need from an embedded Linux system, and make sure that the distribution you are using is capable of the performance you need,” notes Gray.
Retrospective
In general, Gray reports that Magellan is pleased with its decision to use Linux. “We are hugely glad that we chose Linux as the base for our development. We are planning to expand our readers in future in many different areas, and it is planned to include embedded Linux [wherever there is] enough memory to use it.”
Gray continues, “Recent price to performance changes have made it increasingly easy to build Linux capable hardware. With an ARM based microcontroller with onboard Ethernet costing US$16 in small quantites, it is possible to add Flash and SDRAM to this to build a functional Linux system for around US$30. Unless the product being built is extremely cheap, it is very easy to justify this cost in terms of increased functionality and flexibility.”
Gray predicts a bright future for embedded Linux. “There will always be a need for tiny embedded systems that Linux cannot fit on, but the flexibility, stability, source code access, and gradually improving real time performance makes it difficult to compete with. Only niche areas will be able to survive in the long term against such a capable platform.”
Gray continues, “There are many excellent commercial embedded products, but there are also a great many with out-of-date designs, limited hardware and networking support, and sky high pricing. Linux has forced all of these products to keep up, and in doing so has improved the embedded market for all end users, whether they use Linux or not.
“Not having access to the source code in most commercial real time systems is a huge limitation on being able to build customised systems and understanding details of functionality. We have a system, where every component has been built with exactly what we want on it.
“As well as using entirely Open Source products for our distribution, we have released all source code to our application to all licensed manufacturers and users. This means that they can create customised versions of the application if they want to change the hardware. Also, they are not dependant on any company remaining around forever (not that we have any plans to disappear) to support the product.
“From our point of view, [Linux] gives our customers control over the product to a degree they do not get with closed source applications. It is also a way of treating them with respect, where closed source products are a supplier's way of telling you they don't trust you.”
This article was originally published on LinuxDevices.com and has been donated to the open source community by QuinStreet Inc. Please visit LinuxToday.com for up-to-date news and articles about Linux and open source.