Skip to content

Conversation

@pwittich
Copy link
Contributor

@pwittich pwittich commented Nov 10, 2025

  • Add a command to toggle the reset on the 5 clock synthesizers (CLI: clkreset , c: int resetClockSynth(int device)
  • Add more clock tests (not successful, unsure why).
  • Change the first_mcu function to allow it to be run even if it's been run before
  • Fix bug in semaphore release in MonitorTask.

@pwittich pwittich requested a review from Copilot November 10, 2025 20:09
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a clock synthesizer reset command and improves clock testing functionality. The key changes include adding a clkreset CLI command to toggle reset on the 5 clock synthesizers, expanding the clock frequency testing capabilities to support multiple test configurations with R0A/R0B clock input selection, and fixing a bug in the MonitorTask where semaphores were not being properly released on error paths.

  • Added resetClockSynth() function and clk_reset CLI command to reset individual clock synthesizers
  • Enhanced clk_freq_fpga_cmd to support multiple test configurations with proper R0A/R0B selection
  • Renamed first_mcu_ctl to set_mcu_id and removed first-time-only restriction
  • Fixed semaphore release bug in MonitorTask by removing broken release_break() macro

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
projects/cm_mcu/commands/SensorControl.h Added declaration for clk_reset command and portmacro.h include
projects/cm_mcu/commands/SensorControl.c Implemented clock reset command, enhanced clock frequency testing with test parameter and R0A/R0B selection, improved input validation
projects/cm_mcu/commands/BoardCommands.h Renamed function from first_mcu_ctl to set_mcu_id
projects/cm_mcu/commands/BoardCommands.c Removed first-time-only check and improved input validation in board ID setup
projects/cm_mcu/clocksynth.h Renamed I2C expander address constants and added resetClockSynth declaration
projects/cm_mcu/clocksynth.c Implemented resetClockSynth function to toggle reset pins via I2C expanders
projects/cm_mcu/MonitorTask.c Fixed semaphore release bug by removing release_break() macro
projects/cm_mcu/CommandLineTask.c Updated command registration for clk_freq_fpga and clkreset, renamed first_mcu command
common/log.c Increased log buffer size from 128 to 192 bytes

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@pwittich pwittich requested a review from Copilot November 10, 2025 20:43
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 6 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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