为了正常的体验网站,请在浏览器设置里面开启Javascript功能!

SPI总线规范

2013-12-01 5页 pdf 162KB 358阅读

用户头像

is_360863

暂无简介

举报
SPI总线规范 Technical Note 15 1(5) SPI Interface Specification OBJECTIVE This document specifies the Serial Peripheral Interface (SPI) that is used in the SCA61T, SCA100T, SCA103T, SCA1000, and SCA1020 –series sensors...
SPI总线规范
Technical Note 15 1(5) SPI Interface Specification OBJECTIVE This document specifies the Serial Peripheral Interface (SPI) that is used in the SCA61T, SCA100T, SCA103T, SCA1000, and SCA1020 –series sensors. THE SPI INTERFACE A Serial Peripheral Interface (SPI) system consists of one master device and one or more slave devices. The master is defined as a microcontroller providing the SPI clock and the slave as any integrated circuit receiving the SPI clock from the master. The ASIC in VTI Technologies’ products always operates as a slave device in master-slave operation mode. The SPI has a 4-wire synchronous serial interface. Data communication is enabled with a low active Slave Select or Chip Select wire (CSB). Data is transmitted with a 3-wire interface consisting of wires for serial data input (MOSI), serial data output (MISO) and serial clock (SCK). DATA OUT (MOSI) DATA IN (MISO) SERIAL CLOCK (SCK) SS0 SS1 SS2 SS3 MASTER MICROCONTROLLER SI SO SCK CS SLAVE SI SO SCK CS SI SO SCK CS SI SO SCK CS Figure 1. Typical SPI connection The SPI interface in VTI products is designed to support any microcontroller that uses SPI bus. Communication can be carried out by software or hardware based SPI. Please note that in the case of hardware based SPI, the received acceleration data is 11 bits. The SPI interface is used for testing and calibration purposes, and it can also be used in the final application. Some of the test and calibration commands are disabled in normal use, and are not documented here. The data transfer uses the following 4- wire interface: MOSI master out slave in µP → ASIC MISO master in slave out ASIC → µP SCK serial clock µP → ASIC CSB chip select (low active) µP → ASIC 1 9 Sep 2005 VTI Technologies reserves all rights to modify this document without prior notice. Technical Note 15 2(5) Each transmission starts with a falling edge of CSB and ends with the rising edge. During transmission, commands and data are controlled by SCK and CSB according to the following rules: • commands and data are shifted; MSB first, LSB last • each output data/status bits are shifted out on the falling edge of SCK (MISO line) • each bit is sampled on the rising edge of SCK (MOSI line) • after the device is selected with the falling edge of CSB, an 8-bit command is received. The command defines the operations to be performed • the rising edge of CSB ends all data transfer and resets internal counter and command register • if an invalid command is received, no data is shifted into the chip and the MISO remains in high impedance state until the falling edge of CSB. This reinitializes the serial communication. • In order to perform other commands than those listed in Table 1, the lock register content must be set correctly. If such a command is fed without setting the correct lock register content, no data will be shifted into the chip and the MISO remains in high impedance state until the falling edge of CSB. • data transfer to MOSI continues immediately after receiving the command in all cases where data is to be written to ASIC’s internal registers • data transfer out from MISO starts with the falling edge of SCK immediately after the last bit of the SPI command is sampled in on the rising edge of SCK • maximum SPI clock frequency is 500kHz • maximum data transfer speed for RDAX and RDAY is 6600 samples per sec / channel SPI command can be either an individual command or a combination of command and data. In the case of combined command and data, the input data follows uninterruptedly the SPI command and the output data is shifted out parallel with the input data. 7 6 5 4 3 2 1 0 7 6 5 4 3 2 1 0 CSB SCK M ISO M OSI 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 H IGH IM PED ANCE COM M AND DATA IN DATA OU T Figure 2. Command and data transmission over the SPI After power up, the circuit starts to operate in Measure mode. This is the normal operation mode that is used for the applications. 19 Sep 2005 VTI Technologies reserves all rights to modify this document prior notice. Technica 3(5) DIGITAL INTERFACE SPECIFICATION (TABLE 1) Parameter Condition Min Typ Max Units Digital output load @ 500 kHz 1 nF SPI clock frequency (1 500 kHz Internal AD conversion 150 µs Data transfer time @ 500 kHz 38 µs Note1. Minimum SPI frequency depends on the master microcontroller clock frequency THE SPI COMMANDS The SPI interface uses an 8-bit instruction (or command) register. The list of commands is given in Table 2. Table 2. SPI commands. The commands in Italic are in use in the 2-axis SCA100T only. Command Command format Description: MEAS 00000000 Measure mode (normal operation mode after power on) RWTR 00001000 Read and write temperature data register STX 00001110 Activate Self test for X-channel STY 00001111 Activate Self test for Y-channel RDAX 00010000 Read X-channel acceleration through SPI RDAY 00010001 Read Y-channel acceleration through SPI Measure mode (MEAS) is standard operation mode after power-up. During normal operation, MEAS command is the exit command from Self test. Read temperature data register (RWTR) reads temperature data register during normal operation without effecting the operation. Temperature data register is updated every 150 µs. The load operation is disabled whenever the CSB signal is low, hence CSB must stay high at least 150 µs prior the RWTR command in order to guarantee correct data. The data transfer is presented in Figure 3, and the data is transferred MSB first. In normal operation, it does not matter what data is written into temperature data register during the RWTR command and hence writing all zeros is recommended. Self test for X-channel (STX) activates the self test function for the X-channel (Channel 1). The Internal charge pump is activated and a high voltage is applied to the X-channel acceleration sensor element electrode. This causes the electrostatic force that deflects the beam of the sensing element and simulates the acceleration to the positive direction. The X-channel self-test is de-activated by giving the MEAS command. Self test for Y-channel (STY) activates the self test function for the Y-channel (Channel 2). The internal charge pump is activated and a high voltage is applied to the Y-channel acceleration sensor element electrode. This causes the electrostatic force that deflects the beam of the sensing element and simulates the acceleration to the positive direction. The Y-channel self-test is de-activated by giving the MEAS command. Note! This command is valid for the 2-axis SCA100T only. Read X-channel acceleration (RDAX) accesses the AD converted X-channel (Channel 1) acceleration signal stored in acceleration data register X. During normal operation, acceleration data register X is reloaded every 150 µs. The load operation is disabled whenever the CSB signal is low, hence CSB must stay high at least 150 µs prior the RDAX command in order to guarantee correct data. Data output is an 11-bit digital word that is fed out MSB first and LSB last. (see Figures 3 and 4). 19 Sep 2005 VTI Technologies reserves all rights to modify this document without prior notice. l Note 15 Technical Note 15 4(5) Read Y-channel acceleration (RDAY) accesses the AD converted Y-channel (Channel 2) acceleration signal stored in acceleration data register Y. During normal operation acceleration data register Y is reloaded every 150 µs. The load operation is disabled whenever the CSB signal is low, hence CSB must stay high at least 150 µs prior the RDAY command in order to guarantee correct data. Data output is an 11-bit digital word that is fed out MSB first and LSB last. Note! This command is valid for the 2-axis SCA100T only. RDAX COMMAND AND DATA TRANSMISSION OVER THE SPI (FIGURE 3) MSB MISO in high-impedance during 8-bit command. MOSI data = 16 (in decimal format) MISO data = 975 (in decimal format) LSB 0 1 1 1 1 0 0 1 1 1 1 0 0 0 1 0 0 0 0 SPI BUS TIMING DIAGRAM (FIGURE 4) CSB SCK MOSI MISO TLS1 TCH THOL TSET TVAL1 TVAL2 TLZ TLS2 TLH MSB in MSB out LSB in LSB outDATA out DATA in TCL 19 Sep 2005 VTI Technologies reserves all rights to modify this document without prior notice. Technical Note 15 5(5) DC CHARACTERISTICS OF THE SPI INTERFACE (TABLE 3) Parameter Conditions Symbol Min Typ Max Unit Input terminal CSB Pull up current VIN = 0 V IPU 13 22 35 µA Input high voltage VIH 4 Vdd+0.3 V Input low voltage VIL -0.3 1 V Hysteresis VHYST 0.23*Vdd V Input capacitance CIN 2 pF Input terminal MOSI, SCK Pull down current VIN = 5 V IPD 9 17 29 µA Input high voltage VIH 4 Vdd+0.3 V Input low voltage VIL -0.3 1 V Hysteresis VHYST 0.23*Vdd V Input capacitance CIN 2 pF Output terminal MISO Output high voltage I > -1mA VOH Vdd-0.5 V Output low voltage I < 1 mA VOL 0.5 V Tristate leakage 0 < VMISO < Vdd ILEAK 5 100 pA Supply voltage is 5 V unless otherwise noted. Current flowing into the circuit have positive values. AC CHARACTERISTICS OF THE SPI INTERFACE (TABLE 4) Parameter Conditions Symbol Min Typ Max Unit Terminal CSB, SCK Time from CSB (10%) to SCK (90%)(1 TLS1 120 ns Time from SCK (10%) to CSB (90%)(1 TLS2 120 ns Terminal SCK SCK low time Load capacitance at MISO < 2 nF TCL 1 µs SCK high time Load capacitance at MISO < 2 nF TCH 1 µs Terminal MOSI, SCK Time from changing MOSI (10%, 90%) to SCK (90%)(1. Data setup time TSET 30 ns Time from SCK (90%) to changing MOSI (10%,90%)(1. Data hold time THOL 30 ns Terminal MISO, CSB Time from CSB (10%) to stable MISO (10%, 90%)(1. Load capacitance at MISO < 15 pF TVAL1 10 100 ns Time from CSB (90%) to high impedance state of MISO(1. Load capacitance at MISO < 15 pF TLZ 10 100 ns Terminal MISO, SCK Time from SCK (10%) to stable MISO (10%, 90%)(1. Load capacitance at MISO < 15 pF TVAL2 100 ns Terminal CSB Time between SPI cycles, CSB at high level (90%) TLH 15 µs When using SPI commands RDAX, RDAY, RWTR: Time between SPI cycles, CSB at high level (90%) TLH 150 µs (1 not production tested 19 Sep 2005 VTI Technologies reserves all rights to modify this document without prior notice. VTI Technologies Oy Myllynkivenkuja 6 VTI Technologies, Inc. One Park Lane Blvd. VTI Technologies Oy Frankfurt Branch P.O.Box 27 FIN-01621 Vantaa Suite 804 - East Tower Dearborn, MI 48126 Rennbahnstr. 72-74 D-60528 Frankfurt am Main Finland Tel. +358 9 8791 81 Fax. +358 9 8791 8791 sales@vti.fi USA Tel. (313) 425 0850 Fax (313) 425 0860 sales@vtitechnologies.com Germany Tel. +49 69 6786 880 Fax +49 69 6786 8829 sales.de@vti.fi 150 (s Input terminal CSB Input terminal MOSI, SCK Output terminal MISO
/
本文档为【SPI总线规范】,请使用软件OFFICE或WPS软件打开。作品中的文字与图均可以修改和编辑, 图片更改请在作品中右键图片并更换,文字修改请直接点击文字进行修改,也可以新增和删除文档中的内容。
[版权声明] 本站所有资料为用户分享产生,若发现您的权利被侵害,请联系客服邮件isharekefu@iask.cn,我们尽快处理。 本作品所展示的图片、画像、字体、音乐的版权可能需版权方额外授权,请谨慎使用。 网站提供的党政主题相关内容(国旗、国徽、党徽..)目的在于配合国家政策宣传,仅限个人学习分享使用,禁止用于任何广告和商用目的。

历史搜索

    清空历史搜索