-
Notifications
You must be signed in to change notification settings - Fork 143
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
Add I2C support for whole STM32 family #101
Comments
I looked at the reference manuals yesterday. I would suggest to rename the L4 I2C to |
I think this is only true for the other IP. If I didn't overlook anything the |
@rleh Are you currently working on this? It wouldn't be very efficient if we end up with 2 PRs implementing the same thing. |
This comment has been minimized.
This comment has been minimized.
CubeMX has data about e.g. <RefParameter Name="GPIO_FM6" Comment="Fast Mode" Type="list" DefaultValue="__NULL">
<PossibleValue Value="__NULL" Comment="Disable"/>
<PossibleValue Value="I2C_FASTMODEPLUS_PB6" Comment="Enable"/>
</RefParameter> <RefParameter Comment="I2C Speed Mode " DefaultValue="I2C_Standard" Group="Timing configuration" Name="I2C_Speed_Mode" Type="list">
<PossibleValue Comment="Standard Mode" Value="I2C_Standard"/>
<PossibleValue Comment="Fast Mode" Value="I2C_Fast"/>
<PossibleValue Comment="Fast Mode Plus" Semaphore="$IpInstance_FastMP" Value="I2C_Fast_Plus"/>
</RefParameter> But I don't know where |
No. |
This data is available because for |
According to CubeMX every device with the All instances of This data is somehow contradictory to the reference manuals. STM32F05xxx have no FM+ but I can configure it in CubeMX for STM32F058x8. The correct rule according to the reference manual is that every instance supports FM+ except for I2C2 on F03x, F05x and F070xB devices. |
Is there a way in lbuild to see if there are multiple instances of the peripheral? in module.lb:
but ST sometimes leaves out the postfix Or should I just create an alias between |
You mean like this? has_instances = "instance" in device.get_driver("i2c") This is just a dictionary, so you can always use the |
The above is an issue in the CAN drivers, where there's CAN or CAN1 and/or CAN2. We follow the reference manual naming here, since we don't want to rename stuff (that gets you into trouble). |
This is probably not the right solution to this problem. This relation only holds for some L4. For instance, STM32F745 has 4 I2Cs but no |
L4 controllers have |
There is a little FIXME we/I need to fix. Blame me :-O The timing blob was taken from the CubeMX. Does anybody know how to calculate these settings? Is a LUT with a bunch of common frequencies an intermediate solution? |
Closed in #118. |
There has been some work done in roboterclubaachen/xpcc#350 by @rleh
The STM32L4 driver (which is an ugly name, blame @strongly-typed), seems to be suitable also for F0, F3 and F7. I discussed with @chris-durand on Friday. I have F3 hardware here to test this.
There is the distinction between
in modm-devices.
How integrate this to modm?
The text was updated successfully, but these errors were encountered: