NB3H5150 I2C Programming Guide. I2C/SMBus Custom Configuration Application Note



Similar documents
The I2C Bus. NXP Semiconductors: UM10204 I2C-bus specification and user manual HAW - Arduino 1

DS Wire Digital Thermometer and Thermostat

USB2.0 <=> I2C V4.4. Konverter Kabel und Box mit Galvanischetrennung

Data Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide

AN601 I2C 2.8 Communication Protocol. SM130 SM130 - Mini APPLICATION NOTE

DS1307ZN. 64 x 8 Serial Real-Time Clock

Definitions and Documents

RS-485 Protocol Manual

UM I 2 C-bus specification and user manual. Document information

Arbitration and Switching Between Bus Masters

FM75 Low-Voltage Two-Wire Digital Temperature Sensor with Thermal Alarm

Table 1: Address Table

AN141 SMBUS COMMUNICATION FOR SMALL FORM FACTOR DEVICE FAMILIES. 1. Introduction. 2. Overview of the SMBus Specification. 2.1.

Allows the user to protect against inadvertent write operations. Device select and address bytes are Acknowledged Data Bytes are not Acknowledged

DS18B20 Programmable Resolution 1-Wire Digital Thermometer

DS1621 Digital Thermometer and Thermostat

The I 2 C-bus and how to use it (including specifications)

Designing VM2 Application Boards

7 OUT1 8 OUT2 9 OUT3 10 OUT4 11 OUT5 12 OUT6 13 OUT7 14 OUT8 15 OUT9 16 OUT10 17 OUT11 18 OUT12 19 OUT13 20 OUT14 21 OUT15 22 OUT16 OUT17 23 OUT18

PACKAGE OUTLINE DALLAS DS2434 DS2434 GND. PR 35 PACKAGE See Mech. Drawings Section

MAX5417L Evaluation Kit/Evaluation System

Consult protocol, Nissan Technical egroup, Issue 6

DS1621 Digital Thermometer and Thermostat

MODULE BOUSSOLE ÉLECTRONIQUE CMPS03 Référence :

Programming Specifications

Adafruit MCP9808 Precision I2C Temperature Sensor Guide

eztcp Technical Document Modbus/TCP of eztcp Caution: Specifications of this document may be changed without prior notice for improvement.

I 2 C Master Mode Overview and Use of the PICmicro MSSP I 2 C Interface with a 24xx01x EEPROM

DS1821 Programmable Digital Thermostat and Thermometer

NTE2053 Integrated Circuit 8 Bit MPU Compatible A/D Converter

- 35mA Standby, mA Speaking pre-defined phrases with up to 1925 total characters.

Table 1 below is a complete list of MPTH commands with descriptions. Table 1 : MPTH Commands. Command Name Code Setting Value Description

HP03 BAROMETER MODULE Version: 1.1

Microprocessor & Assembly Language

SRF08 Ultra sonic range finder Technical Specification

Wireless Temperature

A DIY Hardware Packet Sniffer

The Answer to the 14 Most Frequently Asked Modbus Questions

PLL frequency synthesizer

HDMM01 V1.0. Dual-axis Magnetic Sensor Module With I 2 C Interface FEATURES. Signal Path X

Internal Oscillator. I 2 C Interface. SPI Interface. Controller. Internal Registers Port Controller. Eight I/O Pins. Figure 1.

AN2680 Application note

Programming Flash Microcontrollers through the Controller Area Network (CAN) Interface

LM75A. 1. General description. 2. Features. Digital temperature sensor and thermal watchdog

AVR151: Setup and Use of the SPI. Introduction. Features. Atmel AVR 8-bit Microcontroller APPLICATION NOTE

NHD-0420D3Z-FL-GBW-V3

Develop a Dallas 1-Wire Master Using the Z8F1680 Series of MCUs

SSD1306. Advance Information. 128 x 64 Dot Matrix OLED/PLED Segment/Common Driver with Controller

ARM Ltd 110 Fulbourn Road, Cambridge, CB1 9NJ, UK.

LM75 Digital Temperature Sensor and Thermal Watchdog with Two-Wire Interface

Embedded Multi-Media Card Specification (e MMC 4.5)

AVR315: Using the TWI Module as I2C Master. Introduction. Features. AVR 8-bit Microcontrollers APPLICATION NOTE

Serial Communications / Protocol in AirTest Products

Understanding SAE J1939. by Simma Software, Inc.

Modbus and ION Technology

1-to-8 I 2 C Bus Switches/Multiplexers with Bus Lock-Up Detection, Isolation, and Notification

MICROPROCESSOR. Exclusive for IACE Students iacehyd.blogspot.in Ph: /422 Page 1

AVR311: Using the TWI Module as I2C Slave. Introduction. Features. AVR 8-bit Microcontrollers APPLICATION NOTE

Application Note 120 Communicating Through the 1-Wire Master

ESPA Nov 1984 PROPOSAL FOR SERIAL DATA INTERFACE FOR PAGING EQUIPMENT CONTENTS 1. INTRODUCTION 2. CHARACTER DESCRIPTION

Chapter 5 Real time clock by John Leung

BV4512. I2C-LCD- 128 x 64 Graphic Controller. Product specification. November 2008 V0.a. ByVac Page 1 of 14

PCT General description. I 2 C-bus Fm+, 1 degree C accuracy, digital temperature sensor and thermal watchdog

PCA9564 Parallel bus to I 2 C-bus controller INTEGRATED CIRCUITS Sep 01. Product data sheet Supersedes data of 2004 Jun 25

MCP3426/7/8. 16-Bit, Multi-Channel ΔΣ Analog-to-Digital Converter with I 2 C Interface and On-Board Reference. Features.

MicroMag3 3-Axis Magnetic Sensor Module

Data sheet Wireless UART firmware version 4.02

AN3155 Application note

Elettronica dei Sistemi Digitali Costantino Giaconia SERIAL I/O COMMON PROTOCOLS

Web Site: Forums: forums.parallax.com Sales: Technical:

THE I 2 C-BUS SPECIFICATION VERSION 2.1 JANUARY document order number:

User Manual. AS-Interface Programmer

AN736. An I 2 C TM Network Protocol for Environmental Monitoring THE I 2 C BUS SPECIFICATION INTRODUCTION

SKYEMODULE GEMINI DATASHEET VERSION

Microcontroller Based Low Cost Portable PC Mouse and Keyboard Tester

Part 1. MAX BIT DAC with an Arduino Board. MIDI to Voltage Converter Part1

1.Eastron SDM220Modbus Smart Meter Modbus Protocol Implementation V1.0

Appendix B RCS11 Remote Communications

ZL30136 GbE and Telecom Rate Network Interface Synchronizer

Accessing I2C devices with Digi Embedded Linux 5.2 example on Digi Connect ME 9210

INTEGRATED CIRCUITS PCA9530, PCA9531, PCA9532, PCA9533, PCA9550, PCA9551, PCA9552, PCA9553, SAA1064

USING I2C WITH PICAXE

FUNCTIONAL BLOCK DIAGRAM SDA SCL SMBALERT. SMBus SERIAL BUS INTERFACE ADDRESS SELECTION PWM CONFIG AUTOMATIC FAN SPEED CONTROL REGISTERS

ECE 358: Computer Networks. Homework #3. Chapter 5 and 6 Review Questions 1

64 x 8, Serial, I 2 C Real-Time Clock

CHAPTER 11: Flip Flops

UniPi technical documentation REV 1.1

Next Generation Intelligent LCDs

HOST Embedded System. SLAVE EasyMDB interface. Reference Manual EasyMDB RS232-TTL. 1 Introduction

DS2401 Silicon Serial Number

AN Driving I 2 C-bus signals over twisted pair cables with PCA9605. Document information

MCP4017/18/19. 7-Bit Single I 2 C Digital POT with Volatile Memory in SC70. Package Types. Features. Device Features. Rheostat

2-wire Serial EEPROM AT24C512

SERIAL INTERFACE. Series SSW-03 and 04

Hardware Connections between Arduino and IMU Nori Wilkins Apr. 5, 2013

Micro SDSC / SDHC / SDXC. Micro SD Data Sheet

MTS Master Custom Communications Protocol APPLICATION NOTES

Design and Verification of Nine port Network Router

