WiSnap User Manual 4.41 05282015-ML
Page 28
Drive GPIO9 High
GPIO8
The module sleeps as soon as GPIO8 is held high (4 µs
latency). To enable this feature, use the
set sys trigger
0x20
command setting.
To wake up the module from sleep, following options are available:
Method
Type
Description
Sensor Input (1.2VDC ONLY)
Sensor Pins
You can wake up the module on sensor pins 0-3 (
1.2V
ONLY
). Use the
set sys trigger <value>
command to
enable. Refer to section 10.2 for details.
Rx Pin (1.2VDC ONLY)
Rx pin via Sensor 0
The RX pin on the RN-134 is tied to Sensor Pin 0. Use the
set sys trigger 1
command to wake up on RX data.
NOTE:
You may drop the first byte of UART data. A better way
to wake up the module on CTS pin. Refer to section 10.3
for details.
CTS Pin (3.3VDC ONLY)
CTS pin via Sensor 1
The CTS pin on the RN-134 is tied to Sensor pin 1. Use
the
set sys trigger 2
command to wake up on CTS. Refer
to section 10.3 for details.
Wake Timer
Internal RTC
Wakes up the module from sleep based on the
set sys
wake <secs>
command.
FORCE AWAKE
FORCE AWAKE pin
Input pulse of at least 31 µsecs duration (
3.3V ONLY
) will
wake up the module.
When the module wakes up from sleep, it takes a certain amount of time (in milliseconds) to initialize the internal hardware.
During this time, any data that is sent to the WiSnap module over the UART will not be processed. You can monitor certain
signals that indicate that the module is ready to accept data. These are described in the table below:
Method
Interface
Description
RTS transition
RTS pin
Once the WiSnap module wakes up, the RTS line goes
HIGH. Once the system is ready, the RTS is driven LOW.
This can be monitored by the micro controller.
Monitor GPIO4
Alternative GPIO functions Set the alternative functions for GPIO 4, 5, and 6 (refer
to section 10.5.1). Once the module wakes up and
connects to an AP, GPIO 4 goes high. This indicates the
module is ready to receive data over UART. Your micro
controller can monitor GPIO 4.
Sensor power
Sensor power pin
You can configure the module to output Vbat, 3.3 V, or
1.2 V on the sensor power pin when it wakes from sleep,
indicating it is ready to accept data.
Once the module is awake, you can open a TCP connection to a remote host in a number of ways described below. The remote
host can be set using the following commands:
1)
set ip host
<IP address>
or
set dns name
<string>
-
sets up the IP address OR URL of host
2)
set ip remote <port number> -
sets up the port number on which the host is listening
3)
save
-
save settings in config file
4)
reboot
-
reboots the module so that the settings take effect
Method
Type
Description
Auto connect
Internal RTC Timer
Connect out to the host at specific time intervals based
upon the
set sys autoconn <secs>
command.
Open
UART
In command mode, you can issue the
open
command.
Connect UART data
UART mode 2
This mode is designed for the HTML client feature. Use
the
set uart mode 2
command to automatically connect
out to host on UART data.
GPIO 5
Alternative GPIO functions Set the alternative functions for GPIO 4, 5, and 6 (refer
to section 10.5.1). Set GPIO 5 HIGH to trigger TCP
connection, LOW to disconnect.