-
-
Notifications
You must be signed in to change notification settings - Fork 9
Add bus timing helpers #114
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
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,83 @@ | ||||||
| // | ||||||
| // Copyright (c) .NET Foundation and Contributors | ||||||
| // See LICENSE file in the project root for full license information. | ||||||
| // | ||||||
|
|
||||||
| namespace nanoFramework.Device.Can | ||||||
| { | ||||||
| /// <summary> | ||||||
| /// Helper for common CAN timings for the STM32 | ||||||
|
||||||
| /// </summary> | ||||||
| public static class CanTimingSTM32 | ||||||
| { | ||||||
| /// <summary> | ||||||
| /// 25 KBaud. | ||||||
| /// </summary> | ||||||
| public static CanSettings Timing500KBaud () { | ||||||
|
||||||
| return new CanSettings(6, 8, 1, 0); | ||||||
| } | ||||||
|
|
||||||
| } | ||||||
|
|
||||||
| /// <summary> | ||||||
| /// Helper for common CAN timings for the ESP32. Values from https://github.com/espressif/esp-idf/blob/master/components/hal/include/hal/twai_types.h#L54 | ||||||
| /// </summary> | ||||||
| public static class CanTimingESP32 | ||||||
|
||||||
| public static class CanTimingESP32 | |
| public static class CanTimingEsp32 |
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please hit CTRL+K + CTRL+D to have VS auto format the code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
file name must match the name of the class, so please rename to CanTimingSTM32.cs :-)