
28
As the raw data starts to come in from the wireless unit, a continuous write command
is first issued to the SD card, and data is written directly to the card. The write
command used to make the data write function is similar to the command 0 that was
shown in section 2.3. Figure 20 shows the continuous write command 25 as given via
the SPI to the SD card.
Figure 20: PSoC Designer SPI CMD 25. Screenshot [3].
As can be seen in the figure, the command starts with the command byte of 0x59
representing a continuous write function. Next is the argument which gives the
memory location to be written to, shown here as variables passed to the function. The
CRC is not necessary at this point as the card is initialized and in SPI mode, so once in
SPI mode the hex number 0x95 is used instead as a dummy byte for the CRC.
After the continuous write command, the MCU waits for an accepted response token
from the SD card. Then the MCU is free to send data beginning with the start byte of
0xFC. The SD card knows then that everything following is raw data and should be
saved into the respective memory locations. This is a continuous write command and it
will take data in one sector at a time until a proper stop token is received. This sector
grouping is such that the SD card may perform a CRC on the data with every sector.
This grouping is not avoidable even though the CRC is not being used. Furthermore, this
grouping does slow down the transmission of data. When all data is sent on the
Comentarios a estos manuales