Skip to content

i2c: address format #88

@chrysn

Description

@chrysn

I've encountered i2c addresses both in on-the-wire format (typically given as an even number, between 0 and 254, to which 1 is ORed for reads) and in 7-bit format (a number between 0 and 127).

Which one of those is addr in the read/write/write_read functions supposed to be?

If it's 7-bit, I'd add a "Slave addresses are always given as 7-bit numbers (0 <= address < 128)." in the module documentation, and maybe change "SAD+R = slave address with 8th bit set to 1" to "SAD+R = slave address followed by bit 1" and similar at the function level. (Can provide a PR if that's the intention).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions