摘要
Atmel公司的TWI(Two-wire Serial Interface)接口是对I2C总线接口的继承和发展,完全兼容I2C总线,具有硬件实现简单、软件设计方便、运行可靠和成本低廉的优点。介绍了在TWI通信过程中使用到的Atmega128单片机、Atmega16单片机对应寄存器的功能及设置方法,以及一个以Atmel公司Atmega128单片机为主机、Atmega16单片机为从机的TWI多机通信系统的软、硬件设计。
TWI (Two-wire Serial Interface) interface in Atmel Corporation is developed from I^2C bus interface. The advantages of interface are fully compatible with I^2C bus interface, easy to be implemented, convenient software design, reliable operating and low cost. This paper introduces the settings and functions of registers in Atmega128 and Atmega16 microprocessors which are used in the process of TWI communication, and expounds the hardware and software design of a multi-machine TWI communication system in which the Atmega128 MCU is operated as master mode and Atmega16 MCUs are operated as slave mode.
出处
《装备制造技术》
2008年第6期96-98,共3页
Equipment Manufacturing Technology