DS1990A-F5. Serial Number ibutton TM

BV4513 Serial LED Display. Product specification. October 2009 V0.a. ByVac Page 1 of 19

Transcription:

NB3H550 I2C Programming Guide I2C/SMBus Custom Configuration Application Note 3/4/206

Table of Contents Introduction... 3 Overview Process of Configuring NB3H550 via I2C/SMBus... 3 Standard I2C Communication Protocol... 4 Standard I2C Communication Protocol Sequence... 4 Byte Write Sequence... 4 Byte Read Sequence... 4 Byte Block Write/Read Sequence... 4 I2C/SMBus Programming & Operation with NB3H550... 5 SDA/SCL Serial Hardware Interface with NB3H550... 5 Device Slave Address Selection for NB3H550... 6 User Programming Procedure... 6-8 Electrical and Timing Specifications... 9

Introduction This application note provides details on configuring the NB3H550 by writing to registers in the NB3H550 through the I2C/SMBus interface. Overview Process of Configuring a GUI style register file for the NB3H550 and programming this file into the device registers via the I2C/SMBus. The user will select the following: Desired Register file from ON Semiconductor Website or from the NB3H550 GUI register file folder. Standard I2C Communication Protocol Byte Read/Write Reading or writing a register in a SMBus slave device in byte mode always involves specifying the register number. Read. The standard byte read is as shown in the following figure. It is an extension of the byte write. The write start condition is repeated then the slave device starts sending data and the master acknowledges it until the last byte is sent. The master terminates the transfer with a NAK, then a stop condition. For byte operation, the 2*7 th bit of the command byte must be set. For block operations, the 2*7 th bit must be reset. If the bit is not set, the next byte must be the byte transfer count. T Slave Wr A Command 7 A r Slave Rd A 8 Data Byte 0 N P start Register # to read 2*7 bit = Command Repeat start Not ack stop Byte Read Protocol Figure. Byte Read Protocol Write. The following figure illustrates a simple typical byte write. For byte operation the 2*7th bit of the command byte must be set. For block operations, the 2*7th bit must be reset. If the bit is not set, the next byte must be the byte transfer count. The count can be between and 32. It is not allowed to be zero or exceed 32. T Slave Wr A Command A Data Byte 0 A P Register # to write start 2*7 bit = stop Command Byte Write Protocol M to S to Master to Slave to Figure 2. Byte Write Protocol

Block Read/Write Read. After the slave address is sent with the r/w condition bit set, the command byte is sent with the MSB = 0. The slave Ack s the register index in the command byte. The master sends a repeat start function. After the slave Ack s this, the slave sends the number of bytes it wants to transfer (>0 and <33). The master Ack s each byte except the last and sends a stop function. T Slave Wr A Command Code A r Slave Rd A start Register # to write 2*7 bit = 0 repeat start Command Data Byte A Data Byte 0 A Data Byte N P Block Read Protocol Not acknowledge stop Figure 3. Block Read Protocol Write. After the slave address is sent with the r/w condition bit not set, the command byte is sent with the MSB = 0. The lower seven bits indicate what register to start the transfer at. If the command byte is 00h, the slave device will be compatible with existing block mode slave devices. The next byte of a write must be the count of bytes that the master will transfer to the slave device. The byte count must be greater than zero and less than 33. Following this byte are the data bytes to be transferred to the slave device. The slave device always acknowledges each byte received. The transfer is terminated after the slave sends the Ack and the master sends a stop function. T Slave Address Wr A Command A M to S to Master to Slave to Register # to write 2*7 bit = 0 Command bit Byte Count = 2 A Data Byte 0 A Data Byte A P Block Write Protocol stop Figure 4. Block Write Protocol 4

I2C/SMBus Programming & Operation with NB3H550 SDA/SCL Serial Hardware Interface with NB3H550 The NB3H550 provides an I2C / SMBus digital interface that can be used with any standard 2-wire I2C host device. Configuration, control and operation of the NB3H550 are handled by reading and writing to the RAM space using the I2C/SMBus interface. The I2C bus consists of a bidirectional serial data line (SDA) and a serial clock input (SCL) as shown in Figure 9. In addition, the NB3H550 operates as a slave device on the 2-wire SDA/SCL serial bus, compatible with the popular SMBus version 2.0 or I2C specification. To enable the NB3H550 to be in I2C/SMBus mode, both the SDA and SCL/PD pins must be connected to the VDD supply via external pull-up resistors on the I2C/SMBus. Recommend 0k-Ω. The NB3H550 operates in Standard-Mode transfer up to 00 kbps and supports 7-bit addressing. 5

