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

abort immediate #7

Closed
1 of 2 tasks
tablatronix opened this issue Jul 6, 2019 · 4 comments
Closed
1 of 2 tasks

abort immediate #7

tablatronix opened this issue Jul 6, 2019 · 4 comments

Comments

@tablatronix
Copy link

tablatronix commented Jul 6, 2019

abort does not turn off heater immediately

  • add SetRelayFrequency(0);
    do not wait for return and loop
void AbortReflow()
{
   SetRelayFrequency(0); // relay off
  if ( state == 1 || state == 2 || state == 16 ) // if we are in warmup or reflow states
  {
  • moved in front of state checking, and always abort!, in case a bug causes a bad state etc.
@UnexpectedMaker
Copy link
Owner

This has been improved in v1.04 that I am going to upload today, but the abort button should never be able to be pressed outside of those states, so not sure why you need SetRelayFrequency(0); outside the if statement.

It is inside the if statement in v1.04 :-)

@tablatronix
Copy link
Author

It was a safety thing, in case of a bug or loss of state , abort aborts always

@UnexpectedMaker
Copy link
Owner

Right, but again, AbortReflow() is only ever called from a button press, and that press can only happen in those states...

    else if ( state == 1 || state == 2 || state == 16 )
    {
      AbortReflow();
    }

@tablatronix
Copy link
Author

I am always thinking about future abstraction less code coverage if abort gets called from a big red button or tc failure

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