Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simulation status #52

Closed
1 of 4 tasks
perlindgren opened this issue Jul 29, 2023 · 2 comments
Closed
1 of 4 tasks

Simulation status #52

perlindgren opened this issue Jul 29, 2023 · 2 comments
Assignees

Comments

@perlindgren
Copy link
Owner

perlindgren commented Jul 29, 2023

Problem

As of now evaluating (clock) have no return value. So its not possible for the simulator to know if e.g., a halt condition has been encountered.

Solution

Introducing a return type for the Component::clock method.

Something like

enum Condition {
  Error(String),
  Halt(String),
}

And let clock return Result<(),Condition>, where Ok(()) indicates that clocking was successful, and Condition some type of exception. We can later refine the Condition to be more specific if we like but this could work to start out with.

  • basics as per PR Return type #58
  • handling of Condition in the simulator, allowing run to halt/error etc.
  • handling of Condition and Simulator status in vizia.
  • handling of Condition and Simulator status in egui.
@perlindgren perlindgren self-assigned this Jul 29, 2023
@perlindgren
Copy link
Owner Author

PR #58 should address the basics, and we can work based on that.

@onsdagens
Copy link
Collaborator

Addressed with #78 .

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

No branches or pull requests

2 participants