Jump to content

Recommended Posts

  • MVP 2023

That looks amazingly like the Example program Kikis posted for you.  You're having trouble modifying the code because you didn't write it and you don't know how it works.  The problem with a Set/Reset and Contact type program (A.K.A. "A Bit-Banger") is they are very difficult to insert new steps in after they've been written to perform a certain task.

Fear not, young Padawan.  There is a better way, but you must study the Ways of the Force.  You are trying to program a sequence, which can easily be defined using a flow chart.

Read the following post three times:

 

Then download my State Machine example program and study how it works.

Then list the  steps of your sequence.  On paper.  Use circles and arrows.  A paragraph on the back is optional.

From your written steps, see if you can implement the State Machine.  You should be able to do it in four networks with three timers, based on your previous posts and this new information.

Upload what you come up with, even if it doesn't work right.  We'll worry about the analog output for the speed after the output coils are working.

Joe T.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

This site uses cookies. By clicking I accept, you agree to their use.