Device Slave Address Selection for NB3H550 When communicating with multiple I2C/SMBus devices using the I2C/SMBus interface, each device must have its own unique address so the host can distinguish between the devices. Only the device with a matching slave address responds to subsequent I2C commands. The device whose address corresponds to the transmitted address will respond by sending an acknowledge bit. All other devices on the bus remain idle while the selected device waits for data transfer with the master. These slave devices are accessed via a 7-bit slave address transmitted as part of an I2C packet. The NB3H550 allows up to nine unique NB3H550 slave devices to be used in the system in addition to any other I2C slave device with a different I2C address. Slave addresses for the NB3H550 are shown in Table 2. The NB3H550 slave address is defined and can be set according to the pin-strap options listed in Table 8 of the datasheet and is set when the MMC pin is Low. * FS4A and FS4B float to Mid-level when open. User Programming Procedure SMBus / I2C selection The NB3H550 (by default on power-up) is in SMBus mode. The bit to change between SMBus and I2C modes is located in Register 0x08 bit 5. Do not change any other bits in byte address 0x08 other than Bit 5. The other bits are reserved and must never be set to logic. 6

Byte 0x08 Bit Description If Bit = 0 If Bit = Type Default Bank Switching Operation 0 Reserved 0 Reserved 0 2 Reserved 0 3 Reserved 0 4 Reserved 0 5 SMBus mode I2C mode 0,SMBus 6 Reserved 0 7 Reserved 0 I2C can only access 256 addresses directly (i.e. 0x00 through 0xFF). SMBus can only access 28 addresses directly (i.e. 0x00 through 0x7F). NB3H550 has an address space which goes up to 0x4F. Therefore, a bank switching mechanism is included to allow access to all addresses no matter which bus protocol is used. Effectively, the two bank select bits are appended to the most-significant end of the seven-bit byte offset, creating a nine-bit address. The bank switch control bits(6:7) are located in Register 0x2. The most significant two bits of that register are used for bank selection; the least significant six bits are used for the READBYTECOUNT Function. A provision has been made to always be able to access the register which controls the bank selection, no matter which bank is currently selected. An SMBus byte mode operation on the register (SMBUSCTL), or an I2C operation on the 0x2 register, where that register is the first (or only) byte of the operation will unconditionally be routed to the 0x2 register, no matter what the bank select bits are. Conversely, this means that Read/Write performed with SMBus block-mode operations, or Read/Writes on all but the first byte of a multi-byte I2C operation will use the bank select bits in forming the effect address. NOTE: It is not possible to cross from one bank to another in a block mode operation. SMBus Mode Address Bank Selection: Byte 0x2, Bits 7:6 SMBus Mode Bank SMBus Byte Offset NB3H550 Registers Accessed 00 0x00-0x7F 0x00-0x7F 0 2 0x00-0x7F 0x80-0xFF 0 3 0x00-0x7F 0x00-0x7F 4 0x00-0x7F 0x80-0xFF 7

I2C Mode Address Bank Selection: Register 0x2, Bits 7:6 I2C Mode Bank I2C Byte Offset NB3H550 Registers Accessed 0x 0x00-0xFF 0x00-0xFF x 2 0x00-0xFF 0x00-0xFF READBYTECOUNT bits The least-significant bits in the SMBUSCTL register are for the READ byte count. This controls the number of bytes of data that the device will return on an I2C/SMBus Block Read operation. Typically, these six bits would be set to 0x20 (32 decimal) which is the maximum allowed by the SMBus protocol. The SMBus master can read fewer than this number in a block read without any adverse consequences. 8

Electrical and Timing Specifications AC and DC electrical specifications for the SCL and SDA pins are shown in Table 3. The timing specifications and timing diagram for the I2C bus are compatible with the I2C-Bus Standard. 9