**4. Simulation results**

Simulation results of the system designed and implemented by Proteus and LabVIEW programs were achieved.

#### **4.1 The results in proteus**

The design suite Proteus 8.9 is an exclusive software implement suite that was principally used in this project for electronic project automation. In Proteus, a hex file to the microcontroller portion on the diagram was used to operate the Arduino mega2560 simulation. It is next co-simulated along through whichever digital and analog electronics linked to it. In **Figure 10**, we build a prototype by selecting a few blocks and using the Simulink block toolbar to join them together. Results were achieved on how to perform each of the following:

#### *4.1.1 Monitoring and controlling storage tank*

The spread of USTs represents an actual risk that requires difficult and costly methods for its management. But by adopting the method used in the simulation, it is possible to control and monitor the level of petrol available in the storage tanks in an easy and inexpensive way. **Figure 11**, shows the design of the power supply is simple and cheap, when it is turn ON. First, Arduino mega2560 checks the petrol level by ultrasonic sensor at the top of the tank. if a petrol level is low than threshold value, a buzzer is initiated and displayed low petrol level on the LCD and Arduino mega operates relay which connected to run DC motor of a fuel supply pump to supply fuel to the tank. In **Figure 12**, shows when a fuel level rises above the

**Figure 10.** *Initialized subsystem before launched to IoT server in Proteus.*

**Figure 11.** *Simulation of the management storage tank (low fuel level).*

threshold value, the buzzer is turned off and levels of fuel displayed on LCD screen. When the fuel level reaches the full level as set in the programming, Arduino mega turns off the relay which connected to stop the dc motor of fuel supply pump running,

**Figure 12.** *Simulation of the management storage tank for the proposed system (display fuel level).*

the LCD screen displays that the tank is completely full as shown in **Figure 13**. **Figure 14**, shows how the fuel levels in the storage tanks can be displayed on the serial monitor.


**Figure 14.** *Fuel level of the storage tank on a serial monitor.*

### *4.1.2 A fuel filling operation*

Sub-system simulation of the proposed system in the Proteus program, to reveal how the system performs in the fuel filling process. The result of the subsystem, along with a step-by-step approach, is listed below:

*Step 1:* Swipe the RFID card and type in the ID number. Where it appears from the **Figure 15**, that Arduino mega2560 connected to the other parts of the subsystem, the green LED is activated to indicate that the petrol station is operating normally, which are of interest to us in this step, the connection between the microcontroller and Ultrasonic sensor installed at the top of the fuel tank, which measures the height of the fuel and send its data to Arduino mega to display the fuel level on the LCD screen, as for the benefit of connecting the microcontroller to the keypad, it appears by entering the ID number of the card swiped on the virtual card reader as shown in **Figure 16**.

*Step 2:* If RFID card is authorized, then the controller fetches the user available amount data from server and display on LCD, then microcontroller ask the user to enter the amount of petrol as shown in **Figure 17**.

**Figure 15.** *LCD shows level of fuel tank.*

**Figure 16.** *Enter ID No by keypad.*

**Figure 17.** *User ID and balance.*

*Step 3:* If an entered amount is less than the available amount, then petrol filling process starts (i.e., Motor turns ON) as shown in **Figure 18**. Otherwise microcontroller say to recharge a suitable amount as shown in **Figure 19**.

*Step 4:* After filling the petrol, the petrol filled amount and available balance information is display on LCD screen as shown in **Figure 20**. And available balance is updated in the server.

#### *4.1.3 Monitor fire protection*

The microcontroller in this system is connected to a flame sensor and servo motor as a fire extinguisher (that discharges a jet of water, foam, gas, or other material to extinguish a fire). When there is a fire, the flame sensors detect it, then the warning system - indicated by the buzzer and red LED - is activated, and the servo motor is activated to convert its angle of 180 degrees. When the alarm state ends, the servo motor returns to its original position, and the LED and buzzer turn off. As seen in **Figure 21**, a fire alert shows on the LCD screen.

#### *4.1.4 Monitor security of petrol station*

Safety of fuel pump also tested in the occurrence of a buildup in the load, to indicate a warning situation on the LCD screen, the buzzer and the red LED were

**Figure 19.** *If the entered amount is more than the available amount.*

**Figure 20.** *The amount of petrol loaded and the available balance.*

**Figure 21.** *Simulation of management fire protection of proposed system.*

triggered to tell the viewer of the status of the load besides work to switch off the relay that runs the pump motor, as displayed in **Figure 22**.
