Rf22, Operating mode control, Figure5. spi timing—read mode – Rainbow Electronics RF22 User Manual
Page 9: Figure6. spi timing—burst write mode, Figure7. spi timing—burst read mode

RF22
Version: 0.1 Date: 12/23/2008
Tel: +86-755-82973805 Fax: +86-755-82973550 E-mail: [email protected] http://www.hoperf.com
9
To read back data from the RF22, the R/W bit must be set to 0 followed by the 7-bit address of the register from which
to read. The 8 bit DATA field following the 7-bit ADDR field is ignored when R/W = 0. The next eight positive edge
transitions of the SCLK signal will clock out the contents of the selected register. The data read from the selected
register will be available on the SDO output pin. The READ function is shown in Figure 5. After the READ function is
completed the SDO pin will remain at either logic 1 or logic 0 state depending on the last data bit clocked out (D0).
When nSEL goes high the SDO output pin will be pulled high by internal pull-up.
nSEL
SCLK
SDI
=0
RW
A6 A5 A4
=X
D6 D5 D4 D3
D2 D1 D0
D0
=X
D1
=X
D2
=X
D3
=X
D4
=X
D5
=X
D6
A3
Last Bit
First Bit
=X
SDO
D7
A1
A2
D7
A0
Last Bit
First Bit
Figure5. SPI Timing—READ Mode
The SPI interface contains a burst read/write mode which will allows for reading/writing sequential registers without
having to re-send the SPI address. When the nSEL bit is held low while continuing to send SCLK pulses, the SPI
interface will automatically increment the ADDR and read from/write to the next address. An SPI burst write transaction
is demonstrated in Figure 6 and burst read in Figure 7. As long as nSEL is held low, input data will be latched into the
RF22 every eight SCLK cycles. A burst read transaction is also demonstrated in Figure 7.
First Bit
=X
D0
=X
D1
=X
D2
=X
D3
=X
D4
=X
D5
=X
D6
=X
D7
=1
Last Bit
RW
A6 A5
=X
A4
D0
=X
D1
=X
D2
=X
D3
=X
D4
=X
D5
=X
D6
A3 A2
=X
A1
D7
A0
nSEL
SCLK
SDI
Figure6. SPI Timing—Burst Write Mode
First Bit
D1 D0
D2
D3
=0
D7 D6 D5 D4
RW
A6 A5
=X
D6 D5 D4 D3 D2 D1 D0
A4
D0
=X
D1
=X
D2
=X
D3
=X
4
D
=X
5
D
=X
D6
First Bit
A3 A2
=X
SDO
D7
A1
D7
A0
Last Bit
nSEL
SCLK
SDI
Figure7. SPI Timing—Burst Read Mode
3.2. Operating Mode Control
There are four primary states in the RF22 radio state machine: SHUTDOWN, IDLE, TX, and RX (see Figure 8). The
SHUTDOWN state completely shuts down the radio to minimize current consumption. There are five different
configurations/options for the IDLE state which can be selected to optimize the chip to the applications needs.
"Register 07h. Operating Mode and Function Control 1" controls which operating mode/state is selected. The TX and
RX state may be reached automatically from any of the IDLE states by setting the txon/rxon bits in "Register 07h.
Operating Mode and Function Control 1". Table 11 shows each of the operating modes with the time required to reach
either RX or TX mode as well as the current consumption of each mode.