Add simulation_oscilloscope_trace and remove probe display_options#615
Draft
seveibar wants to merge 1 commit into
Draft
Add simulation_oscilloscope_trace and remove probe display_options#615seveibar wants to merge 1 commit into
seveibar wants to merge 1 commit into
Conversation
Contributor
Author
|
Cc @ShiboSoftwareDev i dont like this yet but this is conceptually an api update |
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.
Motivation
display_optionson probes bundled graph/legend rendering with probe definitions, which conflates measurement and presentation concerns.labelandunits_per_divwere unclear for an oscilloscope-style UI andunitsis ambiguous between volts and amps.Description
display_optionsschemas and thedisplay_optionsfield fromsimulation_voltage_probeandsimulation_current_probe, keeping probe connectivity/measurement logic unchanged.simulation_oscilloscope_traceZod schema and TypeScript interface that captures display/legend/scale properties (display_name,color,volts_per_div,amps_per_div,vertical_center,vertical_offset_divs) and references to either a transient graph or a probe.volts_per_divwhile current traces useamps_per_div.any_circuit_elementunion, and updated tests to remove probe-level display_options checks and to add tests for the new trace object.Testing
bun test tests/simulation_voltage_probe.test.ts tests/simulation_current_probe.test.ts tests/simulation_experiment.test.tsand all tests passed (21 pass,0 fail).bunx tsc --noEmitto typecheck andbun run formatto format code, both completed successfully.Codex Task