00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _TWI_H_
00021 #define _TWI_H_ 1
00022
00023
00024
00025 #define TW_START 0x08
00026 #define TW_REP_START 0x10
00027
00028 #define TW_MT_SLA_ACK 0x18
00029 #define TW_MT_SLA_NACK 0x20
00030 #define TW_MT_DATA_ACK 0x28
00031 #define TW_MT_DATA_NACK 0x30
00032 #define TW_MT_ARB_LOST 0x38
00033
00034 #define TW_MR_ARB_LOST 0x38
00035 #define TW_MR_SLA_ACK 0x40
00036 #define TW_MR_SLA_NACK 0x48
00037 #define TW_MR_DATA_ACK 0x50
00038 #define TW_MR_DATA_NACK 0x58
00039
00040 #define TW_ST_SLA_ACK 0xA8
00041 #define TW_ST_ARB_LOST_SLA_ACK 0xB0
00042 #define TW_ST_DATA_ACK 0xB8
00043 #define TW_ST_DATA_NACK 0xC0
00044 #define TW_ST_LAST_DATA 0xC8
00045
00046 #define TW_SR_SLA_ACK 0x60
00047 #define TW_SR_ARB_LOST_SLA_ACK 0x68
00048 #define TW_SR_GCALL_ACK 0x70
00049 #define TW_SR_ARB_LOST_GCALL_ACK 0x78
00050 #define TW_SR_DATA_ACK 0x80
00051 #define TW_SR_DATA_NACK 0x88
00052 #define TW_SR_GCALL_DATA_ACK 0x90
00053 #define TW_SR_GCALL_DATA_NACK 0x98
00054 #define TW_SR_STOP 0xA0
00055
00056 #define TW_NO_INFO 0xF8
00057 #define TW_BUS_ERROR 0x00
00058
00059 #endif