In this report we will see both the circuit simulation and the actual programming of a safe. Next, we will look at both the general and individual flow diagrams.
We read the voltage of the pins as follows.
They would give us this data according to the buttons (from left to right).
Once we have all the data from the buttons, we configure the reading of pins
The buttons are loaded as follows (There are two parts that we will explain later)
We show the data pressed both on the display and in the virtual Proteus terminal
First we have a special code, if the special code is inserted we have to enter a 4-digit password to our liking. We have to compare two arrangements. For this we have to load an array called against []. (this is the array that contains the momentary data). Once this fix is loaded, we have to go through both the fix that we load and the one we have as "Special Code". We compare each figure in the arrangement according to position. Every time a number matches in the same position of both, it will be incremented by one in a variable called "k". (This in the function called "FourNumbers" at the end of the report).
In the event that the password is incorrect, it would show us the following on the screen
In the event that the four digits are equal, both in value and in position, the following function will be executed to be able to enter a new password.
In the "Open" function, we set both the "change" and "changeContra" variables to true. We use the "change" function to be able to use the "traverseContra" function and the keyboard takes "ChangeContra" as true to use the other part of the function.
Once we choose the 4 numbers for our password, it restarts, but with our password saved. If we put the password that we choose after putting the special code, the servomotor has to be turned on.
Since the servo part was in my topics, I left it to my partner. Even so, I printed a message of what would happen if it was activated.
EIn this job I had problems in the part where I had to load a new arrangement. I implemented all the tools that we saw these years in addition to some things that were personal research.