- Silicon Labs Community
- Welcome and Announcements
- Silicon Labs Knowledge Base
- 8-bit MCU
- 32-bit MCU
- Bluetooth / Wi-Fi
- Other Products Category
- Optical/RH/Temp Sensor
- Other Products
- Hardware and Software Tools
- Simplicity Studio and Software
- General Discussions and Suggestions
- Chinese Forum
- Software Libraries
- Development Kits
- Reference Designs
- Third Party Tools
- White Papers
- Official Blog of Silicon Labs
- Chinese Blog
03-07-2017 09:33 AM - last edited on 07-19-2017 02:21 PM by Siliconlabs
Currently using P0Skip and the crossbar, I can set the SMBus on P0.4 (SDA) and P0.5(SCL), but the hardware layout has the SDA and SCL pins swopped, i have read conflicting answers about if the SMBus pins can be swapped around?
03-07-2017 09:23 PM
Can you please show me the webpage of the conflicting answers ?
The pin assignments are determined by the priority of the enabled peripherals. And the priority of SDA is higer than the SCL, for my understanding, there is no way to swap the SDA/SCL pins.
03-07-2017 11:15 PM
Some of 8-bit device support SDA/SCL swap for SMBUS, for example EFM8LB1, if you read the reference manual (EFM8LB1) you could get a bitfield named SWAP that was used to control this swap feature. But for F338, I think it don't support this feature.
03-07-2017 11:15 PM
.... but the hardware layout has the SDA and SCL pins swopped, i have read conflicting answers about if the SMBus pins can be swapped around?
What does the data sheet for your device say ?
Some SiLabs parts (this from EFM8BB3) say this
"SMBus Pin Swap
The SMBus peripheral is assigned to pins using the priority crossbar decoder. By default, the SMBus signals are assigned to port pins starting with SDA on the lower-numbered pin, and SCL on the next available pin. The SWAP bit in the SMBus Timing Control register can be set to 1 to reverse the order in which the SMBus signals are assigned."
If your data does not, then there is your answer.
That said, if this is just a simple i2c master use, then you can of course, create a Software i2c that swaps the pins (or uses any pins you like).
03-08-2017 08:00 AM
I can set the SMBus on P0.4 (SDA) and P0.5(SCL), but the hardware layout has the SDA and SCL pins swopped, i have read conflicting answers about if the SMBus pins can be swapped around?
on the 8051fxxx devices they can not
I continuously get amazed to see how many do not digest the datasheet before designing the hardware