Repository navigation
docs/library/machine.RTC.rst Fix example code, document datetime method. - #5553
Closed
peterhinch wants to merge 1 commit into
Closed
peterhinch wants to merge 1 commit into
peterhinch wants to merge 1 commit into
Conversation
Contributor
|
Document that it's an undocumentable mess? :-) I think the best you could do is to break it out into one section per architecture. Maybe that'll inspire someone to fix it? |
Contributor
Author
|
This continues to cause problems in the forum. |
This was referenced Apr 25, 2020
|
+1 |
This was referenced Jun 11, 2021
Member
|
Thanks for this. Merged in c0499bc |
tannewt
added a commit
to tannewt/circuitpython
that referenced
this pull request
Nov 12, 2021
Improved accuracy of common_hal_mcu_delay_us of STM port.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is the minimum change to fix the example code so it actually runs.
Unfortunately documenting the RTC class is difficult because it has been implemented differently for each platform. I checked STM, ESP8266 and ESP32. All implement
datetime. Implementation ofinitis platform dependent: STM accepts no args. ESP8266 does not implement it while ESP32 requires a datetime tuple. Further, each platform implements a different set of methods and some documented methods are not implemented on any of these platforms: for example thenowmethod.Methods such as
calibrateare inherently hardware dependent but where a method is implemented across platforms its calling signature should (in my view) be consistent.There are other platforms where I don't own hardware so can't test. I'm stumped as to how properly to document this class.