| Electronic Components Datasheet Search |
|
AN3254 Datasheet(PDF) 8 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN3254 Datasheet(HTML) 8 Page - STMicroelectronics |
|
8 / 24 page ![]() SPI operations AN3254 8/24 Doc ID 17783 Rev 1 Commands for changing configuration bits and system signals should be sent during active signals SCS and SYN, as it is shown in Figure 3. The SYN must be put low in order to disable the SDA output driver of the device and to make the SDA an input pin. A string of commands can be sent within one period of active signals SCS and SYN or a command can be followed by reading the data record but, in this case, the SYN should be deactivated in order to enable the SDA output driver and a SYN pulse should be applied before activation of the SCS in order to latch the data. Given the connection between the STPMC1 and a microcontroller, as shown in the previous paragraph, it is possible to implement the writing procedure in the firmware through the following steps: 1. disable the SPI peripheral 2. set MISO, SCLK, and SS to be output 3. set the pin which is connected to SYN to be output high 4. activate SCS first and then SYN 5. activate SCL 6. apply a bit value to SDA and deactivate SCL 7. repeat the last two steps seven times to complete one byte transfer 8. repeat the last three steps for any remaining byte transfer 9. deactivate SYN and the SCS 10. enable again the SPI module. To temporarily set any bit, it is necessary to set the RD system signal before any other bit. This bit determines the device functioning from OTP shadow latches and not from OTP memory. The procedure to set this signal is that shown above. In the case of a precharge command (0xFF), emulation of the above is not necessary, it can be sent before any reading command. In fact, due to the pull up device on the SDA pin the processor needs to perform the following steps: 1. activate SYN first in order to latch the results 2. after at least 1 µs activate SCS 3. write one byte to the transmitter of SPI this produces 8 pulses on the SCL with SDA=1 4. deactivate SYN 5. read the data records as shown in Section 3.4 (the sequence of reading is altered) 6. deactivate SCS. 3.3 Data registers permanent writing In order to make a permanent set in OTP memory of some configuration bits, the following procedure should be conducted: |
|
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |