arduino / arduino/reference-en

Ambiguous wording in `analogReadResolution` note re: setting higher resolution than supported

Open
#779 3 comments 0 reactions 1 assignee Claimed by @kengdahl View on GitHub
enhancement
Dominant language
No language data
Stars
173
Forks
704
PR merge metrics
No merged PRs in 30d

Description

In the section "Notes and Warnings" there is ambiguous wording:

> For example: using the Due with `analogReadResolution(16)` will give you an approximated 16-bit number with the first 12 bits containing the real ADC reading and the last 4 bits **padded with zeros**.

Consider revising it to:

> For example: using the Due with `analogReadResolution(16)` will give you an approximated 16-bit number with the most significant 12 bits containing the real ADC reading and the least significant 4 bits **padded with zeros**.

This would make it consistent with the wording of the following paragraph:

> If you set the `analogReadResolution()` value to a value lower than your board’s capabilities, the extra least significant bits read from the ADC will be **discarded**.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.