You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Hopefully attached is a pdf that will likely be further updated as we go on.   The word doc is in the usual project doc dir.: MoteOpsHints.pdf

METCRAXII “Mote” Hints

Contents

Mote Setting Defaults:1

How-To Command/Interact with a Specific V2.4 Soil/Rad Xbee Radio Motes:1

METCRAXII: Rad/Soil Mote Commands V2.4:2

METCRAXII: Serial Forwarding Mote:3

METCRAXII: Power Monitor Mote:4

HOW-TO: Change Mote Xbee Radio’s.5

The Wisard ‘motes’ come in 3 flavors for MetcraxII: Soil/Rad-XbeeWireless data sampling; Serial-Forwarding for crater barometer/csat’s; Power Monitor.    The basic command sets are shown below:

Mote Setting Defaults:

If the ‘eeinit’ command is used, the project defaults are reprogrammed into the eeprom which controls operating parameters.

Low Battery Voltage Monitor:           disabled (vm=0).

GPS:                                                    disabled on the serial forwarding motes in crater (2baro’s and 2csats)

rad/soil gps sync rate=2hours (gr=7200), timeout=1min (gto=60), failed retry rate=30min (gfr=1800)

Primary Output Port                           pp=radio (pp=1)

Message Output                                  wisard mode (mp=0) messages

Local Data Storage                             disabled (fsr=0)

Sampling Mode                                   Self-Timed (md=0)…Don’t change this!

How-To Command/Interact with a Specific V2.4 Soil/Rad Xbee Radio Motes:

By default all commands are sent by a base station radio to all remotes.  You can address a specific mote only by one of two ways:

1)       Don’t Do This!:                    Reprogram the base Xbee radio (or equivalent) to only talk with your target.

2)       Do This:                                 #xxcmd where xx=moteID, and ‘cmd’ is one of the above commands.

For example: ‘#17dr’ or ‘#2xb=pl’ or ‘#4eeupdate’

FLR: >rs 2             ids = 1,2,17           Unless they’re changed!

NEAR: >rs 1         ids = 3,8,10

FAR: >rs 2             ids = 4,22

 

METCRAXII: Rad/Soil Mote Commands V2.4:

Note: Cmds with ‘=’ option can be reset with a new value
Note: All values are stored in eeprom and reloaded at runtime. If you change one or more and then ‘eeupdate’ they will be used both immediately and at any reboot.  Exceptions are rxb,hb,st,jd and ‘on/off’

Sampling Rates:

‘dr’ ‘dr=’
‘sp’ ‘sp=’
‘sn’ ‘sn=’
‘sx’ ‘sx=’

Data Sampling rate in seconds
Power message skip count = dr*value
Serial# message skip count = dr*value
XbeeStatus message skip count
Skipcount 0=Disabled, 1=Every Message

Operating Modes

‘md’ ‘md=’
‘id’ ‘id=’
‘mp’ ‘mp=’
‘pp’ ‘pp=’
cache cache=

0=Self-Timed Mode (Default)1=Xbee-Sleep
MoteID
Output: 0=Wisard, 1=DSM printable,2=Ascii
Primary Output Port: 0=rs232, 1=xbee
Show/Set  message caching count

Local File

fsON/OFF
fsr  fsr=

 
Rate in seconds to cycle (ie flush) local storage fil.
fsr=0 disables local data storage

Batt Monitor
 
 

‘vm’ ‘vm=’
‘vl’ ‘vl=’
‘vh’ ‘vh=’
‘vs’ ‘vs=’

vm=1 MonitoringON,    vm=0 OFF
vl=7000     Turn MoteOps off at 7vdc
vh=12300 Turn back on at 12.3vdc
when off ‘sleep seconds’ before re-testing

EEPROM

‘eecfg’
‘eeupdate’
‘eeinit’
‘eeload’

report current operating settings
write eeprom with current settings
initialize default settings
read/load existing eeprom contents

Xbee Radio:

‘xb=’
 
