Skip to content

Conversation

@sandeepmistry
Copy link
Contributor

For the SAM side of #613.

Also moved common reset and disable code in libsam TWI_ConfigureMaster and TWI_ConfigureSlave functions to new TWI_Disable function, which is used in TwoWire::end()

The TwoWire constructor now has a new end callback parameter that is used to undo any actions that were done in the begin callback.

Updated version of #3730

Copy link
Member

Choose a reason for hiding this comment

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

Mhhh, why OUTPUT? I'm expecting to see them set as INPUT

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@cmaglie upon further investigation, this code isn't needed, as the PIO_Configure calls in the Wire1_Init do not enable pull ups. I've updated this in: sandeepmistry@dd7e908

I was confused my the external SDA0 and SCL0 pull ups on the Due.

@cmaglie cmaglie added Library: Wire The Wire Arduino library feature request A request to make an enhancement (not a bug fix) labels Oct 14, 2015
@sandeepmistry sandeepmistry added the Architecture: SAM Applies only to the SAM microcontrollers (Due) label Oct 22, 2015
also moved common reset and disable code in libsam TWI_ConfigureMaster
and TWI_ConfigureSlave functions to new TWI_Disable function, which is
used in TwoWire::end()
The Due has external pull-ups on the SDA0 and SCL0, and PIO_Configure
in Wire*_Init does not enable then.
@cmaglie cmaglie merged commit 851efae into arduino:master Oct 29, 2015
@cmaglie cmaglie added this to the Release 1.6.6 milestone Oct 29, 2015
@sandeepmistry sandeepmistry deleted the sam-Wire.end-2 branch July 18, 2016 18:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Architecture: SAM Applies only to the SAM microcontrollers (Due) 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.

2 participants