SERIALIO WISNAP User Guide

www.serialio.com
WiSnap User Manual 2.2 06252010-JF
WIS
NAP
WIFI/S
ERIAL
A
DAPTER
802.11 B/G Wireless LAN Module
User Manual and Command Reference
Version 2.15
Apr 6th, 2010
1 Overview ............................................................................................................................ 3
2 Hardware Interface .............................................................................................................. 4
2.1 Power .......................................................................................................................... 4
2.2 Reset ........................................................................................................................... 4
2.3 UART ........................................................................................................................... 4
2.4 Status Indictors .......................................................................................................... 5
3 Configuration ...................................................................................................................... 5
3.1 Entering Command Mode ............................................................................................... 5
3.2 Common Configurations ................................................................................................. 6
4 WiSnap Command Reference ................................................................................................ 9
4.1 Command Syntax .......................................................................................................... 9
4.2 Command Organization .................................................................................................. 9
5 SET Commands .............................................................................................................. 10
5.1 AD-HOC Parameters ................................................................................................... 10
5.2 BROADCAST Parameters ............................................................................................. 10
5.3 COMM Parameters ...................................................................................................... 10
5.4 DNS Parameters .......................................................................................................... 11
5.5 FTP Parameters .......................................................................................................... 12
5.6 IP Parameters ............................................................................................................. 12
5.7 OPTIONAL Parameters ................................................................................................. 13
5.8 SYSTEM Parameters .................................................................................................... 14
5.9 TIME Server Parameters ............................................................................................... 15
5.10 UART Parameters ..................................................................................................... 15
Page 1 of 49
www.serialio.com
5.11 WLAN Parameters ..................................................................................................... 16
6 GET Commands ................................................................................................................. 18
7 STATUS Commands ........................................................................................................ 19
8 ACTION Commands ....................................................................................................... 21
9 FILE IO Commands ........................................................................................................... 22
10 Advanced Features and Settings ....................................................................................... 23
10.1 System Timers and Auto Connect Timers ..................................................................... 23
10.2 Wake on Sensor Input ............................................................................................... 24
10.3 Wake on UART ......................................................................................................... 24
10.4 Optimizing UART RX and Hardware Flow Control .......................................................... 24
10.5 Setting GPIO direction, Alternate Functions and Disabling LEDs ...................................... 25
10.6 Setting Debug Print levels ........................................................................................... 28
10.7 Using the Real Time Clock Function .............................................................................. 28
10.9 Using the UDP Broadcast function ................................................................................ 29
11 Joining Networks and Making Connections ......................................................................... 31
11.1 Associate with a network access point ........................................................................ 31
11.2 Making Connections .................................................................................................. 32
11.3 Setting up Automatic Connections .............................................................................. 32
11.4 Controlling Connections using PIO5 and PIO6 ............................................................... 33
11.5 Using DNS settings .................................................................................................. 33
11.6 Utilizing the Backup IP address/connect function .......................................................... 33
12.1 Automatic-Advanced Web Server Modes ....................................................................... 34
14 Ad-hoc Networking Mode .................................................................................................. 37
14.1 Infrastructure and ad-hoc comparison ......................................................................... 37
14.2 Configuring ad-hoc mode ........................................................................................... 37
15 Analog Sensor Capability ................................................................................................. 39
16 Default Configuration Settings ........................................................................................... 42
16.1 Restoring Default configuration settings: .................................................................... 43
17 Boot-up Timing Values ..................................................................................................... 44
18 Supported Access Points ................................................................................................... 44
19 Release Notes ................................................................................................................. 45
19.1 Known problems ....................................................................................................... 45
19.2 Current Firmware features and fixes ........................................................................... 45
WiSnap User Manual 2.2 06252010-JF
Page 2 of 49
www.serialio.com
WiSnap User Manual 2.2 06252010-JF

1 Overview

WiSnap radio module is a complete stand alone embedded wireless LAN access device. The
The device has an on-board TCP/IP stack and RS-232 interface for transferring data to remote applications, such as an iPhone app, data logger, or PC control console.
Fully Qualified and Wifi Certified 2.4GHz IEEE 802.11b/g transceiver High throughput, up to 4Mbps sustained data rate with TCP/IP and WPA2 Ultra-low power (4uA sleep, 40mA Rx, 210mA max Tx) Small, compact surface mount module On board ceramic chip antenna and U.FL connector for external antenna 8 Mbit flash memory and 128 KB RAM UART and SPI (future) data/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 Ad-hoc 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 UART Memory 128 KB RAM,2MB ROM, 2 KB battery-backed memory, 8 Mbit Flash. Intelligent, built-in power management with programmable wakeup Can be powered from regulated 3.3-3.7V source or 2.0-3.0V batteries Real time clock for time stamping, auto-sleep and auto-wakeup modes Configuration over UART or wireless interfaces using simple ASCII commands Over the air firmware upgrade (FTP), and data file upload. Secure WiFi authentication WEP-128, WPA-PSK (TKIP), WPA2-PSK (AES). Built in networking applications DHCP client, UDP, DNS client , ARP, ICMP ping, FTP, HTTP 802.11 power save and roaming functions
One of the main applications for this device is the iPhone, since it requires buying additional authorization hardware to use Bluetooth SPP, the WiSnap in ad-hoc mode is a simple and cost effective way to connect to iPhone apps. The WiSnap Serial Adapter is more than a cable replacement solution. By allowing multiple TCP/IP sockets, applications can control and monitor hundreds of WiFi Serial adapters remotely distributed across a building LAN or campus WAN.
Page 3 of 49
www.serialio.com
WiSnap User Manual 2.2 06252010-JF

2 Hardware Interface

2.1 Power

There are two options for powering the WISNAP module directly.
DC SUPPLY: Apply 3.3 VDC power to VBATT (pin 20), and V3.3IN (pin 21). Tie 3.3VREG-IN (pin 18)
to GROUND. 3.3V-REG-OUT (Pin 17) leave floating.
BATTERY: Apply battery = 2.0 to 3.3VDC to VBATT (pin 20). V3.3IN pin 21 = floating.
Tie pin 17 to pin 18. (This enables the on board battery boost 3.3V switcher).
There is a built in voltage brownout monitor which will shut down the chip when the voltage drops below 2.0 VDC.
Warning module.
Notes:

2.2 Reset

Reset is active LOW and is optional/does not need to be connected. The reset pin is 3.3V tolerant and has an internal pull up of 100K to the VBATT.

2.3 UART

Connect a common ground when using the external TX, RX inputs.
For a 3 wire DB-9 interface (connect tx, rx, gnd only)
Factory default is hardware flow control disabled, CTS and RTS are not required.
When using a 5.0 VDC Input, PIO 10K in series with 20k to ground. PIOs are 0-3.3 VDC not 5.0 VDC tolerant.
: Do NOT exceed the voltage ratings on the 3.3V pins, this may result in damage to the
#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 module. The failure mode is a short across GND and VCC.
s while they are set as outputs will permanently damage the
s and UART input pins require a resistor divider. A suggestion is
Page 4 of 49
www.serialio.com
WiSnap User Manual 2.2 06252010-JF

2.4 Status Indictors

PIO 4, 5 and 6 are active high and can be connected to external LEDs to provide network, connection and data status.
State Red LED Yellow LED Green LED Blue LED
ON solid Not Associated Connected over TCP
Fast blink Rx/Tx data transfer
Slow blink Associated, No Internet
OFF Associated, Internet OK
IP address OK Low Power
No IP address or
Config Mode
Full Charge

3 Configuration

3.1 Entering Command Mode

