[an error occurred while processing this directive]
readme.txt
(«Телесистемы»: Конференция «Микроконтроллеры и их применение»)
миниатюрный аудио-видеорекордер mAVR

Отправлено Sergey Pinigin 15 июля 2002 г. 09:55
В ответ на: smpl90f543v01r02.exe\90F543\Soft_I2C подойдет для любого MB90F отправлено Sergey Pinigin 15 июля 2002 г. 09:26

The project soft_i2c is emulating an I2C bus interface for 8-Bit addressing,
using two standard I/O ports:
SDA - port 34 (HRQ)
SCL - port 35 (HAK)

Note:
Clock synchronisation mechanisms and arbitration procedures are not considered
within here. The example has been used to communicate with an M24C08. Memory
acceses are restricted to 8-bit addresses. The device slave address can be
changed with a define instruction.

Implemented functions:

I2C_Start - generate start condition
I2C_Stop - generate stop condition
I2C_Read_Byte - read byte from I2C memory
I2C_Write_Byte - write byte to I2C memory
I2C_Read_Ack - read Acknowledge from I2C bus device

I2C-Write_Device - complete sequence to write a byte to I2C memory address
I2C_Read_Device - complete sequence to read a byte from I2C memory address

Note:
For no high speed I2C devices, it would be necessary to add some further
wait states within these functions to ensure the proper timing.

Составить ответ  |||  Конференция  |||  Архив

Ответы



Перейти к списку ответов  |||  Конференция  |||  Архив  |||  Главная страница  |||  Содержание  |||  Без кадра

E-mail: info@telesys.ru