Skip to content

Wire library support for TWI General Call #49

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 7 commits into from

Conversation

edbaafi
Copy link

@edbaafi edbaafi commented Nov 11, 2011

This patch adds TWI (I2C) "General Call" capabilities to the Wire library

General call is like a broadcast that can be received by many listeners at the same same. This is useful when you don't know the address of the device you want to talk to or it can be used as a sort of interrupt over the TWI. While it was possible to enable general call from an Arduino user program simply by setting the TWGCE bit in the TWAR, it was not possible to determine which address the data came from.

TwoWire::onReceive is overridden to add an optional second callback which will be called whenever data is received over the general call address.

This patch addresses issue 120 (http://code.google.com/p/arduino/issues/detail?id=120) and its use is reasonably well documented in the example code.

Thanks,
Ed

@ffissore ffissore added the New label Feb 27, 2014
@cmaglie cmaglie added feature request A request to make an enhancement (not a bug fix) Library: Wire The Wire Arduino library Architecture: AVR Applies only to the AVR microcontrollers (Uno, etc.) labels Apr 8, 2015
@q2dg
Copy link

q2dg commented Aug 16, 2015

Could it be expanded to ARM-based boards?

tbowmo pushed a commit to tbowmo/Arduino that referenced this pull request Jul 14, 2016
fix convBuf size to print P_CUSTOM payloads
facchinm pushed a commit to arduino/ArduinoCore-avr that referenced this pull request Nov 13, 2017
@facchinm
Copy link
Member

Patchset rebased and PR ready to be opened here ( https://github.com/arduino/ArduinoCore-avr/compare/pr_49?expand=1 ).
If someone is still interested in "sponsoring" this feature, please open the PR and adopt the code 😉

@facchinm facchinm closed this Sep 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Architecture: AVR Applies only to the AVR microcontrollers (Uno, etc.) feature request A request to make an enhancement (not a bug fix) Library: Wire The Wire Arduino library
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants