GS2101M IP2WiFi Adapter Command Reference Guide
1VV0301499
Rev. 2.0
45
2019-08-05
3.2.2.2.2 Polling Methodology
This method can only be used if the MCU is not capable to generate the interrupts where
the MCU is single threaded. Currently its not recommended to use this mode.
For high speed MCUs, it is always recommended to use interrupt mode.
The following section provides steps involved while transferring data from MCU to GS
node using Polling methodology.
Transferring Data
from MCU to GS
Node
1. MCU provides clock.
2. MCU sends the WRITE_REQUEST to GS node. It uses HI frame with:
a. Class field - WRITE_REQUEST
b. Length is the size of data to be transferred from MCU to GS node.
–
The maximum available data size is 2032 (2048-8-8).
–
The maximum DMA size allowed on GS2000 is 1024.
–
It is recommended to send up to 1400bytes at a time.
3. When GS node receives the WRITE_REQUEST, it pulls GPIO37 LOW (to avoid the
race condition when GPIO37 is high and HOST MCU wants to write some data to GS
node) and then processes WRITE_REQUEST. It creates WRITE_RESPONSE
populating the DMA buffer and then makes the GPIO37 HIGH.
4. GS node pulls the Ready to Send signal (GPIO37) high to inform the MCU when it is
ready with the WRITE_RESPONSE.
5. MCU provides the clock to read WRITE_RESPONSE.
6. GS node sends WRITE_RESPONSE to MCU. It uses HI frame with:
NOTE:
If a race condition occurs when the GS node wants to send data to MCU and
MCU wants to send data to GS node at the same time, then:
a.) GS node first responds to the WRITE_REQUEST and provides proper
responses.
b.) Once MCU WRITE is finished and MCU receives proper response, GPIO37
will be again made HIGH as GS node contains certain pending data which MCU
has not read.
c.) MCU should send READ_REQUEST and read all the data available in GS
node.
NOTE:
The MCU must wait for the GPIO37 transition from Low to High before
applying the clock.