Posts Tagged ‘Sensor Andrew Adapters’

t

What adapters do?

In Uncategorized on October 8, 2009 by salvadormrf Tagged:

In order to understand, what we can generalize, we need to know, what adpters do, and find common implementations (*) in adapters.

What adapters do? (publishers)

- create XMPP connection (*)

- read config settings (*)

- parse XML (specific for each type of sensor) (*)

- opens connection to device

- starts XMPP connection (*)

- starts an cycle

- get data from device

- prepares sox message (with device installation and transducers installation info as well sensor data values) (*)

- publish sox message (*)

Files: config.xml and device_kind.xml

config.xml(*) > information for connection and identification  (host, port, username, password, device id, …)

device_kind.xml > device specific informations (eg: serial port location, database, … )

###########################################################################

- also compiled sox libs and tools on mac os x server

—> installed macports as normal user ( info )

—> installed glib2 from macports (perl installation issue with owner > solution)

—> installed loudmouth lib

—> installed sox lib (osx shared lib compilation issues > solution)

—> installed cmd_line_tools (needs -lgcrypt -lglib-2.0  in Makefile)

- installed an bash script to publish minime server cpu temp  every 10 minutes.

sensor name: minime_cpu_sensor
sensor id: 001
event node: minime_cpu_temperature
publisher: salvador@openfire
host: hci.dme.uma.pt
port: 10223

Now we can subscribe to cpu temperature sensor data, as well  get last data from node. (by default is FIREFLY sensor packet)

Follow

Get every new post delivered to your Inbox.