Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Issie Design Sheet Parameter Features #522

@tomcl

Description

@tomcl

Parameter Inheritance

Yes we need this. And it has an extra feature that we will want some time no doubt:

  • Parameter value tracing. It should be possible for a user to view how slot values are calculated substituting for all inherited parameters, with all intermediate parameter expressions (and their values) shown. If this is done at design time it will lead to multiple traces - one for each path to a possible root sheet. But, with any luck, most will be the same. This one looks like a feature for me, it needs a good UI.

Consistent & Correct Simulation

Simulation should:

  • Set all slots to correct integer values based on parameters
  • Deliver comprehensible error messages if constraints are not obeyed.
  • Simulate as normal
  • Maybe simulation should reset default values of parameters to those used in simulation? But, see below, there is no consistent way to do this.

It is worth remembering that the values of parameter slots in simulation will in general vary between custom component instances, due to parameter inheritance this can be due to a parameter change in value above the sheet in which the instance exists.

Constants & Bus Comparators need parameters on the value slot - which must be bigint

That means all parameters must be bigint but that should actually be easy: CompSlotName can have an extra case used for those values where the bigint parameter stays bignum when being read/written from the slot. Max constraints prevent int slots from having too large values. The change should be juts refactor the parameter type and change where compiler asks. This feature will let me write a parametrised N-bit up/down counter!

Parameters work for Bus Split and Bus SplitN

SplitN is always the nastiest component to implement! It will need a new ParamSlotName case that hold a list of two-parameter records.

Saving and loading should work and old designs must load ok - although they maybe will save in new format

I think this is a feature we now have but I need to test it and check corner cases. NB - bigint load/save works with load/save as well as any other type!

Additional context

  • Basic parameter mechanism now on master
  • TODO
    • Inheritance
    • add bigint option
    • constants and bus comparators
    • splitN

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions