Project Files of X27.168 Speedometer Gauge Library for Proteus V1.0 (Switec X25)
x27-168-speedometer-gauge-tep-v1-0-d563b64c593f4671ac148c9d753fca6d.zip

X27.168 Speedometer Gauge Library for Proteus V1.0
X27.168 Speedometer Gauge Library for Proteus V1.0 comes as a ZIP archive of 10 files (1.2 MB, 2.7 MB unpacked) holding Proteus library files, simulation model DLLs, a Proteus simulation, an Arduino sketch and compiled HEX firmware.
- LIBProteus library
- DLLProteus model
- DSNProteus simulation
- INOArduino sketch
- HEXHEX firmware
Description
X27.168-Speedometer-Gauge-Library-for-Proteus-v1.0.zip with the X27.168 gauge stepper in Proteus (a speedometer dial, two 260 ohm coils driven straight from four pins, the zeroing and lost steps; TEPX27.LIB and TEPX27.DLL), our Arduino UNO V4.0, the A4 demo project with its sketch and a README.
File Structure
5.1 KB201.9 KB32 KB883.5 KB325.5 KB883.5 KB325.5 KB24.1 KB21.4 KB16.7 KBGallery12 images from the tutorialOpen the tutorial
The circuit, the board and the results as they appear in X27.168 Speedometer Gauge Library for Proteus V1.0 (Switec X25). Open an image for its full size.












README
X27.168 SPEEDOMETER GAUGE LIBRARY FOR PROTEUS - V1.0 (the gauge stepper with a speedometer dial and a pop-up panel)
Designed by The Engineering Projects
www.TheEngineeringProjects.com
IMPORTANT LINKS
Article (read it first - pictures, step by step, every feature explained):
https://www.theengineeringprojects.com/2026/10/x27-168-speedometer-gauge-library-for-proteus-v1-0.html
Report a bug or suggest a feature (our forum):
https://www.theengineeringprojects.com/forum/category/motor-driver-proteus-library
The demo runs on our Arduino UNO V4.0 (included) - working LEDs, RESET and a
built-in serial monitor, no Virtual Terminal to wire - its own article:
https://www.theengineeringprojects.com/2026/10/arduino-uno-library-for-proteus-v40.html
Support us (the libraries are free):
https://www.theengineeringprojects.com/donate
FILE STRUCTURE
X27.168-Speedometer-Gauge-TEP-v1.0/
|-- Proteus Library Files/
| |-- ArduinoV4TEP.LIB 201.9 KB TEP Arduino boards V4.0 (UNO) -> LIBRARY
| |-- TEPX27.LIB 32.0 KB the library -> LIBRARY folder
|-- Proteus Model Files/
| |-- TEPARDUINO.DLL 883.5 KB the Arduino board model -> MODELS folder
| |-- TEPX27.DLL 325.5 KB the model -> MODELS folder
|-- Proteus Simulation/
| |-- TEPARDUINO.DLL 883.5 KB copy of the board model
| |-- TEPX27.DLL 325.5 KB copy of the model
| |-- X27_Speedometer_Demo.hex 21.4 KB the demo firmware
| |-- X27-Speedometer-Gauge-ArduinoUnoV4.pdsprj 24.1 KB the demo project
|-- Arduino Code/
| |-- X27_Speedometer_Demo/X27_Speedometer_Demo.ino 5.1 KB the demo sketch (source of the .hex)
|-- README.txt ~17.8 KB this file
Total: 2.66 MB (unzipped). The C++ source code of the models is not included.
WHAT IS IT?
A simulation model of the X27.168, the small stepper motor behind the needles
of car instrument clusters (the Switec X25 family) - the part makers use for
speedometers, tachometers and fuel gauges. Our own model, not a symbol on top
of Proteus's motor:
* Two coils, 260 ohm each, whose axes sit 60 deg apart, a two-pole magnet
rotor and a 180 : 1 gear train to the needle. The 6-state partial-step
sequence (0x9, 0x1, 0x7, 0x6, 0xE, 0x8 on A+ A- B+ B-) turns the field 60
deg a state: one step = 1/3 deg of the needle, 945 steps = 315 deg.
* Four Arduino pins drive it directly: about 17 mA a coil at 5 V (a pin can
give 20 mA). The current comes from the pins in the circuit - an ammeter or
a probe on a coil wire shows it.
* The needle has real end stops at 0 and 315 deg. Like every gauge sketch,
the demo zeroes at power-up: 1000 steps down, the needle pushes against
its 0 stop and the positions count from there.
* The rotor is a tiny magnet with inertia and friction: it follows 800 us
steps from rest and about 1400 steps/s (470 deg/s) with a ramp. Steps
that come too fast without a ramp - or a finger on the needle - are LOST:
the needle then shows the wrong value until the next zeroing, exactly the
fault you meet on the bench.
* The mistakes it names: lost steps (too fast, or the needle held), a coil
wire off (only one coil carries current), more current than a pin should
give, steps beyond the end of the scale.
The symbol: a white plate with the speedometer dial (0 - 240 km/h over the 315
deg sweep - property SCALE), the red-orange needle turned to the simulated
angle, the black X27.168 motor body with its four pins A+ A- B+ B- on top. A
click on the dial puts a finger on the needle (a click again lets go). The
plate, the dial, the coil LEDs A and B (green while the coil's current flows
from + to -, red the other way) and the strip under the plate (KM/H, DEG,
STEPS and OPEN PANEL) are TEP additions; the real X27.168 is the bare motor.
ONE DEVICE (search "X27" or "gauge" in Pick Devices):
X27168TEP "X27.168 Speedometer Gauge V1.0" (category Electromechanical >
Stepper Motors), model TEPX27.DLL
The pop-up panel "TEP X27.168 Speedometer Gauge" opens at Run (and with OPEN
PANEL on the strip) - the look of the TEP Serial Monitor. Tabs Gauge, Graphs,
Event log and Check; gear and ? icons for Settings and Help; the palette icon
switches the theme:
Gauge the state in big letters (SHOWING 180 KM/H / MOVING UP / LOSING
STEPS / AT THE 0 STOP - THE ZEROING / RELEASED), the dial - the
red needle and an orange mark where the coils ask -, the live
values (speed, needle, position, step rate, target, lost steps,
coil A, coil B) and the two coil currents over the last 20 ms:
the 6-state step pattern. The toolbar: "Hold it" - a finger on
the needle.
Graphs the needle and where the coils ask (deg), the step rate (steps/s)
and the coil current over the last 2, 6 or 15 s. Live / Freeze.
Event log coils on, the zeroing, every move ("HOLDING at 236.7 deg (710
steps) - from 6.5 deg, the move peaked at 1399 steps/s"), the
stops, lost steps, the warnings; filters All / Moves / Warnings,
Pause, Clear
Check Good for: a needle that does not move, only twitches, shows the
wrong speed, drifts or never settles at 0 - the coils, the
current, the steps, the rate, the zeroing and lost steps, each
with a verdict (green = fine, amber = check, red = wrong)
Settings theme, text size, open at Run, window size
Help report a bug, suggest a feature, article, updates, donate,
forum; Copy diagnostics for a bug report
TEST STATUS
V1.0: verified in Proteus 8.5 on 28 Oct 2026 (the demo project as shipped: an
A4 sheet, an Arduino UNO V4.0 with its built-in monitor, the gauge on D4 - D7,
RV1 on A0; the pop-up open).
What the runs showed (the needle's angle as the model computed it):
* The project loads and starts cleanly. The zeroing: 1000 steps down, "AT
THE 0 STOP", then "ZEROED" at 1.09 s; the self-test sweep: the needle to
315.3 deg and back to 0.3 deg, peaking at about 1400 steps/s (467 deg/s).
* RV1 at 75 %: "Pot 768 -> 180 km/h = 709 steps = 236.3 deg"; the needle
settled at 236.7 deg (one step above the count - after the zeroing the
rotor sits on the first field position above the stop), coils -16.7 /
16.7 mA, both coil LEDs lit, 0 lost steps.
* speed 60: 236 steps, the needle at 79.0 deg. sweep: up to 315 deg and back
(the Graphs page: the needle on top of the target). knob: back to 236.7.
* Hold it (a finger on the needle) and speed 30: the needle did not move,
the coils ran on - "lost 588 steps (594 in all, 198.0 deg)" in red. Let
go: the needle stayed at 235.7 deg - the sketch thinks it shows 30 km/h.
zero, then knob: back at 236.7 deg, 0 lost steps.
* The pop-up: Gauge, Graphs (2 / 6 / 15 s), Event log, Check - all four pages
followed the run.
Plus automatic checks on a PC, 0 failed: 19 on the gauge (the zeroing from
120 deg ends at 0.3 deg; the demo's start with no rest after the zeroing;
90 steps at 800 us from rest = 30.02 deg; 3 steps = 0.997 deg; 16.1 mA a
coil; the ramped sweep: 900 steps = 300 deg, top 1701 steps/s, nothing lost;
300 steps at 350 us without a ramp lose 282 steps; 2000 us steps are fine;
the upper stop at 315.4 deg; a finger holds the needle); 3 on the pop-up
pages rendered; the demo project read back from disk (63 checks: devices,
pins, wires, labels, no wire through a part, no wire crossing).
INSTALLATION (about 2 minutes)
1. Close Proteus. Extract the WHOLE ZIP to a normal folder (e.g. Desktop).
2. Copy everything in "Proteus Library Files" (TEPX27.LIB, and our Arduino
library V4.0, ArduinoV4TEP.LIB, with the ARDUINO UNO V4.0 used by the demo)
to the LIBRARY folder of Proteus, for example:
C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY
(on some PCs: C:\ProgramData\Labcenter Electronics\Proteus 8 Professional\
LIBRARY - use the folder that already holds Proteus's own .LIB files).
3. Copy TEPX27.DLL and TEPARDUINO.DLL from "Proteus Model Files" to the
MODELS folder (...\Proteus 8 Professional\MODELS).
ArduinoV4TEP.LIB and TEPARDUINO.DLL are the files of our Arduino Library
V4.0 - if you have it, they are the same.
4. Delete TEPX27.IDX from the LIBRARY folder if it is there (Proteus makes a
new index).
5. Start Proteus. In Pick Devices (P) search "X27".
RUN THE DEMO
"Proteus Simulation\X27-Speedometer-Gauge-ArduinoUnoV4.pdsprj" (an A4 sheet) -
keep the .hex file and the two DLLs beside the project.
ARD1: Arduino UNO V4.0 running X27_Speedometer_Demo.hex, its serial monitor
built in (window "TEP Arduino UNO - ARD1").
M1: the X27.168 gauge - A+ on D4, A- on D5, B+ on D6, B- on D7 (by the
net labels D4 - D7 above both parts).
RV1: a 10k potentiometer (POT-HG) on A0 - the speed: 0 - 240 km/h.
1. Press Run. The monitor and the gauge's pop-up open (move them aside -
they open over the schematic). The needle zeroes, sweeps to the end of
the dial and back, then goes to the pot's speed (RV1 at 75 %: 180 km/h).
2. Click RV1's arrows: the needle follows with a smooth ramp.
3. Type in the monitor and press Send: speed 120, step 30, sweep, zero,
knob - see THE DEMO SKETCH.
4. Click the dial (or "Hold it" on the pop-up): a finger holds the needle.
Type speed 30 - the steps are lost. Let go, type zero and knob.
5. The pop-up: Gauge, Graphs (try 15 s and Freeze), Event log, Check.
Closed a window? The monitor: click the UNO's USB port; the pop-up: OPEN PANEL.
WIRING (the same in Proteus and on a real board)
X27.168 pin Arduino UNO
1 (A+) D4
2 (A-) D5 coil A between pins 1 and 2
3 (B+) D6
4 (B-) D7 coil B between pins 3 and 4
Potentiometer the ends to 5V and GND, the wiper to A0
Any four digital pins work. The sketch writes the six states itself (the same
order as the SwitecX25 Arduino library), so no extra library is needed:
const byte MAP[6] = {0x9, 0x1, 0x7, 0x6, 0xE, 0x8}; // bit0 A+ .. bit3 B-
one step up = the next state, one step down = the one before
zero at power-up: 945 + 55 steps down at 800 us, then position = 0
move with a ramp: 3000 us a step at the start and the end, 600 us between
REAL HARDWARE:
* The coils take about 19 mA each at 5 V: the pins drive them directly.
Driver chips (VID6606, AX1201728SG) add microstepping for a smoother,
quieter needle - this model expects the 6-state steps from four pins.
* Zero at every power-up: a gauge never knows where its needle is.
* Never jump at full speed from rest: ramp up and down, or steps are lost.
THE DEMO SKETCH ON THE SERIAL MONITOR (X27_Speedometer_Demo V1.0, 9600 baud)
speed 120 show 120 km/h (0 - 240) and stay (the pot is ignored until knob)
step 30 30 steps up from the target (step -30: down; kept in 0 - 945)
sweep the self-test: to the end of the dial and back
zero 1000 steps down against the 0 stop, then count from 0
knob follow the pot on A0 again
help the list
EXPECTED MONITOR OUTPUT
X27.168 speedometer gauge demo - The Engineering Projects
A+ D4, A- D5, B+ D6, B- D7. The pot on A0 is the speed: 0 - 240 km/h.
Commands: speed 120 | step 30 | sweep | zero | knob | help
Zeroing: 1000 steps down against the 0 stop...
Self-test: the needle to the end of the dial and back
Ready - turn the pot
Pot 768 -> 180 km/h = 709 steps = 236.3 deg
PROPERTIES (double-click the part > Edit Properties)
SCALE the speed at the end of the dial in km/h (default 240); the dial's
numbers follow it - 120 for a small scale, 300 for a fast car
START the needle's angle at the start in deg, 0 - 315 (default 0): start
it at 120 to watch the zeroing bring it back
Every run starts again from the properties. The demo's UNO (ARDUINO UNO V4.0):
PROGRAM X27_Speedometer_Demo.hex, MONITOR YES (the built-in monitor), BAUD
9600, AUTOOPEN YES, BOOTLOADER YES.
LINKS.INI (OPTIONAL)
The Help page cards of the pop-up open web pages. To point them somewhere else
without a new DLL, put a text file named links.ini next to TEPX27.DLL with
lines KEY=URL, for example:
ARTICLE=https://www.theengineeringprojects.com/...
Keys: WEBSITE, FORUM, BUG_REPORT, FEATURE_REQUEST, ARTICLE, USER_GUIDE,
UPDATE_CHECK, DONATE. Only http:// and https:// links are used; lines starting
with # are comments.
TROUBLESHOOTING
* The needle never moves and the pop-up says RELEASED: no coil current - the
pins are not OUTPUTs, the wires go to other pins than the sketch's, or the
sketch never writes a state.
* The needle only twitches back and forth: two wires of one coil are swapped
with the other coil's (A+ / B+ crossed) - the field jumps instead of turning.
* "only coil A carries current": coil B's wires (B+ / B-) are off.
* The needle shows the wrong speed: steps were lost - the Event log and the
Check page show how many. Ramp the moves, and zero at power-up.
* The needle sits at an end: steps beyond the scale (more than 945), or the
sketch never zeroed and counts from the wrong place.
* The part is not simulated / the needle never turns: TEPX27.DLL is missing
from MODELS and from the project folder. No UNO / no monitor window:
TEPARDUINO.DLL is missing, or click the UNO's USB port.
* The pop-up does not appear: click OPEN PANEL on the strip, or turn "Open the
panel at Run" on its Settings page back on.
BUG REPORTS AND FEATURE REQUESTS
Please post them in our forum with a screenshot, the Serial Monitor text, the
simulation log and the pop-up's Copy diagnostics text:
https://www.theengineeringprojects.com/forum/category/motor-driver-proteus-library
SUPPORT US
This library is free. If it saves you time, please support our work:
https://www.theengineeringprojects.com/donate
WEBSITE
https://www.theengineeringprojects.com/
LICENCES AND THIRD-PARTY NOTES
* The gauge model (TEPX27.DLL), the symbol and artwork and the Arduino Library
V4.0 (ArduinoV4TEP.LIB / TEPARDUINO.DLL, with its built-in TEP Serial Monitor
Advance) are made by The Engineering Projects. The model is an independent
implementation written from the typical data of the X27.168 gauge stepper.
The model uses only standard Windows libraries; no Visual C++ redistributable
is needed. The C++ source code is not included.
* Arduino UNO V4.0 (ArduinoV4TEP.LIB / TEPARDUINO.DLL, our Arduino Library
V4.0 - its microcontroller is Proteus's own AVR model): The Engineering
Projects, https://www.theengineeringprojects.com/2026/10/arduino-uno-library-for-proteus-v40.html
* The potentiometer is Proteus's own POT-HG.
* The .hex file is built from the demo sketch and the Arduino AVR core 1.8.6,
which includes LGPL-licensed code; its source code is available at
https://github.com/arduino/ArduinoCore-avr/tree/1.8.6
* Proteus is a product of Labcenter Electronics and is not included. Arduino is
a trademark of Arduino SA. Switec and X27.168 are names used by their makers.
This library is not made or endorsed by the gauge's makers, Arduino or
Labcenter.
REBUILDING THE FIRMWARE (OPTIONAL)
The HEX file is supplied; Arduino IDE is not needed to run the demo. To edit the
sketch, open Arduino Code\X27_Speedometer_Demo\X27_Speedometer_Demo.ino, select
Arduino Uno and use Sketch > Export Compiled Binary. Replace the simulation's
.hex with the exported HEX. The sketch needs 7,786 bytes of flash (24 % of the
UNO) and 295 bytes of RAM.
MODEL SCOPE AND LIMITS
Modelled: the two coils (resistance, inductance, the back-EMF of the turning
magnet), the rotor's torque from both coil currents, the 180 : 1 gear, inertia,
friction and the damping of the rotor's ringing, both end stops, lost steps,
the current each pin gives, a finger on the needle.
How it runs: the coils are part of the analog circuit (each a resistor-and-
inductor companion model with its back-EMF, solved by Proteus with the pins'
own resistance); between two analog points the rotor runs in 5 us steps. The
analog step shrinks to 100 us while the needle moves.
Not modelled: microstepping drivers (VID6606 and similar), gear play, the
needle's bounce at a stop in detail, the spread from part to part, noise.
VERSION
TEP X27.168 Speedometer Gauge library V1.0 (Oct 2026). Device X27168TEP
(TEPX27.LIB / TEPX27.DLL). Demo sketch X27_Speedometer_Demo V1.0. Demo board:
ARDUINO UNO V4.0 (TEP Arduino Library V4.0) with its built-in serial monitor.Development1 release
-
V1.0X27.168 Speedometer Gauge Library for Proteus V1.0this page
V1.0 is the only release in the Download Center so far. When a newer version is published, it appears above with its own download page.
Installation8 steps
From the download to a working project, in order. The steps follow what the package contains.
You will need
- Proteus Design SuiteProteus 8 or newer (Labcenter), on Windows
- Arduino IDE1.8 or 2.x, with the board of the tutorial chosen under Tools → Board
- Any archive toolWindows, macOS and Linux extract ZIP files on their own
Steps
- 1
Extract the archive
Right-click x27-168-speedometer-gauge-tep-v1-0-d563b64c593f4671ac148c9d753fca6d.zip and choose Extract All (or open it with 7-Zip or WinRAR) into a folder you can find again. Keep its folder structure (X27.168-Speedometer-Gauge-TEP-v1.0) as it is.
- 2
Copy the library files into Proteus
Move ArduinoV4TEP.LIB and TEPX27.LIB and the files into the LIBRARY folder of your Proteus installation: C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY for Proteus 8, or the matching Proteus 7 folder. Older versions keep it under ProgramData\Labcenter Electronics. If Proteus is open, close it first.
- 3
Add the simulation model
Copy TEPARDUINO.DLL and TEPX27.DLL into the MODELS folder next to LIBRARY, so the component can run, not only be drawn.
- 4
Restart Proteus and place the component
Start Proteus, open a schematic, press P (Pick Devices) and search for the component by the name used in the tutorial. It appears with its pins ready to wire.
- 5
Open the sketch in the Arduino IDE
Open X27_Speedometer_Demo.ino, select your board and port under Tools, then Verify. Sketch → Export Compiled Binary writes the HEX file a simulation needs.
- 6
Load the HEX file
In Proteus double-click the microcontroller, set Program File to X27_Speedometer_Demo.hex and run the simulation. For real hardware, flash the same file with your programmer.
- 7
Open the example simulation
Open X27-Speedometer-Gauge-ArduinoUnoV4.pdsprj in Proteus to see the wiring exactly as in the tutorial. Check the controller's Program File path, then press Play.
- 8
Follow the tutorial
X27.168 Speedometer Gauge Library for Proteus V1.0 (Switec X25) explains every connection and setting in order; keep it open beside the files while you build.
FAQs9 questionsContact TEP
How do I download X27.168 Speedometer Gauge Library for Proteus V1.0?
Wait for the 30-second guest countdown on this page, then press the download button; the file comes straight from our storage. Members who are logged in skip the wait. If the browser opens the file instead of saving it, use its Save as option. The download link is made for you when the countdown ends and works for 15 minutes; a saved or shared link stops working, so share this page instead.
What is inside the archive?
X27.168 Speedometer Gauge Library for Proteus V1.0 comes as a ZIP archive of 10 files (1.2 MB, 2.7 MB unpacked) holding Proteus library files, simulation model DLLs, a Proteus simulation, an Arduino sketch and compiled HEX firmware. Open the File Structure tab for the full list of 10 files.
What should I do if the download does not start?
Check the browser's download list first; an ad blocker or a company firewall can also hold it back, so try another browser or network. If the file arrives incomplete, download it again. For an installation problem, read the Install tab or tell us in the comments with your software version and the exact error message.
Is this file free?
Yes. Every file in the TEP Download Center is free for learning, personal and student projects. If you share it, link back to this page or the tutorial so others find the latest version.
How do I check that the file arrived complete?
Compare its SHA-256 with the one on this page, e889a6c297f9bf26e86887e0a7783070dae47000facfffc2653ffa4269027040. In PowerShell run Get-FileHash "x27-168-speedometer-gauge-tep-v1-0-d563b64c593f4671ac148c9d753fca6d.zip"; on macOS or Linux run shasum -a 256 "x27-168-speedometer-gauge-tep-v1-0-d563b64c593f4671ac148c9d753fca6d.zip". The same value means the file is exactly the one in our storage; a different one means the download broke off, so download it again.
Do I need WinRAR to open the ZIP file?
No. Windows, macOS and Linux open ZIP archives on their own (Extract All, or double-click). WinRAR and 7-Zip work too. Extract the whole archive before using the files.
Where do I put the LIB and IDX files?
Both files go into the LIBRARY folder of your Proteus installation (Proteus 8: C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY; Proteus 7 has the same folder under its own name). Restart Proteus afterwards and search for the component with P.
Which Proteus version does the library need?
The tutorial names the Proteus version the library was made and tested with. Most TEP libraries work in Proteus 7 and Proteus 8; if the component does not appear after a restart, check that both the LIB and the IDX file were copied and that Proteus was fully closed while copying.
How do I get the HEX file into the simulation?
Compile the sketch in the Arduino IDE (Sketch → Export Compiled Binary gives you the HEX next to the sketch), then in Proteus double-click the board, set Program File to that HEX and run.
Members skip the wait. Log in or join TEP.
- 0Total downloads
- 4%Popularity
- ProteusCategory
- 0Comments
- ssyedzainnasirUploaded by
- 30 Oct 2026Uploaded at
e889a6c297f9bf26e86887e0a7783070dae47000facfffc2653ffa4269027040

















Comments
0