‘xr’ ‘xr=’ ‘hb’
‘xs’
‘rxb’
‘xbdl’,’xbch’,’xbid’’xbst’,’xbsp’
‘xv’

Send specific command to xbee: such as ‘xb=pl’ for power. To reprogram a new  value ex: ‘xb=pl2’ or ‘xb=dl12345678’
Xbee automatic reset rate unless ‘hb’ heart-beat rcvd
Xbee status
Reset Xbee
dl=destination, ch=chan: values setup in eeprom
st=wake time (7D0=2sec) sp=sleep time(12C=3sec)
Do This to Confirm/Reprogram xbee with above values

GPS / Timing:

‘gpsON/OFF’
‘gr’   ‘gr=’
‘gto’  ‘gto=’
‘gfr’  ‘gfr=’
‘gnl’ ‘gnl=’
‘st’ ‘ st=’
‘jd’   jd=’
‘bf’  bf=’
‘ba’  ‘ba=’

 
How often ‘gpsON’ to set Date/Time (secs)
Timeout Seconds if no lock acquired
Retry Wait time (secs) if no lock
#of sequential valid messages to confirm lock
Show/Set time of day ‘hhmmss’
Show/Set Julian date
Special use: Bresenham Freq. (~8000000) Adjust value

 

‘?’ ‘reset’ ‘reboot’

Print command list, reset cpu

White-Button Use

1
2

scan for any attached  I2C sensors
Toggle Output port between radio/Console

LEDs

Startup
 
 
 
Normal Ops
Command ingest
 
 
GPS
 
WhiteButton

Normally 3 blinks of either: green-led=output is radio, red=output is console; then 7 quick blinks before boot (sometimes other leds come on and when xbee is the output there is a delay period before ‘boot’)
1-sec green led heart-beat, and red led blink at the ‘data-rate’
Orange led (above pic) comes on when a command is being ingested from the ‘base radio’ or the console which-ever is active, and goes out upon command <cr> termination.
Yellow led (under microSD)blinks when message received and blinks several times when it syncs, then goes out.
Org blinks for # of presses, then if swapping output ports the green or red will blink 3 times.


 

METCRAXII: Serial Forwarding Mote:

Note: Cmds with ‘=’ option can be reset with a new value
Note: All values are stored in eeprom and reloaded at runtime. Thus if you change one or more and then ‘eeupdate’ they will be used both immediately and at any reboot.  Exceptions are rxb,hb and ‘on/off’
NOTE: by default ALL MOTE COMMANDS ARE DISABLED and it is in ‘pass-through’ mode. Thus when you connect, you’ll be talking with the serial sensor itself.  To enable these commands use the hidden escape:
         ‘esc-esc-esc’ to toggle the command-mode on/off.

Sampling Rates:

‘dr’ ‘dr=’
‘sp’ ‘sp=’
‘sx’ ‘sx=’

Data Sampling rate in seconds
Power message skip count = dr*value
XbeeStatus message skip count
Skipcount 0=Disabled, 1=Every Message

Operating Modes

 ‘id’ ‘id=’
‘mp’ ‘mp=’
‘pp’ ‘pp=’
‘delay’ ‘delay=’

MoteID
Output: 0=Wisard, 1=DSM printable,2=Ascii
Primary Output Port: 0=rs232, 1=xbee
Seconds of delay before starting up.  This was done to allow the sensor and bluetooth radio to boot before forwarding chars begins

Local File

fsON/OFF
fsr  fsr=

Any questions…?
Rate in seconds to cycle (ie flush) local storage file

EEPROM

‘eecfg’
‘eeupdate’
‘eeinit’
‘eeload’

report current operating settings
write eeprom with current settings
initialize default settings
read/load existing eeprom contents

Xbee Radio:

‘xb=’
 
‘xr’ ‘xr=’
‘xs’
‘rxb’
‘btradio’

Send specific command to xbee: such as ‘xb=pl’ for power. To reprogram a new xbee value ex: ‘xb=pl2’ or ‘xb=dl12345678’
Xbee automatic reset rate unless ‘hb’ rcvd
Report Xbee status
Reset Xbee immediately
Special Use Only while using Console Port!: passthrough directly to the radio.  You then need to do the timing, special ‘+++’ ‘atxx’ etc.

GPS / Timing:

gpsON/OFF
gr   gr=
gto  gto=
gfr  gfr=
gnl  gnl=

Any questions…?
How often ‘gpsON’ to set Date/Time (secs)
Timeout Seconds if no lock acquired
Retry Wait time (secs) if no lock
#of sequential valid messages to confirm lock

 

‘?’
‘reset’ ‘reboot’

Print command list
reset cpu

White-Button Usage

1
2
3

scan for any attache  I2C sensors (limited use for forwarder!)
Toggle Output port between radio/Console
Tobble Fake Message Simulator On/Off (so you don’t need a sensor attached to try out the radio link)

LEDs

Startup
 
Normal Ops
 
Command ingest
 
 
GPS

A long series of 1-sec blinks will last for the ‘delay’ time mentioned above.  Then ‘roughly’ 7 blinks and the
1-sec green led heart-beat, and red led blink at the ‘data-rate’ when sampling occurs (yes the forwarder is taking power readings at ‘dr’)
Orange led (above pic) comes on when a command is being ingested from the ‘base radio’ or the console which-ever is active, and goes out upon command <cr> termination.
Yellow led (under microSD)


Because the Serial Forwarding Motes in MetcraxII are BlueTooth based radios, to talk with them individually, the command ‘#’ prefix shown above is superfluous.   Instead the interaction is entirely up to the DSM virtual serial port connection.  For that you must know what the friendly name of its BT-radio.   With the DSM / Nidas software running, and logged into the DSM:

>rserial btspp:name            This must be a known name in the config and in the radio.

METCRAXII: Power Monitor Mote:

The Power Monitor Board designed and built in 2013 was based upon a PIC18F2520, the same as used on the original Version 1 motes.  For convenience the initial implementation of the command set was similar to V1 Motes, not the V2.4 soil/rad devices.
Note: Cmds with ‘=’ option can be reset with a new value

Sampling Rates:

‘dr’ ‘dr=’
‘sx’ ‘sx=’

Data Sampling rate in seconds
XbeeStatus message skip count
If skipcount=0 Disabled
If skipcount=1 Every msg (ie no sensor data)

Operating Modes

 ‘id’ ‘id=’
‘mp’ ‘mp=’
‘pp’ ‘pp=’
‘mt’
‘mx’

MoteID
Output: 0=Wisard, 1=Ascii
Primary Output Port: 0=rs232, 1=xbee
Self-Timed Mode (Default)
Xbee-Sleep Mode
BEWARE: unlike version2+ once in xbee mode you can’t hit the button, only power cycle and/or use a properly setup xbee ‘base’

Calibration Offset/Gain Settings
 
 

‘vbg’ ‘vbg=’
‘vbo’ ‘vbo=’
‘ilg’ ‘ilg=’
‘ilo’ ‘ilo=’
‘ilt’ ‘ilt=’
‘ipvg’ ipvg=’
‘ipvo’ ‘ipvo=’
‘ipvt’ ‘ipvt=’

Battery Voltage circuit    Gain,
                                         Offset
Load Current circuit        Gain,
                                         Offset,
                                         Temperature Coefficient Charging Current circuit Gain,
                                         Offset,
                                         Temperature Coefficient

EEPROM

‘ew’
‘ei’
‘er’

write eeprom with current settings
initialize default settings
read eeprom contents

Xbee Radio:

‘xb=’
‘xr’ ‘xr=’
‘hb’
‘xs’
‘rxb’

Send command to xbee: ‘xb=pl’ for power
Xbee automatic reset rate unless ‘hb’ rcvd
Send Xbee a ‘heart-beat’
Report Xbee status
Reset Xbee immediately

Timing:

‘st’  ‘st=’
‘jd’  ‘ jd=’
‘bf’  ‘bf=’ ‘ba’ ‘ba=’

Show/Set time of day ‘hhmmss’
Show/Set Julian date
Special use: Bresenham Freq. (~8000000) and Adjust value

 

‘?’
‘reset’ ‘reboot’

Print command list
reset cpu


These motes in METCRAXII were initially setup with a wired link into a DSM port and are mounted in the battery boxes.   They can be swapped over to Xbee radios by removing the rs232 module and swapping in a xbee radio pre-programmed to work with the base radio it will be interacting with.

FAR:      >rs 7

NEAR:   >rs 17 (low) >rs 18 (up)

RIM:      >rs 14 (low) >rs 16 (up)

FLR:       >rs 8



HOW-TO: Change Mote Xbee Radio’s

If a a radio goes bad, or more likely a mote/xbee need to be swapped in to a different BASE-Xbee receiver, then the xbee radio must be either swapped in or have its settings changed.    In either case you need to know the Base Radio’s values (labeled on the box):

1)     Serial number, low number: ‘sl’ in the base xbee, used in the ‘dl’ setting of the client xbee.

2)     Channel number: ‘ch’

3)     Node ID: ‘id’

All other parameters should be ready to go in our radios.   The base broadcasts to all clients ‘dl=0000’ and the clients send messages to the base radio ‘dl=xxxxxxxx’.

If the radio is ok but the mote is bad: you can remove the xbee from the old mote and put it in the new one.  If you do that the default eeprom ‘radio settings’ in the mote will probably be different but that is ok because the radio will already be setup correctly; just don’t use the ‘xv’ command!

Otherwise if you putting in a new mote with new radio (ie moving it) then you need to change the xbee and mote settings.  This can be awkwardly done over the air but the best is to use the mote console port:

1) Connect console cable between Mote-PC.   Start serial comm program (minicom,procomm,rserial): 38400bps = Rad/Soil Motes,   9600bps=SerialForwardingMote

2) Power Up Mote            You should see 3 short green blinks indicating stdio is going to the xbee port.

3) 2x White Button           Toggles stdio to the console port.   You should see 2 quick org. blinks indicating it saw the 2 button presses.

4) md=2                            If using minicom/procomm.   This puts the mote in plain text mode so you can see the output.   In rserial the md=0 ‘wisard’ mode is ok/best.

5) xbdl=xxxxxxxx            where ‘xxxxxxxx’ is the BaseRadio’s low serial number (hex)

6) xbid=x                          where ‘x’ is the BaseRadio’s id.

7) xbch=xx                        where ‘xx’ is the BaseRadio’s channel number (hex)

8) xv                                  The mote will reprogram the xbee radio with the above numbers and give you a status report.

9) id=xx                            Do this for the DSM injest if you’re swapping in a new mote.   You must know the old mote number.   The alternative when swapping is to change the dsm’s ‘xml’ for the new id, and all the associated adjustments in base, etc.

9) md=0                            puts the mote in wisard output mode.   If you leave the md=2 (or 1) then the next command will cause it to boot in the wrong mode and cause dsm problems.

9) eeupdate                       This stores the above values in the mote’s eeprom.

10) reboot                          Or press reboot button, or cycle power to restart with the new setting

11) Check the settings/results and that the dsm is still getting data, etc.

The xbee radio settings can be adjusted or viewed also by using the command ‘xb=yyy’ including ‘over the air.’  Be careful not to change one of the 3 values above over the air or else you will lose radio contact.  Some examples

1) xb=pl                             shows xbee’s power level

2) xb=pl2                           changes xbee’s power level.

3) sx                                  reports various xbee status values

4) xb=sl                             shows xbee’s serial number

5) xb=dl                            shows xbee’s destination serial number

6) xb=xxxxxxxx                changes xbee’s destination destination serial number (you can shoot yourself in the foot if using this over the air).<!-- /* Style Definitions */ table.MsoNormalTable

Unknown macro: {mso-style-name}

-->

  • No labels