background image

         

WiFly GSX

 

   

 

WiFlyGSX-um.pdf  11/11/2009

 

 

 

www.rovingnetworks.com 

[email protected] 

Phone 408-395-6539 

 

17 -

 

 
 
 

7

 

STATUS Commands    

 
These commands begin with “show”, and they return the current values of variables in the system. 
In some cases, for example IP addresses,  the current values are received from the network, and 
may not match the stored values. 
 

show  battery 

Displays current battery voltage, (only valid for Roving battery powered product like 
the RN-370 and temperature sensors)  

 

show  connection 

Displays connection status in this HEX format:  8XYZ       

 
 Bit 
location 

13-16 

9-12 

 0-3 

Function 

fixed 

channel 

DNS found 

DNS server 

Authen 

Assoc 

TCP status 

Value 

1-13 

1=resolved 

1= 
contacted 

1= OK 

1=OK 

0= Idle, 
1=Connected 
3= NOIP 
4= Connecting 

    

 
show  io 

Displays IO pin levels status in this HEX format:  8ABC 

 

Example:  

show i

 returns 8103 indicates pins 0, 1 and  9 high level. 

 

show  net 

Displays current network status, association, authentication, etc.  

 

show  rssi 

Displays current last received signal strength. 

 

show  stats 

Displays current statistics,  packet rx/tx counters, etc.  

 

show  time 

Displays number of seconds since last powerup or reboot 

 
show q <0-7>

  Display the value of the an analog interface pin from 0 to 7.  The value returned will 

be in the format  8xxxxx where xxxxx is voltage in microvolts sampled on the 
channel you request with the 8 in front as a start marker. 

 

show q 0x1<mask> 

Displays multiple analog interface values at once.  The channels displayed is 

controlled by a bit mask which is proceeded by a 0x1xx

 

where xx mask is the bit 

mask of the channels. For example, to read channels 0,1, and 7, send: 

 

 

 

show q 0x183     

 

 

 

 

Which returns  8<chan0>, 8<chan1>, 8<chan7>, \r\n  

Summary of Contents for WIFLY GSX

Page 1: ...15 October 16 2009 Copyright 2009 Roving Networks Inc All Rights Reserved The contents of this document can be changed by Roving networks without prior notice and do not constitute any binding undertakings from Roving networks Roving Networks is not responsible under any circumstances for direct indirect unexpected or consequent damage that is caused by this document ...

Page 2: ...ake on Sensor Input 21 10 3 Wake on UART 21 10 4 UART Receiver RTS CTS Hardware Flow Control 21 10 5 Setting GPIO direction Alternate Functions and Disabling LEDs 22 10 6 Setting Debug Print levels 24 10 7 Using the Real Time Clock Function 25 10 8 Using the UDP Broadcast function 26 11 Joining Networks and Making Connections 27 11 1 Associate with a network access point 27 11 2 Making Connections...

Page 3: ...ta control interfaces 10 general purpose digital I O 8 analog inputs Real time clock for wakeup and time stamping data logging Accepts 3 3V regulated or 2 3V battery with on board boost regulators Supports Adhoc and Infrastructure mode connections On board ECOS OS TCP IP stacks Wi Fi Alliance certified for WPA2 PSK FCC CE ICS certified and RoHS compliant Features Host Data Rate Up to 2 7 Mbps for ...

Page 4: ...esult Notes 1 The Sensor inputs SENS0 7 are extremely sensitive to over voltage Under no conditions should these pins be driven above 1 2VDC Placing any voltage above this will permanently damage the radio module and render it useless 2 Placing 5VDC or any voltage above 3 3Vdc into the VDD pins of the module will permanently damage the radio module 3 Placing 3 3Vdc into the PIO s while they are se...

Page 5: ... at http www rovingnetworks com support teraterm zip Type on in the terminal emulator You should see CMD returned to you This will verify that your cable and comm settings are correct Most valid commands will return an AOK response and invalid ones will return an ERR description To exit command mode type exit cr NOTE You can enter command mode locally over the UART interface at any time when not c...

Page 6: ...n check IP address of your Windows computer by running the ipconfig command in the command window If connected this command will show you the IP address and net mask for your computer The IP address assigned by Auto IP must be on the subnet 169 254 1 X otherwise the WiFly GSX module will not be accessible NOTE If your machine has both a wireless and wired interface hardware you will need to disabl...

Page 7: ...ATUS COMMANDS See what is going on with the interface IP status etc ACTION COMMANDS Perform action such as scan connect disconnect etc FILE IO COMMANDS Upgrade load and save configuration delete files etc NOTE You must save any changes made or the module will load the previous settings upon reboot or power up When the system boots all configuration data is loaded into RAM variables from the file c...

Page 8: ... hello heartbeat message is sent The default address is 255 255 255 255 set broadcast interval value sets the interval at which the hello heartbeat UDP message is sent Interval is specified in seconds The value is a mask that is compared to a free running seconds counter For example if interval 0x7 a packet will be sent every 8 seconds The minimum interval value is 0x01 every 2 seconds and max val...

Page 9: ... of 1 millisecond intervals after the last UART byte is received before the data is sent over Wifi 1 is the minimum value Default is 10 10 milliseconds Setting this value to 0 will disable forwarding based on time delay 5 4 DNS Parameters set dns address addr sets the IP address of the DNS sever This is auto set when using DHCP and needs to be set in STATIC IP or Auto IP modes set dns name string ...

Page 10: ...eserved for future use set ip flags value Set IP related advanced functions Value is a bit mapped flag register Default 0x7 Bit Function 0 TCP stack copies RX buffer before sending 1 Bypass Nagle algorithm and use TCP_NODELAY 2 TCP application level single retry enabled 3 RETRY multi retries 4 times 4 DNS host address caching enabled 5 ARP table caching enabled 6 Reserved 7 31 Reserved set ip gate...

Page 11: ...UDP The current value can be shown with the get option or show deviceid commands Max string size is 32 bytes The default is WiFly GSX set opt password string TCP connection password Used to challenge the remote device to authenticate the connection When set all incoming connections will be challenged and the first characters sent must match the stored password or the connection will be closed When...

Page 12: ...wake on 0 3 Bit mapped value 0 disables set sys wake secs sets the auto wake timer 0 disables See section 10 1 for more details on using system timers 5 9 TIME Server Parameters set time address addr sets the time server address sNTP servers set time port num sets the time server port number Defaults to 123 which is almost always the sNTP server port set time enable value Enable or disable fetchin...

Page 13: ...n 0 NOECHO disables echo of RX data while in command mode 1 Reserved for future RAW mode protocol 2 Reserved for future Multipoint protocol 3 Enable Sleep on RX BREAK signal set uart tx 0 1 Disables or enables the TX pin PIO10 of the UART Disable will set PIO10 to an INPUT with weak pulldown NOTE Due to an issue in the UART hardware the UART does not support even or odd parity 5 11 WLAN Parameters...

Page 14: ... for the access point with the strongest signal The channels searched can be limited by setting the channel mask 3 Reserved Not used 4 Create an Adhoc network using stored SSID IP address and netmask Channel MUST be set DHCP should be 0 static IP or set to Auto IP with this policy unless another Adhoc device can act as DHCP server This policy is often used instead of the hardware jumper to creat a...

Page 15: ... use 1 4 is the valid range Example set w n 2 sets the default key to 2 set wlan phrase string sets the passphrase for WPA and WPA2 security modes 1 64 chars The passphrase can be alpha and numeric and is used along with the SSID to generate a unique 32 byte Pre shared key PSK which is then hashed into a 256 bit number Changing either the SSID or this value re calculates and stores the PSK If exac...

Page 16: ... Default is 1460 bytes 6 GET Commands These commands begin with get They display the current values get adhoc display all adhoc settings get broadcast will display the broadcast UPD address port and interval get everything displays all configuration settings useful for debug get com display comm settings get dns display DNS settings get ftp display FTP settings get ip display IP address and port n...

Page 17: ...4 Connecting show io Displays IO pin levels status in this HEX format 8ABC Example show i returns 8103 indicates pins 0 1 and 9 high level show net Displays current network status association authentication etc show rssi Displays current last received signal strength show stats Displays current statistics packet rx tx counters etc show time Displays number of seconds since last powerup or reboot s...

Page 18: ...can list that is returned from the scan command If network is security enabled you must set the pass phrase with the set wlan phrase command prior to issuing the join command leave disconnects from currently associated Access Point open addr port opens a TCP connection to the given IP port and address If no arguments are provided the device will attempt to connect to the stored remote host IP addr...

Page 19: ...by synchronizing with the time server specified with the time server parameters see section 5 9 This command sends a UDP time server request packet 9 FILE IO Commands del name num Deletes a file Optional num will override the name and use the sector number shown in the ls command load name Reads in a new config file ls Displays the files in the system save Saves the configuration to config the def...

Page 20: ...2 minutes you would set the timers as such set wlan ssid my_net set wlan passphrase my_pass set sys sleep 30 set sys wake 90 save reboot UDP sleep and Connection timers There is another timer than can be used to put the device to sleep In UDP protocol mode the autoconn timer is used as an auto sleep timer Upon the start of transmission of the first UDP data packet this timer will count down set sy...

Page 21: ...0 3 Wake on UART When the module is in sleep mode the UART itself is disabled However wake on UART can be accomplished by connecting the SENSE1 pin to the RX data pin Using the appropriate divider resistors mentioned above The SuRF board RN 134 has a built in resistor divider connecting SENSE 0 and SENSE 1 to RXD and CTS to allow waking up the module Note On SuRF board rev 2 the resistor pack conn...

Page 22: ...rection Alternate Functions and Disabling LEDs The direction of the GPIO can be controlled with the GPIO mask using the set sys mask value command to set the GPIO pin direction Value is entered as a hex number If you need to set only one bit in the mask you need to read mask and set the value Otherwise you will over write any previous GPIO settings The hex value represents a bit mask that controls...

Page 23: ...is to control the LED functionality This default functionality can be overridden to allow user programable IO or alternate IO functionality by using the set sys iofunc value command Value is entered as a hex number The hex value represents a bit mask that controls each bit in the value represents a particular GPIO pin If a bit is 0 then that GPIO is driven read by the firmware per the default func...

Page 24: ... alternate function for GPIO 5 and GPIO 6 2 09 save 2 09 reboot the module must be rebooted for the alternate settings to take effect On the remote host run your application or other software that opens and listens on the port Connect GPIO 5 to your embedded processor or other control signal When GPIO 5 is driven high a connection will be attempted When drive low the connection will be closed Be s...

Page 25: ...and to see the current time and uptime 2 09 show t Time 08 43 10 UpTime 10 s Time can be set by using the time command 2 09 show t Time NOT SET UpTime 8 s 2 09 time 2 09 show t Time 08 51 31 UpTime 15 s NOTE the WiFly module must by successfully associated with a network for the module to contact the sNTP server Alternatively the module can be configured to get the time whenever it powers up by se...

Page 26: ...red remotely with this information The MAC address of the associated AP channel and RSSI value are available in this packet thus enabling a simple location and tracking based function By default the Wifly module now sends out a UDP broadcast to 255 255 255 255 on port 55555 at a programmable interval The broadcast address port and interval are set using the set broadcast commands The format of the...

Page 27: ...dhoc mode open up a telnet window on IP address 169 254 1 1 port 2000 If configuring the module using the UART mode either using the RS232 or development board open a terminal emulator on the COM port associated with that deveice The default baud rate is 9600 8 bits no parity 11 1 Associate with a network access point From within the terminal window put the WiFly GSX module into command mode by ty...

Page 28: ...A simple program to test this functionality is a COM port redirector This software opens an IP port and transfers all data it receives to a specified COM port on your machine A free com port redirector program is available from Pira at http www pira cz eng piracom htm After installing and starting this program note the IP address of the machine it is running on This can be found by running ipconfi...

Page 29: ...onnect when set low set sys io 0x20 configures PIO5 to connect disconnect You can monitor the connection status by reading PIO6 High indicates an open connection low indicates no connection Use the command set system IO to enable PIO6 set sys io 0x40 configures PIO6 to represent the connection status 11 5 Using DNS settings WiFly contains a built in DNS client If the IP address of the host is not ...

Page 30: ... Roving Networks the following setting are required FTP username roving FTP password Pass123 FTP filename wifly GSX img FTP directory public this parameter can not be modified To use FTP to upgrade the firmware enter the following command ftp upload string string is an optional filename use to bypass the default firmware filename The ftp upload command will retrieve the file and switch the boot im...

Page 31: ...iFi device on the Adhoc network There is no access point All WiFi devices on the adhoc network participate in keeping the network alive and each keeps track of the other active devices on the network by sending and receiving beacon and probe packets In most cases IP addresses are assigned through Auto IP although one of the WiFi devices can be configured as a DHCP server 13 2 Configuring adhoc mod...

Page 32: ...smaller subnet if the other device s IP addresses are begin statically to the same subnet as the adhoc device set ip address 169 254 1 1 set ip netmask 255 255 0 0 set ip dhcp 0 Be sure to save your configuration then upon reboot the module will be in adhoc mode To associate with an adhoc network from another WiFly device set wlan ssid my_adhoc_network reboot or alternatively you can use the join ...

Page 33: ...ings TCP IP Properties menu Once associated with the adhoc network you can open a connection or telnet window as you would with an enterprise connection Note The module does not support adhoc and enterprise network modes simultaneously 14 Analog Sensor Capability The WiFly GSX has 8 analog interface inputs that can be sampled using the show q command The hardware specifications on the analog input...

Page 34: ... 10 milliseconds Idle timer 0 Cmd char DNS PARAMETERS IP address 0 0 0 0 Name server1 Backup backup2 FTP PARAMETERS Server address 208 109 78 34 roving default update server port at 21 File Wifly GSX img User roving Password Pass123 IP PARAMETERS DHCP ON 1 enabled IP address 0 0 0 0 Net mask 255 255 255 0 Local port 2000 gateway 0 0 0 0 host 0 0 0 0 remote port 2000 protocol 2 TCP server and clien...

Page 35: ...elease only the hardcoded factory defaults would be restored From command interface use the factory RESET command to restore the defaults From hardware setting PIO9 high on power up arms the factory reset functional and toggling PIO9 five 5 times there after causes the configuration setting to restored to the factory reset Now however if there is a config file named user it is read in as the facto...

Page 36: ...sys both standard and openWRT linux Netgear WGR614 v8 Netgear WGN54 DLINK dir 615 Airlink 101 Apple Airport express ADHOC MODE Apple Iphone Microsoft windows PC with XP Vista Ubuntu Linux Function Description Time in ms Power up Powerup Time from Reset HIGH or power good to boot code loaded 70 Initialization Initialize ECOS 500 Ready Load configuration and Initialize application 30 Total time to R...

Page 37: ...r the state of the association to the AP The AP is scanned once per second and if x consecutive scans fail the WiFly declares AP is lost sets the interface to down state and enters the association process Previously the WiFly would not detect that the AP association was lost until the AP became available again or the WiFly was power cycled or rebooted ADHOC mode The command set adhoc probe x is no...

Page 38: ... connection is now accepted but then immediately closed Hardware flow control is now supported To enable use the set uart flow 1 command DHCP renew and rebind is fully supported Previously DHCP renew rebind would update IP settings and if a TCP session was active it would enter a hung state TCP connections now survive a DHCP renew rebind Features TCP connection password This optional pass word is ...

Page 39: ...functional Current Firmware Version 2 09 7 10 2009 Sleep mode was drawing 70uA instead of the expected 4uA due to an oscillator that was not disabled before going to sleep Refer to the RN 131G datasheet for the proper low power hardware configuration Fixed closing of TCP port on TCP RESET Previously the module was not handling remote TCP reset correctly and would disconnect which resulted in a pri...

Page 40: ...atures show net now displays the wifi TX rate and correctly displays authenticated state and shows authentication mode that was used ping h will ping the stored host address If no host address stored will attempt to use the DNS hostname ping i command added to ping a known Internet server www neelum com by first resolving the address proving that DNS is working and then pinging the server This pro...

Reviews: