-
Notifications
You must be signed in to change notification settings - Fork 220
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
Rename DelayUs
to BasicDelay
, add delay_ns
.
#537
Conversation
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.
Looks good to me, thanks!
What makes it "Basic"? I still prefer DelayNs in line with having DelayUs before, assuming we save Delay for some future trait, but maybe it's too confusing since it provides all three methods? I think of it as "delay with ns resolution", plus methods to delay for longer units which can trivially be done with more nanoseconds. |
I also thought about making this point, but I guess as an end user with no knowledge of these traits I wouldn't assume |
it's "basic" as "not using the fancy hypothetical future I think No strong opinion from me, I'm fine with |
Just to throw some other names into the mix:
I have no strong opinions on any of the suggestions so far, I'd be happy with any of them. |
same as
hmm I'm not sure, there's nothing inherently "imprecise" about it, it just rounds up if needed. The |
c4a98ff
to
5f7c351
Compare
As discussed in today's meeting, we should add nanosecond precision to the delay trait.
Fixes #521
Fixes #535
Though as discussed in the meeting as well, we should add configuration settings to the SpiDevice impls in
embedded-hal-bus
to do the delays, and document drivers are discouraged from usingOperation::DelayNs
for CS-to-clocks delays. Opened #537 to track this