Infineon / XMC-for-Arduino

Integration of Infineon's XMC microcontrollers into the Arduino IDE.
Other
103 stars 64 forks source link

GPIO Init after USIC CH Start #238

Closed 9Volts9er closed 1 year ago

9Volts9er commented 1 year ago

Put the GPIO_Init() after CH_Start for SPI, I2C and HardwareSerial in order to avoid false pulses as described in issue #234

By creating this pull request you agree to the terms in CONTRIBUTING.md. https://github.com/Infineon/.github/blob/master/CONTRIBUTING.md --- DO NOT DELETE ANYTHING ABOVE THIS LINE ---

Description With this PR the GPIO_Init() functions are moved after XMC_CH_Start() of I2C, SPI and HardwareSerial. This solves the issue #234 with wrong pulses output on the communication lines. Also in the respective end() functions.

See also PR #237

Related Issue

234

techpaul commented 1 year ago

Only thing missed is that SPI has THREE pins you forgot to move the SCLK pin init call in HW_SPI.cpp

techpaul commented 1 year ago

Just need same change on PR #237

boramonideep commented 1 year ago

Thanks @9Volts9er for the code changes and @techpaul for the review.