You can administer the device with your favourite terminal emulator, such as Teraterm or PuTTY.
Parameters, such as the SSID, channel, IP address, Serial Port settings, and all other settings can be viewed and configured in command mode.
ASCII characters can be sent through a terminal emulator connected to the UART or via Telnet. Defaults are: 9600 baudrate, 8 bits, No Parity, 1 stop bit, and hardware flow control disabled.
Typing returned to you. This will verify that your cable and communication settings are correct. Most valid commands will return an AOK, response, and invalid ones will return an ERR description.
To exit command mode, type
NOTE: You can enter command mode locally over the UART interface at any time when not connected, and also when connected if the appropriate settings are enabled.
Remote configuration using AD-HOC mode
Using ad-hoc mode to configure the device eliminates the need for the module to be associated with a network access point. In ad-hoc mode the module creates it own on demand network that you can connect to via your computer like you would to any other network.
To enable ad-hoc mode, enable the J1 switch on the jumper block. When the module powers up with this jumper set on, the WiSnap module creates an ad-hoc network with the following settings:
With the ad-hoc jumper in place, the above settings override the current saved configuration settings.
$$$on in the terminal emulator will enter command mode. You should see CMD
exit<cr>.
SSID: WiSnap-XX - where XX is the final two bytes of the devices MAC address Channel: 1 DHCP: OFF IP address: 169.254.1.1 Netmask: 255.255.0.0
Page 5 of 49
www.serialio.com
From your computer, connect to the WiSnap-XX network. This is an open network which does not require a pass phrase or pass key.
NOTE: currently the WiSnap only supports OPEN mode for creating ad-hoc networks.
NOTE: It may take a couple of minutes for Auto IP in Windows to assign an IP address and connect
to the network. You can check IP address of your Windows computer by running the ipconfig command in a command window. If connected, this command will show you the IP address and netmask for your computer.
Your IP address must be on the 169.254.1.X network otherwise the WiSnap module will not be accessible.
NOTE: If your machine has both a wireless and wired network interface, you may need to disable the wired LAN interface hardware before connecting to the ad-hoc network. If the wired LAN is enabled, the computer may assign an IP address that is not on the same subnet as the WiSnap module.
Once connected and you have a valid IP address, telnet into the WiSnap module on port 2000 with this command in Windows:
telnet 169.254.1.1 2000
You should see the response *HELLO*
You can now enter command mode and configure the module.
WiSnap User Manual 2.2 06252010-JF

3.2 Common Configurations

Two common modes of operation for the WiSnap module are A) initiating a connection to a server and B) listening for a remote host connection. This section will go through the configuration for each setup. The setups are shown using infrastructure network. i.e. with an access point, however the same can be done with ad-hoc networking.
Initiating a connection from the WiSnap
Step 1: Set up the WLAN properties so the device will connect to the network automatically upon power up. In this example we want to connect to the wireless network my_network.
set wlan join 1 // Auto join upon power up set wlan chan 0 // Scan all channels set wlan ssid my_network // Network name set wlan phrase my_secret_code // Pass phrase
The join 1 setting ensures that when the module wakes up, it tries to join the access point that matches the stored SSID, passkey and channel. Channel =0 (the default) will force auto-scanning. Setting the channel will reduce the time it takes the WiSnap to find and associate.
Step 2: Set up the
set ip host 10.20.20.75 // Set the host IP address set ip remote 3000 // Set the remote port set sys autoconn 2 // Try to connect to the host every 2 seconds save // Save configuration>
Note: If autoconn = 1, the WiSnap will only make one attempt to auto connect.
IP address and port number of the remote server, so the WiSnap can connect when it wakes up.
Page 6 of 49
www.serialio.com
Step 3: Set the
data written to the serial interface. You can also configure the device to wake up on CTS, on a PIO or timer. See the command reference for details. We are going to set this up to wake on a timer then sleep after 2 minutes if there is no connection or if connected and no data has been transferred for 30 seconds.
set sys sleep 120 // sleep after 2 minutes if no connection set sys trigger 2 // wake on CTS set conn idle 30 // disconnect after 30 seconds of no data save // save all the settings to the config file reboot // use the new settings
This setup can be tested using TCP server application that opens a socket on port 3000. Port Peeker is a free application that you can download off the web. It is available at http://www.linklogger.com/portpeeker.htm
Waiting for the remote host to connect to the serial adapter (listen mode)
In this example we are using a static IP so that the remote host knows where the WiSnap Serial adapter is on the network. Alternatively you can write your application software to listen for the broadcast UDP packet (automatically sent by WiSnap by default) to identify the WiSnap Serial adapter and get the IP address and TCP port number that the WiSnap is listening on.
Step 1: Set up the wlan properties so the device will connect to the network automatically upon power up. In this example we want to connect to the wireless network my_network.
set wlan join 1 // Auto join upon power up set wlan chan 1 // only look on channel 1 set wlan ssid my_network // Network name set wlan phrase my_secret_code // Pass phrase
Step 2: Configure the WiSnap static IP address so the remote application can connect, address and netmask.
set ip address 10.20.20.63 // Set the IP address set ip port 5030 // Set the local port to listen on set ip netmask 255.255.255.0 // Set the IP netmask set ip gateway 10.20.20.1 // Sets the network gateway set ip dhcp 0 // Turn off DHCP
Step 3: Set the wake up and sleep conditions. In this mode the sleep and wake timers are used to
conserve battery. Since we dont know when the remote host will connect, the module should to occasionally wake up and listen for the remote host. The trade off with these timers is that the longer you sleep, the better your battery life will be but the longer it will take the remote host to connect.
WARNING: Do not set the sleep timer below 5 seconds or it will be impossible to get into command mode to reprogram this mode without it going back to sleep!
wake up and sleep conditions. By default the adapter will wake whenever there is
WiSnap User Manual 2.2 06252010-JF
turn off DHCP and set the IP
Page 7 of 49
www.serialio.com
set sys wake 20 // Wake after 20 seconds set sys sleep 10 // Go to sleep after 10 seconds save // Save configuration reboot // restart using the new configuration
At this point you could test this configuration using telnet on a computer sharing the same network to connect to the WiSnap module.
WiSnap User Manual 2.2 06252010-JF
Page 8 of 49
www.serialio.com
WiSnap User Manual 2.2 06252010-JF

4 WiSnap Command Reference

4.1 Command Syntax

Commands begin with a keyword, and have optional additional parameters, generally space delimited. Commands and options are case sensitive. Hex input data can be upper or lower case. String text data, such as SSID is also case sensitive.
The first command is fully decoded and must be complete. Other command parameters can be shorted by using only the first character.
For example,
Numbers can be entered as either decimal, (like 115200 above) or hex. To enter hex, use before the value: 0x<value>. For example, the hex value FF would be entered as 0xFF.
Commands fall into 5 general categories:
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 called config. The set commands actually only modify the RAM copy of variables in the system. In general, the IP, WLAN and UART settings need a save and reboot to take effect, since they operate at boot up time. For example: At power up, you will only associate, set the channel and get your IP address once.
Most of the other commands take effect immediately like the COMM settings and timers. This allows temporary change of parameters on the fly to test features, minimizes power usage and saves on flash re-write cycles.
Once all configuration is complete, the user must save the settings using the the configuration data, otherwise it will not take effect upon reboot or reset. Multiple configurations can be stored by using the save <filename> command, and these configurations can be loaded using the load <filename> command.
set uart baudrate 115200 is valid,
set uart b 115200 is also valid,
set u b 115200 is also valid, however,
s uart baudrate 115200 is NOT
valid.

4.2 Command Organization

SET COMMANDS – Changes settings immediately and permanently (save command issued).
GET COMMANDS - Retrieve the permanently stored information for display to user.
STATUS 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.
save command to store
Page 9 of 49
0x
www.serialio.com
WiSnap User Manual 2.2 06252010-JF

5 SET Commands

These commands begin with
AD-HOC - controls the ad-hoc parameters BROADCAST - controls the broadcast hello/heartbeat UDP message COMM - communication and data transfer, timers, matching characters DNS - DNS host and domain FTP - FTP host address and login information IP - IP settings OPTION - optional and not frequently used parameters SYS - system settings such as sleep and wake timers TIME - timer server settings UART - serial port settings such as baud rate and parity WLAN - wireless interface settings, such as SSID, channel, and security options

5.1 AD-HOC Parameters

set ad-hoc beacon <ms> sets the ad-hoc beacon interval in milliseconds. Default is 100.
set ad-hoc probe <num> sets the ad-hoc probe retry count. Default is 5. This is the number

5.2 BROADCAST Parameters

set broadcast address <addr> sets the address to which the UDP hello/heartbeat message is
set broadcast interval <value> sets the interval at which the hello/heartbeat UDP message is
set broadcast port <port> sets the port number to which the UDP hello/heartbeat message is

5.3 COMM Parameters

set comm $ <char> sets character used to enter command mode. Typically used when
set comm close <string>
set. There are 6 major categories.
of consecutive probe responses that can be lost before declaring AD-HOC is lost and disabling the network interface.
sent. The default address is 255.255.255.255
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 1 (every 2 seconds) and max value is 0xff (every 256 seconds). Setting the interval value to zero disables sending UDP broadcast messages. The default interval is 7.
sent. The default port is 55555.
$$$ is a possible data string. Default is $. Care should be taken when setting this to note the new character as once this setting is saved every subsequent reboot will ignore $$$ and look for <char><char><char>.
sets the ASCI string that is sent to the local UART when the TCP port
is closed. If no string is desired, use 0 as the <string> parameter. Max string length is 32 characters. Default is *CLOS*
Page 10 of 49
www.serialio.com
set comm open <string> sets the string that is sent to the local UART when the TCP port is
opened. If no string is desired, use 0 as the <string> parameter. Max string length is 32 characters. Default is *OPEN*
set comm remote <string> sets the string that is sent to the remote TCP client when the TCP
port is opened. If no string is desired, use 0 as the <string> parameter. Max string length is 32 characters. Default is *HELLO*
set comm idle <secs> sets the Idle Timer Value. This is the number of seconds with no
transmit or receive data before the connection is closed automatically. Default is 0, never disconnect on idle.
set comm match <value> sets match character. An IP packet will be sent each time the match
character appears in the data. Value is entered as the decimal (13) or hex (0xd) of the of the ASCII character. Default is 0, disabled. The match character is one of three ways to control TCP/IP packet forwarding. The others are size and timer. For more information see section 10.4.
set comm size <value> sets the flush size. An IP packet will be sent each time value bytes
are received. Default is 64 bytes. You should set this value to the largest possible setting to maximize TCP/IP performance. Maximum value = 1420 (at 9600) bytes.
NOTE: This value is set automatically when the baudrate is set, in
an attempt to optimize the link. It is assumed that higher baudrates equates to more data and hence the flush size is increased.
Flush size is one of three ways to control TCP/IP packet forwarding. The others are match character and timer. For more information see section 10.4.
set comm time <num> sets the flush timer. An IP packet will be sent if no additional bytes
are received for num milliseconds. Num is one milliseconds intervals. 1 is the minimum value. Default is 10 (10 milliseconds). Setting this value to 0 will disable forwarding based on the flush timer.
Flush timer is one of three ways to control TCP/IP packet forwarding. The others are match character and size. For more information see section 10.4.
WiSnap User Manual 2.2 06252010-JF

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> sets the name of the host for TCP/IP connections.
set dns backup <string> sets the name of the backup host for TCP/IP connections.
Page 11 of 49
www.serialio.com
WiSnap User Manual 2.2 06252010-JF
5.5

FTP Parameters

set ftp filename <file> sets the name of the file transferred when issuing the ftp u or ftp
g commands.
set ftp addr <addr> sets the ftp server IP address.
set ftp remote <port> sets the ftp server remote port number (default is 21).
set ftp user <name> sets the ftp user name for accessing the FTP server.
set ftp pass <pass> sets the ftp password for accessing the FTP server.

5.6 IP Parameters

set ip address <addr> sets the IP address of the WiSnap module. If DHCP is turned on, the
IP address is assigned and overwritten during association with the access point.
Example: set ip a 10.20.20.1
set ip backup <addr> sets a secondary host IP address.
set ip dchp <value> enable/disable DHCP mode. If enabled, the IP address, gateway,
netmask, and DNS server are requested and set upon association with access point. Any current IP values are overwritten.
DHCP Cache mode can reduce the time it takes the module to wake
from deep sleep thus saving power. In cache mode, the lease time is checked and if not expired the module uses the previous IP settings. If the lease has expired the module will attempt to associated and use DHCP to get the IP settings. DHCP cached IP address does not survive a power cycle or reset.
Mode Protocol
0 DHCP OFF, use stored static IP address 1 DHCP ON, get IP address and gateway from AP 2 Auto-IP, generally used with Ad-hoc networks
3
4 Reserved 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
DHCP cache mode, Uses previous IP address if lease is not expired (lease survives reboot)
Page 12 of 49
www.serialio.com
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 gateway <addr> sets the gateway IP address, If DHCP is turned on, the gateway IP
address is assign and overwritten during association with the access point.
set ip host <addr> sets the remote host IP address. This command is used for making
connections from the WiSnap module to a TCP/IP server at the IP address <addr>.
set ip localport <num> sets the local port number.
set ip netmask <value> sets the network mask. If DHCP is turned on, the net mask is assign
and overwritten during association with the access point.
set ip protocol <value> sets the IP protocol. Value is a bit mapped setting. To connect to the
WiSnap module over TCP/IP such as Telnet the device must have the use the TCP Server protocol / bit 2 set. To accept both TCP and UDP use value = 3 (bit 1 and bit 2 set)
Bit Position Protocol 0 UDP 1 TCP Server & Client (Default)
2
3 TCP Client only 4 Future Use
set ip remote <value> sets the remote host port number.
WiSnap User Manual 2.2 06252010-JF
Secure (only receive packets with IP address
matches the store host IP)

5.7 OPTIONAL Parameters

set opt jointmr <msecs> Join timer is the time in milliseconds (default=1000) the join function
will wait for the an access point to complete the association process. This timer is also the timeout for the WPA handshaking process.
set opt replace <char> replacement character for spaces. The replacement character is
used when entering SSID and pass phrases that include space. This is used by the WiSnap command parser only. Each occurrence of the replacement character is changed into a space. The default is $ (0x24)
set opt deviceid <string> Configurable Device ID - can be used for storing serial numbers,
product name or other device information. This information is sent
Page 13 of 49
www.serialio.com
as part of the broadcast hello packet that is sent as a UDP. The current value can be shown with the get option or show deviceid commands. Max string size is 32 bytes. The default is WiSnap<DEVICEID>M1.
set opt password <string> TCP connection password. Provides minimal authentication by
requiring any remote device that connects to send and match a challenge <string>. When set, all newly opened connections must first send the exact characters that match the stored password otherwise the WiSnap module will close the connection. When the password is set the WiSnap module sends the string PASS? to the remote host. All characters in the string must be sent in one TCP packet. Max string size is 32 bytes. To disable the password feature use string=0 which is the default.
WiSnap User Manual 2.2 06252010-JF

5.8 SYSTEM Parameters

set sys autoconn <secs> TCP mode: sets the auto connect timer. This command causes the
module periodically connect to the host. The timer <secs> determines how often to connect to the stored remote host. If set to 1, the module will only make one attempt to auto connect upon power up. If set to 2 or greater auto connect will re-open the connection after the connection is closed. Default=0 disables.
set sys autosleep <num> Sets the auto-sleep timer. 0 disables. If the protocol is set to UDP
ONLY, this timer is used as a quick sleep function. Device will sleep
<num> ms after transmission of the first UDP packet.
set sys iofunc <value> sets the IO port alternate functions. Bit-mapped value. For more
details see section 10.5
set sys mask <mask> sets the IO port direction mask. Bit-mapped value. For more
information see section 10.5
set sys printlvl <value> sets numerous print functions. 0 = quiet 1 = connect information
Default is 1.
set sys output <value> <mask> sets output PIO pins to HIGH or LOW. Bit-mapped value.
Optional mask only sets a subset of pins.
set sys sleep <secs> sets the sleep timer. 0 disables.
NOTE: If not using Sensor pins to wake the module, be sure to set the wake timer before issuing the sleep timer or the module will not wake up.
See section 10.1 for more details on using system timers
set sys trigger <value> sets the sensor input(s) to wake on (0-3). Bit-mapped value. 0
disables.
Page 14 of 49
3 Enable Sleep on RX BREAK signal
www.serialio.com
set sys wake <secs> sets the auto wake timer. 0 disables. See section 10.1 for more
details on using system timers
WiSnap User Manual 2.2 06252010-JF

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 fetching time from the specified sNTP time server.
Default=0= disabled. A value or 1 gets time only once on power up. Any value > 1 gets time continuously every <value> minutes.

5.10 UART Parameters

set uart baud <rate> set the UART baud rate. Valid settings are {2400, 4800, 9600,
19200, 38400, 57600, 115200, 230400, 460800, 921600}.
Example :
NOTE: the RS-232 interface on the RN-134 does not work above
230400
set uart instant <rate> This immediately changes the baudrate. This is useful when testing
baudrate settings, or switching baudrate on the fly remotely while connected over TCP. This setting does not affect configuration. Returns the AOK response, and then this command will exit command mode.
set uart raw <rate> sets a RAW UART value. Used to set non-standard rates. The lowest
possible baud rate is 2400.
Example :
set uart flow <0,1> sets the flow control mode. Default=0=off, 1= hardware RTS/CTS. NOTE: once flow control is enabled, it is important to properly Drive the CTS pin (active LOW enabled) If CTS is HIGH, data
will NOT be sent out the UART, and further configuration in command mode will be problematic as no response will be received.
set uart mode <value>
sets the UART mode register. This is a bit-mapped value.
Bit Position Function
set u b 9600 sets the baud rate to 9600 baud.
set u r 7200 sets the baud rate to 7200 baud.
0
1 DATA TRIGGER makes connection on RX data 2 RAW mode (TCP stack disabled)
NOECHO - disables echo of RX data while in command mode
Page 15 of 49
Loading...
+ 34 hidden pages