Skip to content

add ExtendedResolutionInvert for manual direction of the digits#4087

Open
Firat17aze wants to merge 1 commit into
jomjol:mainfrom
Firat17aze:codex/extended-resolution-invert
Open

add ExtendedResolutionInvert for manual direction of the digits#4087
Firat17aze wants to merge 1 commit into
jomjol:mainfrom
Firat17aze:codex/extended-resolution-invert

Conversation

@Firat17aze

Copy link
Copy Markdown

Problem

ExtendedResolution can produce the extra decimal digit in the wrong direction on some meters (different wheel rotation direction).

What this PR changes

  • Adds a new per-number postprocessing option: ExtendedResolutionInvert (default: false)
  • Parses config key EXTENDEDRESOLUTIONINVERT / main.ExtendedResolutionInvert
  • Threads the flag into readout logic
  • Inverts only the derived fractional digit when enabled
  • Adds unit tests for normal vs inverted behavior
  • Adds parameter docs for NUMBER.ExtendedResolutionInvert

Why this is safe

  • Default is false, so existing behavior is unchanged unless user enables it.

Testing

  • pio test -e esp32cam --without-uploading --without-testing ✅ (build/test compile pass)
  • Hardware runtime test requires attached ESP32-CAM board (not available in this environment)

Usage

Set in config.ini when needed:

  • main.ExtendedResolution = true
  • main.ExtendedResolutionInvert = true (only for meters with opposite intermediate direction)

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.

1 participant