Question: Use RIMS simulator to create and run a program as a solution to each of the two exercises below: NOTE: This exercise is to be
Use RIMS simulator to create and run a program as a solution to each of the two exercises below: NOTE: This exercise is to be coded in C language with while loops to wait for changes.
1. A lock has two switches. These are A0 and A1. Once the proper sequence is followed, the lock will open. Write C code for the lock using while loops to wait.
Start at State 0, waiting for State 1 to become true, pseudocode is: while (!(State 1)) then wait for the correct next state condition to occur so the actual code will be while(!(!A1 && !A0)); wait until State 1 is reached.

State A1 A0 0-open the lock A0110 A0011 S0123
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
