Skip to content

customizer: gpio_motors becomes ptz_gpio, with ptz_control naming the method - #140

Merged
openipc-ai merged 1 commit into
masterfrom
customizer-ptz-gpio
Aug 31, 2026
Merged

customizer: gpio_motors becomes ptz_gpio, with ptz_control naming the method#140
openipc-ai merged 1 commit into
masterfrom
customizer-ptz-gpio

Conversation

@openipc-ai

Copy link
Copy Markdown
Contributor

Completes the #227 PTZ env rename (majestic-webui#232, firmware#2341) in the last place still writing the old name, as requested by @flyrouter in majestic-webui#227: the three customizer.sh files carrying fw_setenv gpio_motors … now write ptz_gpio instead. The gpio-motors utility reads ptz_gpio first and falls back to gpio_motors since firmware#2341, and it is the only consumer of the variable anywhere in the org, so the rename is mechanical.

Each device also gains fw_setenv ptz_control gpio — not part of the rename, but required by it: the WebUI is dropping its auto-detection from a bare pin list (unset ptz_control now means no PTZ, per flyrouter's ruling on the same issue; majestic-webui#255). Without the method named, these devices would keep their motors but lose their pads.

  • devices/t23_lite_jooan-q3r-u — active, 5 pins
  • devices/ssc30kd_lite_cmcc-ds-ytj5301 — active, 8 pins
  • devices/t23_lite_jooan-a6m-u — the pin line was commented out, so both new lines are commented there too

… method

The #227 PTZ env rename (majestic-webui#232, firmware#2341) made ptz_gpio
the documented pin-list variable, with gpio_motors kept as a compatibility
alias. These three customizers were the remaining writers of the old name;
flyrouter asked for them to move to the new format
(OpenIPC/majestic-webui#227).

Each also gains 'fw_setenv ptz_control gpio': the WebUI is dropping its
auto-detection from a bare pin list (unset ptz_control now means no PTZ,
per the same issue — majestic-webui#255), so the method must be named for
the pad to appear. In t23_lite_jooan-a6m-u the pin line was commented out,
so both new lines are commented there too.
@qodo-free-for-open-source-projects

Copy link
Copy Markdown

PR Summary by Qodo

Migrate device PTZ settings to the documented environment names

⚙️ Configuration changes 🕐 Less than 10 minutes

Grey Divider

AI Description

• Renames remaining motor pin environment settings from gpio_motors to ptz_gpio.
• Declares GPIO as the PTZ control method for two active device profiles.
• Preserves disabled PTZ settings as commented templates for the Jooan A6M-U.
Diagram

graph TD
  A["Active customizers"] -->|set method and pins| C["fw_setenv"] --> D[("PTZ environment")] -->|pin list| E["GPIO motors"]
  B["Disabled customizer"] -.->|commented template| C
  D -->|method selection| F["WebUI controls"]
Loading
High-Level Assessment

The direct rename plus explicit ptz_control=gpio declaration is the appropriate migration because the motor utility already provides legacy read compatibility while the WebUI now requires an explicit method. Dual-writing gpio_motors and ptz_gpio was considered but would preserve deprecated configuration without improving compatibility.

Files changed (3) +6 / -3

Other (3) +6 / -3
customizer.shAdopt explicit GPIO PTZ environment settings +2/-1

Adopt explicit GPIO PTZ environment settings

• Replaces the active 'gpio_motors' pin list with 'ptz_gpio' and sets 'ptz_control' to 'gpio'. The existing eight-pin mapping remains unchanged.

devices/ssc30kd_lite_cmcc-ds-ytj5301/general/overlay/usr/share/openipc/customizer.sh

customizer.shRename the disabled PTZ configuration template +2/-1

Rename the disabled PTZ configuration template

• Renames the commented motor pin setting to 'ptz_gpio' and adds a matching commented 'ptz_control gpio' line. PTZ remains disabled for this profile.

devices/t23_lite_jooan-a6m-u/general/overlay/usr/share/openipc/customizer.sh

customizer.shMigrate active motor pins to PTZ environment settings +2/-1

Migrate active motor pins to PTZ environment settings

• Replaces the active 'gpio_motors' setting with 'ptz_gpio' and explicitly selects GPIO PTZ control. The existing five-pin mapping is preserved.

devices/t23_lite_jooan-q3r-u/general/overlay/usr/share/openipc/customizer.sh

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Tip of the day
💡 Did you know, you can type 'qodo, fix this' on a finding and the fix lands right on your PR

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

@openipc-ai
openipc-ai merged commit b226740 into master Aug 31, 2026
8 checks passed
@openipc-ai
openipc-ai deleted the customizer-ptz-gpio branch August 31, 2026 11:29
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