
SIM808 Library for Proteus V1.1 (GSM + GPS + Arduino)

Hello friends, I hope you all are doing great. Today, I am going to share the new SIM808 Library for Proteus V1.1. The SIM808 is SIMCom's popular module that puts a GSM / GPRS modem and a GPS receiver on one board, so a single Arduino serial port gives you SMS, calls and your position. That is why it is the favourite of GPS trackers, vehicle trackers and anti-theft projects. With this GSM GPS Library for Proteus, you can build and debug your tracker on your PC, before you buy a SIM card and a 2 A power supply, and before you walk outside for a satellite fix.
SIM808 Library for Proteus
Latest version: V1.1 (October 2026, this tutorial)
Helping Tools
- Serial Monitor Advance: a serial terminal window for the UART of your board
- Serial Monitor Expert: the serial monitor with extra debugging tools
- LCD Library for Proteus V3.0: 16x2, 20x4 and I2C LCDs to show your readings
Version 1.1 replaces the first version of this post. You now get two devices: SIM808 Simple, with the virtual phone and its GPS strip next to the module, and SIM808 Advance, with a pop-up window that holds the phone plus five measured GSM + GPS test tools. The new Arduino GPS tracker Proteus demo has two Arduino UNOs that switch their SIM808 on with PWRKEY, answer a LOCATION SMS with a Google Maps link and talk to our TEP Serial Monitor, shown in its compact Simple interface. Have you read version 1.0? Then jump to "What's New" below.
NOTICE: This library is very special to our team. Our SIM808 model waits for its power key, learns your baud rate from the first "AT", texts and calls over a simulated network and, at the same time, tracks a simulated GPS sky and gets its first fix like a real receiver. It took our team a lot of hard work, many test runs and many design changes. Your feedback is the fuel that keeps us going, so please tell us what you think in the comments below or in the SIM808 Library board of our forum. And if our free libraries help you, you can buy us a coffee. So, let's get started with the SIM808 Library for Proteus:
What is the SIM808 GSM + GPS Module?
The SIM808 is a module made by SIMCom with two radios inside: a quad-band GSM / GPRS part (850, 900, 1800 and 1900 MHz) and a GPS receiver. GSM is the 2G mobile network for calls and SMS, and GPRS is its data service. Your Arduino controls both parts over one UART (the two-wire TX / RX serial port) with AT commands: short text commands that start with "AT", such as AT+CSQ for the signal or AT+CGNSINF for the position.
The GSM part speaks the same AT commands as SIMCom's SIM800 family (firmware R14.18; ATI answers "SIM808 R14.18"). The GPS part is a MediaTek MT3337 engine in today's R14 module; the older R13 module used the MT3336 and the AT+CGPS commands. It receives GPS, QZSS and SBAS satellites, but no GLONASS. People use it for:
- GPS trackers for cars, bikes, pets and parcels,
- anti-theft alarms that text their position,
- remote monitoring and control by SMS,
- student projects that combine GSM and GPS.
SIM808, SIM800 or NEO-6M: Which Library Do You Need?
We have a whole family of GSM and GPS libraries for Proteus. Pick the one that matches your module:
| Your module | What it does | Our library |
|---|---|---|
| SIM808 breakout | GSM + GPS in one module | This article |
| SIM800L (red mini board) | GSM, starts as soon as it gets power | SIM800L Library for Proteus |
| SIM800C (blue HW-537 board) | GSM, with a PWX power key | SIM800C Library for Proteus |
| SIM900A (mini board) | GSM | SIM900A Library for Proteus |
| NEO-6M, NEO-7M, NEO-M8N | GPS / GNSS only (NMEA sentences) | NEO-6M Library for Proteus, NEO-7M Library for Proteus, NEO-M8N Library for Proteus |
Each GSM library has its own simulated network, so a TEP SIM808 cannot text a TEP SIM800L, SIM800C or SIM900A. Two SIM808 modules in one design can text and call each other.
GSM and GPS Terms You Will See in This Article
| Term | Meaning |
|---|---|
| AT command | A text command to the module, ending with a carriage return; it answers OK or ERROR |
| URC | "Unsolicited result code": a line the module sends on its own, such as RING, +CMT or SMS Ready |
| PWRKEY | The power key pin: held LOW for more than 1 s, it switches the module on or off |
| Auto-bauding | The SIM808 learns your UART speed from the first "AT" it receives |
| SMS Ready | The last start-up message; after it, the module takes SMS commands |
| CSQ | Signal quality from 0 to 31 (99 = no signal); 20 and more is good |
| RI | Ring Indicator pin: LOW while a call rings, a short LOW pulse for each new SMS |
| +CLIP | The caller ID line that follows each RING |
| Fix, 3D fix | The GPS knows its position; a 3D fix (4 or more satellites) includes the altitude |
| TTFF | Time To First Fix after power-up or a GPS restart |
| Cold / warm / hot start | A GPS restart that forgets everything / keeps the time / keeps the satellite data; hot is the fastest |
| HDOP, PDOP | How good the satellite geometry is; about 1 is very good, larger numbers mean less accuracy |
| PPS | Pulse per second: a short pulse every second while the GPS has a fix |
What's New in SIM808 Library for Proteus V1.1
If you used version 1.0, here is what has changed:
- Two devices in
TEPSIM808.LIB: SIM808 Simple (SIM808TEP, the v1.0 device, so your old designs keep working) and SIM808 Advance (SIM808ADVTEP), with its own default numbers (+15555550809, phone +15555550192). - Close and reopen the phone: a red X in the phone's Messages bar and a PANEL button on the board; the Advance board has an OPEN PANEL button.
- Board: a ring LED round the GSM antenna and a lamp in its tip (orange = sending, green = receiving), a GPS patch that glows (amber = acquiring, green = fix) and a SIMPLE / ADVANCE badge. The LEDs keep their v1.0 colours.
- Five measured test tools in the Advance pop-up: Network, SMS round trip (with a Google Maps link check), Call, GPS fix and AT check.
- A more realistic network: the search takes 2.2 - 3.2 s (weak signal 2.8 - 3.4 s) instead of a fixed 3 s, and every SMS takes its own time: 1.2 - 1.9 s to the module and 1.7 - 2.5 s back (v1.0: always 1.5 s and 2 s).
- Model fixes: AT+CFUN=1 after AT+CFUN=0 reports +CREG: 2, AT+CFUN=1,1 sends its whole OK before it restarts, and the phone shows 60 characters per message line (v1.0: 56).
- GPS warm start: it now keeps the time and takes 28/30 of the cold-start time, as in the data sheet (v1.0 treated it as a cold start).
- TEP Serial Monitor instead of the two Virtual Terminals, and two UNOs in the demo (one Simple, one Advance), each with an LED on A0.
- A smarter sketch: Serial Monitor commands (AT, STATUS, LOCATION, TEXT, HELP) and a 30 s check that sets the module up again after a restart and presses PWRKEY again after a power-down.
- Real-hardware fix: the 2.8 V divider is now 10 k / 12 k (v1.0 README: 10 k / 20 k, about 3.3 V).
- Lighter package: about 1.6 MB, without the C++ source code.
SIM808 Library for Proteus: Simple vs Advance
Both devices run the same SIM808 model with the same properties; only the panel differs:
| Feature | Simple | Advance |
|---|---|---|
| Full SIM808 model (PWRKEY, AT commands, SMS, calls, RI pin, GPS) | ✔ | ✔ |
| PWR / STA / NET / PPS LEDs, ring LED, tip lamp, glowing GPS patch, waves | ✔ | ✔ |
| Virtual phone with a GPS strip, drawn on the schematic | ✔ | ✘ |
| Phone in a pop-up window you can move, resize and minimise | ✘ | ✔ |
| GPS LOCATION, GPS SKY, NETWORK, SMS and CALL buttons | ✔ | ✔ |
| MODULE, NETWORK, GPS and TRAFFIC cards | ✘ | ✔ |
| Network, SMS round trip and Call tests | ✘ | ✔ |
| GPS fix test (cold, warm and hot starts) | ✘ | ✔ |
| AT check with response times | ✘ | ✔ |
| TEP Dark / Light theme, text size, Help page with Copy diagnostics | ✘ | ✔ |
| Same device name as v1.0 (old designs keep working) | ✔ | ✘ |
Choose Simple to keep the phone beside your circuit, and Advance when your sheet is full or you want hard numbers about your tracker code. The demo has one of each.
Download SIM808 Library for Proteus
Click the button below to download SIM808-GSM-GPS-Library-for-Proteus-v1.1.zip (about 1.6 MB):
SIM808 GSM + GPS Library for Proteus V1.1- README.txt: a detailed guide to the files, the wiring and the model.
- Proteus Library Files:
TEPSIM808.LIB(both devices),TEPSERIALMON.LIBand our Arduino UNO libraryArduinoV3TEP.LIB/ArduinoV3TEP.IDX. - Proteus Model Files:
TEPSIM808.DLLandTEPSERIALMON.DLL. - Proteus Simulation:
SIM808-GPS-Tracker-ArduinoUnoV3.pdsprj,SIM808_GPS_Tracker.hexand copies of both DLLs. - Arduino Code:
SIM808_GPS_Tracker.inoand AltSoftSerial 1.4 (MIT licence).
The demo reads the GPS with AT+CGNSINF, so it needs no GPS library. If you don't have Proteus yet, read How to Download and Install Proteus 7 and 8. New to libraries? Follow How to Install a New Library in Proteus.
How to Install SIM808 Library for Proteus
- Close Proteus and extract the whole zip file.
- Copy the four files from Proteus Library Files into the LIBRARY folder, usually
C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY(on some PCsC:\ProgramData\Labcenter Electronics\Proteus 8 Professional\LIBRARY). - Copy
TEPSIM808.DLLandTEPSERIALMON.DLLinto the MODELS folder. - Start Proteus, press P and search for SIM808. You get the Simple and the Advance device (category Peripherals > Wireless).
Updating from v1.0? Replace TEPSIM808.LIB and TEPSIM808.DLL, and delete any TEPSIM808.IDX from LIBRARY. A v1.0 design keeps its old symbol and runs with the new model, without the new board parts and the red X; re-pick the part to get the v1.1 board. Tested in Proteus 8.5; Proteus 7 is not supported.
The SIM808 Board in Proteus
We designed the module as a clean TEP board in blue: the silver SIM808 with its red SIMCOM band and "QUAD-BAND R14.18", the SIM holder, the PWRKEY push button, four LEDs, the black GSM rubber duck on a gold SMA connector and the beige GPS patch antenna ("GPS 1575.42 MHz") with a small satellite above it. Here is the SIM808 Advance with a GPS fix:
Pinout
The seven pins are the signals a SIM808 breakout gives you; real boards order their headers differently, so always follow the labels on your own board:
| Pin | Function | Demo connection |
|---|---|---|
| VCC | Power supply | Supply terminal |
| GND | Ground | GND |
| TXD | Serial output: answers, URCs and GPS data | Arduino D8 |
| RXD | Serial input: AT commands from the Arduino | Arduino D9 |
| PWRKEY | LOW for more than 1 s = on / off (pulled up inside) | Arduino D7 |
| RST | Reset: LOW for at least 105 ms | Open (internal pull-up) |
| RI | LOW while a call rings, a 120 ms LOW pulse for each new SMS | Arduino D2 (INT0) |
LEDs, Antennas and Waves
| Indicator | What it shows |
|---|---|
| PWR LED (red) | The board has power, even while the module is switched off |
| STA LED (amber) | The module is switched on (its STATUS pin) |
| NET LED (green) | 64 ms on / 800 ms off while searching, 64 ms on / 3 s off when registered |
| PPS LED (blue) | A 100 ms flash every second while the GPS has a fix |
| Ring LED and tip lamp on the GSM antenna | Orange while the module sends, green while it receives, both in turn during a call; the waves above ripple out or in |
| GPS patch and its waves | Amber while the GPS acquires, green with a fix, off / grey while the GPS is off |
The board button is PANEL on the Simple (green dot = SHOWN, grey dot = CLOSED) and OPEN PANEL on the Advance.
Component Properties
| Property | Meaning | Default |
|---|---|---|
| SIMNUM | The module's SIM number | +15555550808 (Advance +15555550809) |
| PHONENUM | Number of its virtual phone | +15555550191 (Advance +15555550192) |
| OPERATOR | Network operator name | TEP MOBILE |
| SIGNAL | Signal at start: GOOD, WEAK or NONE | GOOD |
| CLOCK | Network time: PC (your PC's time and time zone) or a fixed YYYY-MM-DD HH:MM:SS | PC |
| POWERON | KEY = starts OFF like a bare SIM808, AUTO = the board switches it on | KEY |
| GPSLAT / GPSLON / GPSALT | The HOME position | 51.47788 / -0.00148 / 46 (Greenwich) |
| GPSTTFF | Cold-start time to first fix in seconds | 10 (real module: 30) |
GPSTTFF is 10 s instead of the data sheet's 30 s, so your demos don't keep you waiting. Put your own city in GPSLAT / GPSLON, and the HOME button takes the module there.
Switching the SIM808 On: The PWRKEY
Here is the first lesson of every SIM808: it starts switched OFF. Power alone is not enough (the red SIM800L board, by contrast, starts as soon as it gets power). PWRKEY must be held LOW for more than 1 s, and the same pulse on a running module switches it off ("NORMAL POWER DOWN"). The PWRKEY button on the board can be clicked too: it holds the key LOW for 1.5 s.
This is the Advance pop-up 3.8 s after Run, before the sketch has pressed the key. The header says U2 · OFF (KEY), the phone shows SIM808 OFF - HOLD PWRKEY LOW FOR 1 s, the MODULE card says OFF - hold PWRKEY LOW 1 s · 0 start-ups, the signal is CSQ 99 and NETLIGHT is off:
Because a second pulse would switch a running module off, for example after a reset of the UNO, the sketch first sends "AT" and presses the key only when nothing answers:
Serial.print(F("Looking for the SIM808... "));
const byte tries = findModule(8);
wasOn = tries == 1;
if (wasOn) {
Serial.println(F("already on"));
} else if (tries) {
Serial.println(F("on (the board switched it on by itself)"));
} else {
Serial.println(F("no answer (it starts switched OFF)"));
if (!switchOn()) return false;
}
The press itself never drives PWRKEY HIGH. It pulls D7 LOW as an OUTPUT, waits 1.2 s and turns the pin back into an INPUT, so the module's pull-up takes over:
bool switchOn() {
Serial.println(F("Switching the SIM808 on: PWRKEY LOW for 1.2 s"));
pinMode(PWRKEY_PIN, OUTPUT);
digitalWrite(PWRKEY_PIN, LOW);
delay(1200);
pinMode(PWRKEY_PIN, INPUT); // release
delay(2500); // the serial port is ready about 3 s after PWRKEY went LOW
return findModule(20) != 0;
}
From PWRKEY to SMS Ready and the First Fix
- The serial port and the STA LED come up 3 s after PWRKEY went LOW.
- The module is auto-bauding: it says nothing until it receives "AT" at any speed from 1200 to 115200 bps, then answers at that speed.
- Call Ready and SMS Ready follow 2.5 s and 3 s after the serial port.
- The module registers to the network 2.2 - 3.2 s after SMS Ready.
- The GPS is off after every power-up.
AT+CGNSPWR=1switches it on, and the first fix comes GPSTTFF seconds later.
I caught the Advance pop-up in the middle of this phase. The header says U2 · SEARCHING, the UART row says auto-baud - waiting for "AT", the settings are still the factory ones (PDU, CNMI 2,1, CLIP 0, ATE1) and the GPS strip says GPS OFF - SEND AT+CGNSPWR=1:
In the demo, both modules are set up about 12 s after Run (simulation time), and the first fix follows about 10 s after AT+CGNSPWR=1.
The Virtual Phone: SIM808 Simple
Beside the Simple module, we have drawn a smartphone with its own number, a Messages app and a GPS strip. It texts the SIM808, calls it, answers its calls, and it moves the module around the world with one click:
| Part | What it does |
|---|---|
| Status bar | The network time, "GPS" while the GPS is on, and "TEP 2G" |
| Module card | Number, state (for example SIM808 OFF - HOLD PWRKEY LOW FOR 1 s or REGISTERED - TEP MOBILE), CSQ and stored SMS |
| GPS strip | For example GPS ACQUIRING - FIX IN ABOUT n s or GPS 3D FIX - n OF m SATELLITES, with the position, UTC, altitude, HDOP and the place |
| Conversation | Bubbles on the right = sent by the phone, on the left = received from the module, plus call events |
| CALL / ANSWER, HANG UP | Calls the SIM808 or answers its call; ends or rejects a call |
| SMS: LOCATION, LED ON, LED OFF, STATUS | Text the SIM808 (delivered after 1.2 - 1.9 s) |
| GPS LOCATION | LONDON, NEW YORK, TOKYO, LAHORE or HOME |
| NETWORK, GPS SKY | GOOD / WEAK / NO SIGNAL; OPEN SKY / INDOOR |
| Red X | Closes the phone |
SMS: LOCATION, the Google Maps Link
This is the heart of every SIM808 tracker. Tap SMS: LOCATION: the SMS reaches the module, its RI pin pulses LOW, the sketch reads the GPS with AT+CGNSINF and texts back a Google Maps link. Here is U1's phone after LED ON, LOCATION and STATUS:
The GPS strip shows GPS 3D FIX - 7 OF 13 SATELLITES at 51.477862 N, 0.001501 W, altitude 49.6 m, HDOP 1.2: the Greenwich observatory, our default HOME. The link https://maps.google.com/?q=51.477879,-0.001464 opens that spot in any browser; west and south become a minus sign. The STATUS reply packs everything into one SMS: "LED ON, GPS fix 7 sats, CSQ 23, up 353 s".
GPS LOCATION: Moving the Module to Lahore
Now click LAHORE in the GPS LOCATION row. The module jumps to Lahore, sees a different part of the sky and fixes again. Tap SMS: LOCATION once more:
The strip now says GPS 3D FIX - 8 OF 15 SATELLITES, 31.520368 N, 74.358746 E, altitude 218.6 m, HDOP 1.0, and the reply is https://maps.google.com/?q=31.520367,74.358740. LONDON, NEW YORK, TOKYO and HOME work the same way, and the position wanders by a few metres, like a real receiver's.
CALL: The Sketch Rejects It
Tap CALL. After 2 s, the module sends RING and the caller ID, the RI pin goes LOW, and the sketch prints the number and rejects the call with ATH. A tracker is not a phone, after all:
GPS SKY: INDOOR
Click INDOOR to carry the module into a building. Every satellite signal becomes 40 dB weaker, so the GPS loses its fix at once:
The strip turns red, GPS: NO SIGNAL - INDOOR, and the position becomes "LAT -- LON --", but the small line still says 15 SATELLITES IN VIEW: they are above the horizon, the GPS just can't hear them. The patch turns amber and its waves grey, while the GSM side stays REGISTERED. A LOCATION SMS now gets "No GPS fix yet (n satellites)". Click OPEN SKY, and the fix comes back quickly, because the receiver still knows the time and the satellites. That is the lesson for a real tracker: its GPS antenna needs a view of the sky.
Closing the Phone
Need room on the sheet? Click the red X in the Messages bar. The board button then says PANEL: CLOSED with a grey dot, while the module, the GPS and the sketch keep running. Click PANEL to bring the phone back.
SIM808 Advance: The Pop-Up Panel
The Advance device keeps only the board on the schematic. At Run, a TEP pop-up window opens with the look of our TEP Serial Monitor and no Windows title bar: move it by its header, resize or minimise it, and reopen it with OPEN PANEL. The header holds the state (for example U2 · GPS FIX), the Phone and Test tabs and the theme, Settings and Help icons.
The Phone Page
The Phone page holds the same phone beside four cards. Here it is after two LOCATION messages and a STATUS:
- MODULE: number, IMEI, firmware "1418B05SIM808M32 (ATI: SIM808 R14.18)", UART "9600 bps (auto-baud, locked)" and the settings the sketch made ("text · CNMI 2,2 · CLIP 1 · ATE0").
- NETWORK: registered, home network (+CREG 1); CSQ 22 · -69 dBm · GOOD; TEP MOBILE for 62.9 s after a search of 2.67 s; NETLIGHT 64 ms on / 3 s off.
- GPS (MT3337): on · 3D fix · first fix after 10.72 s; 51.477868, -0.001500, 48.3 m; 7 used of 13 in view, HDOP 1.2, PDOP 2.4; HOME · open sky; output "CGNSINF on request".
- TRAFFIC: 5 SMS sent and 5 received, 0 waiting at the SMS centre, 35 AT commands with 0 ERROR, and the last command, the sketch's AT+CGNSINF.
The GPS card tells you at a glance whether your sketch switched the GPS on and how long the first fix took.
The Test Page: Five GSM + GPS Test Tools
The Test tab has five tools, and every number on it is measured on the running model with your sketch. A tool refuses to start, with the reason, when the module is off, another test runs, a call is in progress or (GPS fix) the GPS is off.
1. Network: How Long After PWRKEY Can You Text?
Choose Restart or Radio off / on and 3, 5 or 10 runs. Restart really switches the module off and on again with its power key (PWRKEY LOW for 1 s) and times every step from the key press. Five runs:
Every run shows the same first steps: on after 1.00 s, UART after 3.00 s, Call Ready after 5.50 s and SMS Ready after 6.00 s. Only the network search changes: registered after 8.80, 8.78, 8.53, 8.50 and 8.56 s. So, after pulsing PWRKEY, your sketch must wait more than 8 s before it can text or call: wait for SMS Ready, then poll AT+CREG? until it answers 0,1. Radio off / on uses AT+CFUN=0 / 1 instead and keeps the settings.
A restarted SIM808 has also forgotten its settings, auto-bauds again and has its GPS off. Watch U4 while the test runs: the sketch's 30-second check notices it and sets everything up again, the GPS too:
"No answer from the SIM808" means the check got no answer; "The SIM808 restarted (settings lost)" means the module answered, but not in text mode. Either way, the sketch runs its set-up again, including "GPS: powered on (AT+CGNSPWR=1)".
2. SMS Round Trip with the Maps-Link Check
This tool tests your sketch. The phone texts LED ON, LED OFF, STATUS or LOCATION 3, 5 or 10 times, and each reply SMS stops the clock. With LOCATION, the tool also checks that the reply is a Google Maps link and measures how far its point is from the module's true position. Five runs:
All five were answered in 3.50 to 4.63 s (average 4.07 s). The network in took 1.35 to 1.87 s, the sketch 0.21 s (from +CMT to its AT+CMGS, including its AT+CGNSINF) and the reply back 1.94 to 2.55 s. All five replies were Maps links, 0.2 to 1.8 m from the true point (1.2 m on average). Good for: checking that your sketch answers every command, and how fast.
3. Call Test
The phone calls the module 1, 3 or 5 times. The tool records the first RING, the module's own +CLIP line, the RI pin and whether your sketch answered (ATA) or rejected (ATH) the call:
All three calls rang 2.00 s after dialling, the RI pin (D2) went LOW once for 52 ms, and the sketch rejected each call 0.05 s after the first RING. Above the timeline is the caller ID line, +CLIP: "+15555550192",145,"",0,"",0. Without ATA or ATH, the module gives up after 30 s (NO CARRIER).
4. GPS Fix: Cold, Warm and Hot Starts
This tool is new for the SIM808. It really restarts the GPS engine through the module's own command path, AT+CGNSCMD=0,"$PMTK103*30" for a cold start, and times the first epoch with a fix. Choose Cold, Warm or Hot and 3, 5 or 10 runs:
The five cold starts took 10.71, 10.63, 10.26, 10.89 and 10.52 s (average 10.60 s), each with 7 of 13 satellites and HDOP 1.23. The blue dashed line is our GPSTTFF (10 s), the orange one the SIM808 data sheet (30 s). Why more than 10 s? The GPS reports its fix once per second, so a run takes up to 1 s longer than the start itself. Now Hot ("$PMTK101*32"), which keeps the satellite data:
A hot start took 1.26 to 1.89 s (average 1.57 s; data sheet: 1 s). A hot start needs a fix first, and INDOOR means no fix at all, so the run ends with a time-out. The warm start ("$PMTK102*31") is the v1.1 change: it keeps the time and needs 28/30 of the cold time, 9.3 s here:
Good for: knowing how long your tracker waits for a position, and checking that your sketch handles "no fix" in the meantime.
5. AT Check
The AT check shows what twelve read-only queries answer right now, and the last 8 AT commands your Arduino sent, with the reply and the response time:
The module was ready (+CCALR: 1), registered (+CREG: 0,1), in text mode with +CNMI: 2,2,0,0,0, and its GPS was on (+CGNSPWR: 1); +IPR: 0 means auto-bauding. In 100 commands there was no ERROR, and the last 8 took 74.9 ms on average. Look at the times: AT+CMGF? took 23.8 ms, but AT+CGNSINF with a fix took 115.4 ms (81.0 ms without a fix), because at 9600 bps every character of its long answer takes about 1 ms. The oldest line in the list shows the famous date 1980 (see the note below).
Settings and Help
These pages work like in our SIM800C Library for Proteus and ESP-01 Library for Proteus. The gear opens Settings: theme (TEP Dark or Light), text size, open the panel at Run and the window size, saved for your Windows user.
The ? icon opens Help & Support: eight cards (bug report, feature request, article, user guide, updates, donate, website, forum) and Copy diagnostics for a bug report. Cards whose link is not published yet say "Link coming soon"; a links.ini file next to the DLL can change them.
SIM808 GPS Tracker with Arduino in Proteus
Open SIM808-GPS-Tracker-ArduinoUnoV3.pdsprj from the Proteus Simulation folder. It has two Arduino UNOs from our Arduino Library for Proteus V3.0, both running SIM808_GPS_Tracker.hex:
- NODE 1: UNO 1 (ARD1) with the SIM808 Simple (U1, +15555550808, its phone +15555550191), LED D1 on A0 and Serial Monitor U3.
- NODE 2: UNO 2 (ARD2) with the SIM808 Advance (U2, +15555550809, its phone +15555550192), LED D2 on A0 and Serial Monitor U4.
Wiring
| From | To | Why |
|---|---|---|
| SIM808 VCC / GND | Supply / ground | Power |
| SIM808 TXD | Arduino D8 | AltSoftSerial RX: answers, URCs, GPS data |
| SIM808 RXD | Arduino D9 | AltSoftSerial TX: AT commands |
| SIM808 PWRKEY | Arduino D7 | The power key (pulled LOW for 1.2 s, then released) |
| SIM808 RI | Arduino D2 | INT0 interrupt for calls and new SMS |
| SIM808 RST | Open | Internal pull-up |
| LED + 220 Ω | A0 to GND | Switched by SMS LED ON / LED OFF |
| Serial Monitor RXD / TXD / GND | Arduino D1 / D0 / ground | Shows what the Arduino prints, sends what you type |
Want to know more about these pins? Read our Introduction to Arduino UNO. As with every UART module in Proteus 8.5, the sketch uses AltSoftSerial (Paul Stoffregen, MIT licence) on its fixed pins D8 / D9, because SoftwareSerial needs pin-change interrupts and cannot receive in Proteus 8.5. Keep D10 free while it runs. The external interrupt INT0 on D2 works, which is why RI goes there:
AltSoftSerial gsm; // RX = D8 (from SIM808 TXD), TX = D9 (to SIM808 RXD)
pinMode(RI_PIN, INPUT_PULLUP);
attachInterrupt(digitalPinToInterrupt(RI_PIN), onRi, FALLING);
Reading the GPS: AT+CGNSINF
You don't need a second serial port for the GPS: the position comes over the same UART as the AT commands. AT+CGNSINF answers one line of 21 comma-separated fields. Here is the live line from the AT check above:
+CGNSINF: 1,1,20261006044453.000,51.477890,-0.001483,43.356,0.17,0.0,1,,1.2,2.6,2.2,,13,7,,,48,,
| Field | Meaning | In this line |
|---|---|---|
| 1 | GPS on (1) or off (0) | 1 |
| 2 | Fix (1) or no fix (0) | 1 |
| 3 | UTC date and time, yyyyMMddhhmmss.sss | 6 Oct 2026, 04:44:53 UTC |
| 4, 5 | Latitude and longitude in degrees (minus = south / west) | 51.477890, -0.001483 |
| 6 | Altitude above sea level (m) | 43.356 |
| 7, 8 | Speed (km/h) and course (degrees) | 0.17, 0.0 |
| 9 | Fix mode | 1 |
| 11, 12, 13 | HDOP, PDOP, VDOP | 1.2, 2.6, 2.2 |
| 15, 16 | Satellites in view, satellites used | 13, 7 |
| 17 | GLONASS satellites (the SIM808 has none) | empty |
| 19 | Strongest signal, C/N0 in dB-Hz | 48 |
| 10, 14, 18, 20, 21 | Reserved fields and the position accuracy fields | empty |
Why does my SIM808 say 1980? Right after AT+CGNSPWR=1, before the receiver knows the time, +CGNSINF reports 19800105235944.000: 5 January 1980, 23:59:44, 16 s before GPS time begins (6 January 1980). You can see it as the oldest line of the AT check above. Once the GPS tracks satellites, the right date appears. A real SIM808 does exactly the same.
The sketch splits the line at the commas and keeps the fields it needs. Its comment lists all 21:
// AT+CGNSINF -> "+CGNSINF: <run>,<fix>,<UTC>,<lat>,<lon>,<alt>,<speed>,<course>,<fix mode>,,<HDOP>,
// <PDOP>,<VDOP>,,<satellites in view>,<satellites used>,,,<C/N0>,," (21 fields)
The Arduino Code
After finding the module, setupModule() puts it in the mode the rest of the sketch needs and switches the GPS on:
command("ATE0"); // no echo
command("AT+CMEE=2"); // errors as text
command("AT+CMGF=1"); // SMS in text mode
command("AT+CNMI=2,2,0,0,0"); // print new SMS directly (+CMT:)
command("AT+CLIP=1"); // show the caller's number (+CLIP:)
Serial.print(F("GPS: "));
Serial.println(command("AT+CGNSPWR=1") ? F("powered on (AT+CGNSPWR=1), first fix in about 30 s outdoors")
: F("AT+CGNSPWR=1 failed"));
Every SMS arrives as a +CMT: line followed by the text. For LOCATION (or WHERE), the sketch reads the GPS and builds the Maps link, or says how many satellites it sees without a fix:
if (!strcasecmp(text, "LOCATION") || !strcasecmp(text, "WHERE")) {
readGps();
if (gps.fix) snprintf_P(reply, sizeof(reply), PSTR("https://maps.google.com/?q=%s,%s"), gps.lat, gps.lon);
else snprintf_P(reply, sizeof(reply), PSTR("No GPS fix yet (%d satellites)"), gps.inView);
The SIM808 answers +CMGS only after the SMS has been delivered, so the sketch waits up to 30 s for it. The TRAFFIC card in the first image shows why: the last SMS text took 1829 ms until "+CMGS: 5 OK".
return waitFor("+CMGS:", 30000) && waitFor("OK", 2000);
New in v1.1: a line from the Serial Monitor that starts with "AT" goes straight to the SIM808, and the answer is printed with " < " in front:
if ((line[0] == 'A' || line[0] == 'a') && (line[1] == 'T' || line[1] == 't')) {
Serial.print(F("> "));
Serial.println(line);
gsm.print(line);
gsm.print('\r');
Also new: every 30 s, the sketch asks AT+CMGF?. A wrong answer means the module has restarted and lost its settings; no answer means it may even be off. Either way, setupModule(true) runs again, switches the GPS on and presses PWRKEY only if the module stays silent:
// every 30 s: is the module still set up? (a restart clears its settings and the GPS; a power-down switches it off)
if (restarted || millis() - lastCheck > CHECK_EVERY) {
char answer[24];
const bool ok = command("AT+CMGF?", "+CMGF:", answer, sizeof(answer), 1000);
if (restarted || !ok || answer[7] != '1') {
restarted = false;
Serial.println(ok ? F("The SIM808 restarted (settings lost) - setting it up again")
: F("No answer from the SIM808 (restarted or off) - setting it up again"));
If you change the sketch, load the new HEX file into both UNOs; see How to get the HEX file from Arduino. New to Arduino? Start with our Arduino Tutorial for Beginners.
Serial Monitor and SMS Commands
| Command | What it does |
|---|---|
| AT... (monitor) | Sent to the SIM808 as typed; the answer lines are printed with " < " until OK / ERROR |
| STATUS (monitor) | LED, GPS, signal (CSQ), registered or not, operator, up time |
| LOCATION (monitor) | The position as a Google Maps link, and the GPS line |
| TEXT <message> (monitor) | An SMS to the last number that texted the module |
| HELP (monitor) | The command list |
| LOCATION or WHERE (SMS) | A Google Maps link, or "No GPS fix yet (n satellites)" |
| LED ON, LED OFF, STATUS (SMS) | Switch the LED on A0, or a status reply; unknown texts get no reply |
How to Run the Demo
- Open the project, with the .hex file and both DLLs beside it, and press Run. Both Serial Monitors open at 9600 baud, and so does U2's pop-up.
- Watch the boards start OFF and the sketches pulse PWRKEY; after about 12 s both monitors show the command list, and about 10 s later the GPS fix.
- On U1's phone, tap SMS: LOCATION, LED ON (LED D1 lights) and STATUS; try LAHORE, CALL, INDOOR and OPEN SKY.
- In U2's pop-up, open the Test tab and run the five tools while you watch U4.
SIM808 Proteus Simulation Results
The Serial Monitor in Its Simple Interface
Both monitors in this demo run in the Simple interface of our TEP Serial Monitor, and every monitor screenshot in this article shows them that way. It keeps only the log, the send box and one slim toolbar row: baud rate, follow, pause, search and clear. The header, the quick buttons and the status bar are hidden, so the window stays small next to your schematic.
- Switch to it: right-click the log and choose Simple interface, or press Ctrl+Shift+U.
- Back to the full view: click the corner button (the expand arrows at the top right), press Esc or Ctrl+Shift+U, or right-click and choose Full interface.
- Your choice is remembered.
In the Simple interface, type commands such as LOCATION or AT+CGNSINF in the send box and press Enter; the quick buttons come back with the full view. RXD2, the monitor's second input, is not used here: the module's TXD wire to D8 runs between the RXD and PWRKEY wires, so a wire to it would cross one of them. The sketch prints the module's answers itself. In your own design, wire RXD2 to the module's TXD to watch the raw AT traffic and NMEA. Read all about the monitor in TEP Serial Monitor Advance for Proteus.
Start-Up
After Run, each monitor prints the start-up. Here is U3 in my Proteus run:
SIM808 GPS tracker - text LOCATION to get a Google Maps link
www.TheEngineeringProjects.com
Looking for the SIM808... no answer (it starts switched OFF)
Switching the SIM808 on: PWRKEY LOW for 1.2 s
SIM808 found: SIM808 R14.18
Waiting for SMS Ready... ok
GPS: powered on (AT+CGNSPWR=1), first fix in about 30 s outdoors
Waiting for the network...... registered
Signal: CSQ 22 (good)
Operator: TEP MOBILE
Time: 26/10/06,09:39:46+20
Ready - SMS commands: LOCATION (or WHERE), LED ON, LED OFF, STATUS
Serial Monitor: AT... (to the SIM808), STATUS, LOCATION, TEXT <message>, HELP
GPS: no fix yet, 13 satellites in view
Line by line: no answer to "AT", so the sketch pressed PWRKEY, read ATI, waited for SMS Ready, switched the GPS on and polled AT+CREG? once per second (the dots). "About 30 s outdoors" is the real module's time; here the fix comes after GPSTTFF. The Time line is your PC's local time: 26/10/06,09:39:46+20 is 6 Oct 2026, 09:39:46, and +20 is the time zone in quarter hours (UTC+5). The GPS lines use UTC.
SMS and GPS Lines
Every 10 s, the sketch prints a GPS line. Here is U4 while I tapped LOCATION, STATUS and LOCATION on the pop-up's phone:
Every SMS is announced by "(RI pin went LOW)", the INT0 interrupt of the RI pulse, then comes the text and the reply with "(sent)". Between them, the GPS lines say "fix, 7 of 13 satellites" with the position and the UTC time.
Typing Commands: LOCATION and AT+CGNSINF
Now type in the send box. I typed LOCATION, pressed Enter, then AT+CGNSINF. Lines you send carry a blue TX tag, the Arduino's lines a green RX tag:
LOCATION
Location: https://maps.google.com/?q=51.477865,-0.001486
GPS: fix, 7 of 13 satellites | lat 51.477865 | lon -0.001486 | alt 47.438 m | 04:46:33 UTC
AT+CGNSINF
> AT+CGNSINF
< +CGNSINF: 1,1,20261006044635.000,51.477864,-0.001490,48.023,0.17,0.0,1,,1.2,2.6,2.3,,13,7,,...
< OK
LOCATION printed the Maps link; AT+CGNSINF went straight to the module, and its raw answer came back with "<" in front (the long line runs past the window's edge). Above them, lines 60 - 68 show my phone clicks: the Lahore link, the rejected call, "no fix yet, 15 satellites in view" while INDOOR, and the fix back at HOME.
Useful SIM808 AT Commands
| Command | What it does |
|---|---|
| AT | Checks the module; send it first, because the SIM808 learns your baud rate from it |
| ATI, AT+CGMR | SIM808 R14.18; Revision:1418B05SIM808M32 |
| AT+CSQ, AT+CREG?, AT+COPS?, AT+CCLK? | Signal, registration (0,1 = registered), operator, network time |
| AT+CMGF=1, AT+CNMI=2,2,0,0,0 | SMS in text mode; new SMS printed directly (+CMT) |
| AT+CMGS="number" | Sends an SMS: type the text after "> " and end it with Ctrl+Z (26) |
| ATD+number; / ATA / ATH, AT+CLIP=1 | Call (don't forget the ;) / answer / hang up; caller ID on |
| AT+CPOWD=1, AT+CFUN=0 / 1 / 1,1 | Power down; radio off / on / restart |
| AT+CGNSPWR=1 / 0 | GPS on / off (off after every power-up) |
| AT+CGNSINF | The position line with 21 fields |
| AT+CGNSURC=n | A +UGNSINF position line every n fixes |
| AT+CGNSTST=1 | Streams the NMEA sentences GGA, GLL, GSA, GSV, RMC and VTG once a second on the same TXD |
| AT+CGNSCMD=0,"$PMTK101*32" | Sends a PMTK command to the GPS engine: 101 hot, 102 warm, 103 cold start |
| AT+CGPSPWR, AT+CGPSINF ... | The older R13 GPS commands, still accepted |
NMEA tip: at 9600 bps, the six NMEA sentences do not fit five times a second (PMTK220,200). The module then drops whole bursts and says so in the Simulation Log. Use 1 Hz, fewer sentences (AT+CGPSOUT) or a faster AT+IPR.
Troubleshooting
- "No answer from the SIM808": it starts OFF; hold PWRKEY LOW for more than 1 s (pin or board button) or set POWERON to AUTO. Check TXD -> D8, RXD <- D9, AltSoftSerial and "AT" first.
- The module switched itself OFF: PWRKEY was pulsed while it was running. Send "AT" first and pulse only when there is no answer.
- GPS OFF or no fix: send AT+CGNSPWR=1 (the GPS is off after every power-up and restart), wait GPSTTFF seconds and check that GPS SKY is not INDOOR.
- SMS arrive but the sketch sees nothing: send
AT+CMGF=1andAT+CNMI=2,2,0,0,0. - No answers after a restart: the module auto-bauds again and has lost its settings; send "AT" and set it up again.
- No phone, pop-up or monitor:
TEPSIM808.DLLorTEPSERIALMON.DLLis missing from MODELS and the project folder. For the Advance, click OPEN PANEL. - The red X does not close the phone: the design still holds the v1.0 symbol; replace TEPSIM808.LIB, delete TEPSIM808.IDX and re-pick the part.
Things to Know Before Using a Real SIM808
The demo sketch uses only standard SIM808 AT commands, so it is written for a real module too. Keep these points in mind:
- Power: the SIM808 needs 3.4 - 4.4 V (4.5 V absolute maximum) and draws up to 2 A peaks in its transmit bursts; below 3.0 V it may switch off. Never feed it from the Arduino's 5 V or 3.3 V pin: use your board's own supply input, with a common GND.
- 2.8 V logic: use the board's level shifter (VIO / VMCU set to 5 V), or put 10 k from D9 to RXD and 12 k from RXD to GND (about 2.7 V). The v1.0 README said 10 k / 20 k, which gives about 3.3 V, too high for the 2.8 V port.
- PWRKEY: it is pulled up inside the module; only ever pull it LOW.
- 2G only: you need a SIM card and a 2G network; the SIM808 does not work where 2G has been switched off.
- GPS antenna: it needs a clear view of the sky. The data sheet gives about 30 s for a cold start, and there is no fix indoors.
Limitations of the Simulation
- Not modelled: GPRS / TCP / HTTP, Bluetooth, PDU-mode SMS, audio, the SIM phone book and PIN, sleep modes, the supply current and brown-outs, SBAS / DGPS corrections, assisted GPS and motion (the module stands still).
- The network, operator, SMS centre and phone numbers are simulated; no real SIM is involved and no Google service is contacted: the Maps link is just text.
- The satellites are a simplified GPS sky seen from the chosen place: realistic in kind, but not the real satellites of that day.
- The model is our own implementation, written from SIMCom's published SIM808 Hardware Design, the SIM800 Series AT Command Manual and the SIM800 / SIM808 GNSS application notes; it contains no SIMCom or MediaTek firmware.
- Tested in Proteus 8.5 on 6 Oct 2026 (the demo and every Proteus screenshot here; the warm-start image is a PC render) and with 1,455 automatic checks on the PC; Proteus 7 is not supported.
Need only GSM? See our SIM800L Library for Proteus, SIM800C Library for Proteus or SIM900A Library for Proteus. Need only GPS? Try our NEO-6M Library for Proteus. And to send data without a SIM card, have a look at our HC-12 Library for Proteus.
So, that was all about the SIM808 Library for Proteus V1.1. I hope the virtual phone, the GPS strip and the five test tools make GSM + GPS projects much easier to understand, so your tracker works the first time you wire a real SIM808. If you use the SIM808 Library for Proteus in a project, please share your feedback in the comments or in our forum, and if you have any questions, ask in the comments and I will help you out. Till the next tutorial, take care and have fun!























Comments
0