As an Amazon Associate we earn from qualifying purchases.
A fire robot is a small vehicle that detects a flame, drives toward it and switches on a pump or fan to put it out. Before spending money on sensors, motors and a chassis, you can test the whole idea on a computer. This article shows how to set up a fire robot simulation in Proteus using an Arduino, and what to check while it runs.
The video below shows the simulation working.
How the fire robot works
The robot follows a simple loop: sense, decide, act. Flame sensors point left, front and right. The Arduino reads them and decides which way to turn. A motor driver then spins the wheels, and once the robot is close to the flame, a pump (or fan) is switched on.
If you want to compare this with a finished build, see our fire fighting robot project, which covers the hardware side.
Components you need in Proteus
- Arduino Uno board model (added through a separate Arduino library for Proteus, since it is not always included by default).
- Three flame sensor inputs for left, front and right.
- L293D motor driver to run two DC motors.
- Two DC motors for the left and right wheels.
- A pump or fan output, modelled with a motor, a transistor and a relay or diode as needed.
- Power and ground terminals, plus an optional LED or buzzer as an alarm.
Simulating the flame sensor
Proteus does not normally include a ready-made flame sensor. The usual workaround is to replace each sensor with something that gives the same signal: a logic toggle, a push button with a pull-down resistor, or a potentiometer feeding an analog pin. You then change the value by hand to pretend a flame appeared on that side.
Circuit connections
Exact pins are your choice, but a clear layout like this one keeps the code easy to follow:
- Left, front and right flame inputs to digital pins 2, 3 and 4.
- L293D input pins to digital pins 8, 9, 10 and 11 for the two motors.
- L293D enable pins tied to 5 V so both motors are always enabled.
- Pump control to digital pin 12, through a transistor or relay stage.
- Motor supply connected to the L293D motor voltage pin, with all grounds shared.
The L293D is a dual H-bridge. If you want to understand how it reverses a motor, read our guide on H-bridge motor control in Proteus.
Program logic
Write the sketch in the Arduino IDE. The logic does not need to be complicated:
- Set the flame sensor pins as inputs, and the motor and pump pins as outputs.
- Read the three sensors in a loop.
- If no flame is detected, stop the motors and keep the pump off.
- If the front sensor sees a flame, drive forward until the flame is close.
- If only the left sensor sees a flame, turn left. If only the right sensor sees it, turn right.
- When the flame is close enough, stop the motors and turn the pump on until the sensors read clear.
Check whether your sensor signal is active high or active low in your simulated circuit. This is the most common reason for a robot that runs away from the fire instead of toward it.
Running the simulation
- Compile the sketch in the Arduino IDE and locate the generated .hex file (enable verbose output during compilation to see its path).
- In Proteus, double-click the Arduino and set the Program File to that hex file.
- Press play and toggle the left, front and right inputs one at a time.
- Watch the motors and pump to confirm they respond as expected.
What to test
- No flame: both motors and the pump stay off.
- Flame on the left or right: the correct wheel direction changes to turn toward it.
- Flame in front: both wheels drive forward.
- Flame very close: motors stop and the pump starts.
- Flame removed: the pump stops again.
Limits of the simulation
A simulation checks wiring and logic, not real-world behaviour. It will not show wheel slip, battery drop under motor load, sensor range, or how sunlight and other infrared sources confuse flame sensors. Treat it as a first test, then expect to tune the hardware.
Ideas for extending the project
- Add a buzzer or LED to signal when a flame is found.
- Use a servo to aim a nozzle at the flame.
- Add a way to show readings on an LCD for debugging.
- Control the robot manually, as in our Bluetooth controlled fire robot.
- Try a more advanced chassis, such as the step climbing robot with a fire extinguisher.
Frequently asked questions
Is there a flame sensor in Proteus?
Not in the standard libraries, as far as most users find. You can simulate it with a button, logic toggle or potentiometer, or add a third-party library if you trust the source.
Why does the Arduino not appear in Proteus?
The Arduino board models usually need to be downloaded and added to the Proteus library folder. After restarting Proteus, search for the board in the device picker.
Can I use the same code on a real robot?
Mostly, yes. Pin numbers, sensor polarity and motor timing often need adjusting, and a real pump needs a proper driver and separate power supply.
Is a simulation enough to build the robot?
It is a good start for checking logic and wiring, but you should still test the physical robot carefully and away from anything flammable, using a small safe flame such as a candle under supervision.