Subversion Repositories MK3Mag

Rev

Rev 32 | Rev 40 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 32 Rev 37
Line 151... Line 151...
151
            return;
151
            return;
Line 152... Line 152...
152
 
152
 
153
        case TW_SR_DATA_ACK: // data has been received and ack has been returned
153
        case TW_SR_DATA_ACK: // data has been received and ack has been returned
154
                data = TWDR;
154
                data = TWDR;
155
                        if (Rx_Idx  == 0xFF)
155
                        if (Rx_Idx  == 0xFF)
156
                        {       // if the fisrt byte after slave addressing was received
156
                        {       // if the first byte after slave addressing was received
157
                                switch(data)
157
                                switch(data)
158
                                {
158
                                {
159
                                        case I2C_CMD_VERSION:
159
                                        case I2C_CMD_VERSION:
160
                                                I2C_TxBuffer = (uint8_t *)&I2C_Version;
160
                                                I2C_TxBuffer = (uint8_t *)&I2C_Version;