4 modes of operation of the SPI bus

Source: Internet
Author: User

The 4 operating modes of the SPI bus 0 to 4 Modesspi interface is the full name of "Serial peripheral Interface", meaning the serial peripheral interface, Motorola first defined on its MC68HCXX series processor. The SPI interface is used primarily in eeprom,flash, real-time clocks, ad converters, and digital signal processors and digital signal decoders.

The SPI interface is a synchronous serial data transfer between the CPU and the peripheral low-speed device, in the shift pulse of the main device, the data is bit-transmitted, high in front, position behind, for full-duplex communication, the data transmission speed is generally faster than the I²C bus, the speed can reach a few Mbps.

The SPI interface is a master-slave operation, which typically has one main device and one or more slave devices, and the interface consists of the following four signals:

(1) mosi– master device data output, from device data input
(2) miso– Master device data input, from device data output
(3) sclk– clock signal, generated by the main device
(4)/ss– from the device enable signal, controlled by the main device 

In point-to-point communication, the SPI interface does not require addressing, and it is simple and efficient for full-duplex communication.
In multiple slave device systems, each slave device requires a separate enable signal, which is slightly more complex than the I²C system on the hardware.

The SPI interface in the internal hardware is actually two simple shift registers, the transmitted data is 8 bits, the main device generated from the device enable signal and the shift pulse, the bitwise transmission, high position in front, low post. As shown, data changes on the falling edge of the SCLK, while a data is stored in a shift register.

 

Internal hardware diagram for SPI interface:

Finally, one drawback of the SPI interface is that there is no flow control specified, and there is no response mechanism to confirm receipt of the data.

4 Modes for 4 clock settings, one setting is the clock idle in the high or low state, the other setting data is on the rising edge of the clock or falling along the latch, 2x2=4 species

4 modes of operation of the SPI bus

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.