Aspire :: OSGi Bundles :: OneWireProducer



This section describes the bundle for OneWire sensors

1 Context

The OneWire protocol is a proprietary serial protocol for communicating with low-cost iButton devices. A iButton had a globally unique 64 bits long IDentifiers and optionnally memory banks, sensors (thermometer, hygrometer), realtime clock, wo data loggers.. According to Maxim IC, over 175 million iButtons are currently in circulation and they are used in many applications such access control, door lock, guard tour, cold supply chain, ....

The OneWireProducer bundle registers one Producer service for each iButton connected to the bus managed by the OneWire adapter attached to the host (RS232,Parallel,USB).

2 Build

2.1 Sources

  • trunk/bundles/common
  • trunk/bundles/sensors

2.2 Instruction

  1. we must install the 1-Wire SDK for Java. this library is available for download from http://files.dalsemi.com/auto_id/public/owapi_1_10.zip
  2. we must install the library in your Maven repository with mvn install:install-file -DgroupId=com.dalsemi.onewire -DartifactId=onewireapi -Dversion=1.10.0 -Dpackaging=jar -Dfile=owapi_1_10libOneWireAPI.jar
  3. cd trunk/bundles/common/onewireapi; mvn clean install
  4. cd trunk/bundles/sensors/onewireproducer; mvn clean install

2.3 Extra

Windows DLL are provided in the "1-Wire Drivers" and can be added in the org.ow2.aspirerfid:org.ow2.aspirerfid.onewireapi. Change the Bundle-NativeCode directive in the pom.xml.
  1. adapterName=DS9097U on COM ports (could run without DLL ibtmjava.dll) -> product name DS9097U-9
  2. adapterName={DS9097U} on COM ports (required DLL Ib97u32.dll)
  3. adapterName={DS9097E} on COM ports (required DLL Ib97e32.dll)
  4. adapterName={DS9490} on USB ports (required DLL ib90usb.dll)
  5. adapterName={DS1410E} on LPT ports (required DLL Ib10e32.dll)

3 Configuration

You must configure the properties adapterName and port for your OneWire adapter (see http://www.maxim-ic.com/products/ibutton/products/readers.cfm). The default values are {DS9490} USB1.

4 Artifacts

The artifacts to deploy are
  • org.ow2.aspirerfid:org.ow2.aspirerfid.onewireapi
  • org.ow2.aspirerfid:org.ow2.aspirerfid.onewireproducer
Optionnally, the artifact provides a Felix shell command to inspect the OneWire devices and adapters.
  • org.ow2.aspirerfid:org.ow2.aspirerfid.onewireapi.cmd
-> ow help
ow prop                  : list the properties
ow list                  : list the available devices on the default adapter
ow list <name> <port>    : list the available devices on the default adapter
ow listAll               : list the available devices on all adapters
ow adapters              : list the available adapters
ow help                  : display this help

-> ow list Adapter: {DS9490} Port: USB1 BD000801A332FA10: DS1920 (DS18S20) Digital thermometer measures temperatures … 830000002C575881: DS1990A (DS2401,DS2411) 64-bit unique serial number 27000000CD3B8D2D: DS1972 (DS2431) 1K-Bit protected 1-Wire EEPROM.

-> ow list {DS9490} USB1

5 Link

iButton web site http://www.maxim-ic.com/products/ibutton/ibuttons

5.1 Starter kit

if you want to develop with onewire devices, you need as least one adapter (DS9490 is fine), one connector (DS1402D-DR8 is fine) and some iButtons.