Skip to content

Test command write #29

@EgartSites

Description

@EgartSites

case SMB_TEST_COMMAND_WRITE:
while (EP0CS&bmEPBUSY); // wait until ready
*EP0BUF = 0;
if (!i2c_start()) return FALSE;
if (!i2c_byteout(smb_addr)) goto tcwOver;
if (i2c_byteout(smb_cmd)) { (*EP0BUF)++; // Command ACK = command exists
} else {goto tcwOver;}
if (i2c_byteout(3)) { (*EP0BUF)++; // Data Byte #1 ACK = byte writable
} else {goto tcwOver;}
if (i2c_byteout(0)) { (*EP0BUF)++; // Data Byte #2 ACK = word writable
} else {goto tcwOver;}
if (!i2c_byteout(0)) {goto tcwOver;}
if (i2c_byteout(0)) { (*EP0BUF)++; // Data Byte #4 ACK = block writable
} else {goto tcwOver;}
if (i2c_byteout(0)) { (*EP0BUF)++; // Data Byte #5 ACK = >block writable
} else {goto tcwOver;}

Please, make me understand why first out byte is 0x03 ? I think, it should be 0x00 like others byte.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions