Saturday, March 29, 2014

Communicating with Ambient Orb via Serial Port

Pins on the back of ambient
http://www.ambientdevices.com/developer/DIYSerialDeveloperBoard.html


Powered by PIC 18f242 CPU with 16K bytes ROM and 768 bytes RAM.

Physical Connection

pin 1 is on the left looking at it from the back

Pin 1 Vunreg - 11 volts DC from power transformer
Pin2 MCLR - used to reset device for programming. Leave unconnected
Pin 3 PGD - used for programming. Leave unconnected
Pin 4 PGC - used for programming. Leave unconnected
Pin 5 RS-232 RX (TTL level signal)
Pin 6 RS-232 TX (TTL level signal)
Pin 7 Ground

RS-232 Parameters

The serial port connects to the orb with the following fixed parameters:

  • 19200 Baud
  • 8 data bits
  • no parity
  • 1 stop bit
  • no flow control

Sample Script
  1. Install perl
  2. Install serial port library for perl with
    apt-get install libdevice-serialport-perl
  3. Download orbtest.pl
  4. Change the tty port to match that created when you plugged in your USB-->serial cable.
Bluetooth Setup
Sparkfun BlueSmirf

connect with Hyperterm
+++ to go to command mode within 60 seconds of start
su,19 to set the serial port baud rate to 19200 for ambient device
sy,0004 for standard power 12db
sy,fff8 for 0db
o shows settings
gy shows current power
sn,<new name> to set the name
--- to leave command mode



1 comment: