Add ArUco PDF, update generator, remove old PDFs#21
Open
KavinduMethpura wants to merge 6 commits intomasterfrom
Open
Add ArUco PDF, update generator, remove old PDFs#21KavinduMethpura wants to merge 6 commits intomasterfrom
KavinduMethpura wants to merge 6 commits intomasterfrom
Conversation
Add a single combined markers/aruco_markers.pdf and remove the older split PDFs (markers/pdf/ar_markers_0-5.pdf and markers/pdf/ar_markers_5-9.pdf). Update markers/marker_generator.py to match the new bundled PDF output and adjust requirements.txt accordingly.
Add README docs for markers, scripts, board and legacy scripts; update top-level README to document structure and usage. Add requirements.txt with required dependencies. Improve camera calibration (scripts/board/calibrate.py): accept .png samples, track image size, validate inputs, format and fix calibration/error calculation, and save/load helpers. Add chessboard generator and sample image. Refactor main scripts for robustness and modern OpenCV API compatibility: abstract marker detection/drawing, support ArUcoDetector or legacy API, add type hints, better string/formatting and minor bug fixes. Replace direct imports of optional deps (paho, yaml, picamera) with runtime checks that surface clear installation errors; refactor Raspberry Pi camera preview into a PreviewAnalyzer class. Update MQTT sample config to include username/password and wire credentials into client setup. Misc: various style and whitespace cleanups across previousScripts and main scripts.
Replace hardcoded config paths with SCRIPT_DIR and pathlib.Path objects, and add ensure_required_file(path, label, sample_name) to validate presence of required files and suggest sample files when missing. Open YAML files with UTF-8 encoding and pass string paths to cv.FileStorage for camera calibration. Overall improves robustness and error messages for missing config/calibration files.
Add checks to run.sh to copy config-mapping_sample.yaml and config-mqtt_sample.yaml into place if the corresponding config files are missing, and to print an error and exit if the sample files themselves are missing. Update the top-level README and scripts/README to document that ./run.sh will auto-create missing configs on first run and clarify that running script.py directly requires manually copying the sample configs.
Replace reference to the sample mapping file with the actual config filename. The ensure_required_file call now points to 'config-mapping.yaml' so the script opens the intended mapping configuration rather than the sample.
Remove automatic copying and presence checks for config-mapping and config-mqtt sample files from run.sh. The script now only changes into the scripts directory and runs script.py, avoiding accidental overwrites and simplifying startup; configuration files are expected to be managed externally.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a single combined markers/aruco_markers.pdf and remove the older split PDFs (markers/pdf/ar_markers_0-5.pdf and markers/pdf/ar_markers_5-9.pdf). Update markers/marker_generator.py to match the new bundled PDF output and adjust requirements.txt accordingly.