Skip to content

Improve pulseInLong() description #371

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

Merged
merged 4 commits into from
Jun 11, 2018
Merged

Improve pulseInLong() description #371

merged 4 commits into from
Jun 11, 2018

Conversation

per1234
Copy link
Collaborator

@per1234 per1234 commented Jun 4, 2018

  • Explain difference between pulseIn() and pulseInLong().
  • Improve the explanation of pulseInLong()'s pulse handling.
  • Improve documentation of how pulseInLong()'s timeout works.
  • Use consistent formatting in pulseInLong() description.

per1234 added 4 commits June 3, 2018 16:58
Likely the question "What's the difference between this and pulseIn()" will be the first thing a user will want to know when visiting this page. Although this information was somewhat alluded to at the end of the description, it's much better for it to be at the start of the text.

Reference:
arduino/Arduino#2495 (comment)
Previously there was an initial incomplete description of how pulses are handled, followed by a note clarifying how it actually works. Combining all the information into a single statement avoids confusion and makes the documentation less verbose.
Previously it was not clear that the function returns after the timeout expires.
Code markdown was used on some instances of the words HIGH and LOW and not on others. A search of the rest of the reference pages shows them to be quite inconsistent in formatting but code markdown is used in the majority of instances and I feel that's the correct usage.
@SimonePDA SimonePDA merged commit c92c8f7 into arduino:master Jun 11, 2018
@per1234 per1234 deleted the pulseInLong branch June 11, 2018 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants