GPIO and FSM The problem consists of simulating a combination lock with the help of the two switches S1 and S2. Initiall

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899559
Joined: Mon Aug 02, 2021 8:13 am

GPIO and FSM The problem consists of simulating a combination lock with the help of the two switches S1 and S2. Initiall

Post by answerhappygod »

Gpio And Fsm The Problem Consists Of Simulating A Combination Lock With The Help Of The Two Switches S1 And S2 Initiall 1
Gpio And Fsm The Problem Consists Of Simulating A Combination Lock With The Help Of The Two Switches S1 And S2 Initiall 1 (100.8 KiB) Viewed 53 times
GPIO and FSM The problem consists of simulating a combination lock with the help of the two switches S1 and S2. Initially the RED LED2 is ON signifying that the lock is in the locked state. To open the lock, the switches have to be pressed in the exact sequence S2,S1,S1,S2 which is the code to open the lock. If the correct sequence is provided the GREEN LED2 will be ON and the RED LED2 will go OFF signifying that the lock has entered the unlocked state. If the switches are pressed in any wrong sequence the lock will remain in the locked state with the RED LED2 ON. Once the lock enters the unlocked state it will remain there indefinitely. One needs to reset the board to get into the locked state again and start all over. Write full code in embedded C using driverlib functions. Debouncing switches is not required. You should have a main program which does all the initialization and lights up the LEDs. You should also have a GPIO IRQHandler which accepts the switch inputs and runs the FSM (6)
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply