Skip to content

Add TWIS module#196

Merged
jonas-schievink merged 6 commits intonrf-rs:masterfrom
kalkyl:twis
Aug 25, 2020
Merged

Add TWIS module#196
jonas-schievink merged 6 commits intonrf-rs:masterfrom
kalkyl:twis

Conversation

@kalkyl
Copy link
Copy Markdown
Contributor

@kalkyl kalkyl commented Aug 3, 2020

Added a HAL module for TWIS (I2C compatible two-wire interface peripheral, formerly referred to as an "I2C slave")

Here's a demo showing read and write operations using interrupts and multiple I2C addresses (ItsyBitsy nRF52840):
https://github.com/kalkyl/nrf-hal/blob/twis/examples/twis-demo/src/main.rs

Also added a TWIM demo that can also be used together with the above TWIS demo, to show the corresponding controller code (nRF52840-DK):
https://github.com/kalkyl/nrf-hal/blob/twis/examples/twim-demo/src/main.rs

Copy link
Copy Markdown
Contributor

@jonas-schievink jonas-schievink left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Maybe we should rename read and write to tx and rx, to clarify the data direction and distinguish them from the TWIM operations?

Comment thread examples/twis-demo/src/main.rs Outdated
Comment thread nrf-hal-common/src/twis.rs Outdated
Comment thread nrf-hal-common/src/twis.rs Outdated
kalkyl and others added 3 commits August 12, 2020 23:02
Comment thread examples/twim-demo/src/main.rs Outdated
Comment thread examples/twim-demo/src/main.rs Outdated
Comment thread examples/twim-demo/src/main.rs Outdated
@jonas-schievink jonas-schievink merged commit 5e98514 into nrf-rs:master Aug 25, 2020
@kalkyl kalkyl deleted the twis branch September 4, 2020 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants