Conversation
Meowcaroni
reviewed
Mar 5, 2026
| | I2CDR (data register) | 000 | R/W 0x00 | Holds the data for transmission or recently received data bytes. | | ||
| | I2CCR (Control Register) | 001 | R/W 0x00 | Enables I2C, sets Master/Slave mode, and handles Start/Stop generation. | | ||
| | I2CSR (Status Register) | 010 | R/W 0x00 | Indicates Bus Busy, Arbitration Lost, Address Match, and RX/TX Status | | ||
| | I2CBR (Baud Rate) | 011 | R/W 0x02 | Sets the clock frequency for the SCL line based on the system clock. | |
Collaborator
There was a problem hiding this comment.
Baud Rate, although applicable here, is a specific terminology for UART since it uses asynchronous clock signals. To prevent confusion, please use a different name like suggested below:
Suggested change
| | I2CBR (Baud Rate) | 011 | R/W 0x02 | Sets the clock frequency for the SCL line based on the system clock. | | |
| | I2CCD (Clock Divider) | 011 | R/W 0x02 | Sets the clock frequency for the SCL line based on the system clock. | |
| Clock Modes: Supports standard mode, 100kbps, fast-mode, 400kbps, and sometimes a high-speed mode (3.4 Mbps). For addressing it supports a standard 7-bit addressing or extended 10-bit addressing mode for identifying slaves. Multi-Master; includes built in collision detection and arbitration logic of two masters attempt to control the bus simultaneously. Pull-yps; an open-drain protocol the physical lines (SDA/SCL) require external pull-up resigstors to function. | ||
|
|
||
| Behavior & Timing: | ||
| Timing is governmed by the SCL signal. Data on the SDA line must be stable while SCL is high. Transitions on SDA while SCL is high are reserved for Start and Stop conditions. |
Collaborator
There was a problem hiding this comment.
Possibly provide a brief description of what a data transfer would look like in I2C for members
| Timing is governmed by the SCL signal. Data on the SDA line must be stable while SCL is high. Transitions on SDA while SCL is high are reserved for Start and Stop conditions. | ||
|
|
||
| Errors & Dependencies: | ||
| Errors: Managed via irq_o. Common errors are; arbitatrion lost, NACK (No acknowledge from slave) And bus overrun. |
Collaborator
There was a problem hiding this comment.
Provide one-line descriptions of errors and their causes
Collaborator
There was a problem hiding this comment.
Pretty good here too, just need a little more descriptiveness and formatting fixes. Again, please split parameter and signal tables and add heading formatting (+ bullet points if you'd like)
Meowcaroni
requested changes
Mar 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Created and added I2C Module brief for IO