Download the PHP package track-any-device/drivers without Composer
On this page you can find all versions of the php package track-any-device/drivers. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download track-any-device/drivers
More information about track-any-device/drivers
Files in track-any-device/drivers
Package drivers
Short Description Device drivers and connectors for the Track Any Device platform.
License MIT
Informations about the package drivers
track-any-device/drivers
Device drivers and connectors for the Track Any Device platform.
Each driver encapsulates all protocol knowledge for a specific GPS tracker model — parsing incoming telemetry (stream or SMS), building outgoing commands, and managing device onboarding. The rest of the platform talks to every device through a single uniform interface.
Requirements
- PHP 8.3+
- Laravel 13.7+
track-any-device/core^0.0.2
Installation
The service provider is auto-discovered by Laravel.
Included drivers
| Driver class | Device | Stream channel | SMS fallback |
|---|---|---|---|
GF07Driver |
GF-07 Mini GPS Tracker | — (SMS only) | yes |
AOT120Driver |
AOT120 Vehicle GPS Tracker | JT/T 808 TCP | yes |
P901Driver |
Cantrack P901 Smart ID Card | JT/T 808 TCP | yes |
Core concepts
DeviceDriverInterface
Every driver implements TrackAnyDevice\Drivers\Contracts\DeviceDriverInterface. You interact with any device through this contract without needing to know which driver is underneath.
SignalObject
A readonly value object that carries normalised telemetry. Drivers populate whatever fields they can parse and leave the rest null.
Check for a usable position:
Stamp with server receive time (done by SignalService):
Serialise / deserialise:
Parsing incoming telemetry
Stream events (JT808)
The JT808 TCP server decodes binary frames and publishes a decoded array. Pass it straight to the driver:
SMS replies
Pass the raw SMS body as received from the gateway:
For drivers that only receive SMS (e.g. GF-07), you can also pass an event array with a raw key:
Sending commands
Request a location fix
JT808 drivers send a 0x8201 query over the live socket when the device is online (last signal within 10 minutes), falling back to an SMS command when it is not.
Set tracking mode
Add-on commands
Each driver declares its full command catalogue via addOnCommands(), which the Filament UI uses to render the command panel:
Execute a named command:
Onboarding a new device
Call onboardingAction once after a device is provisioned. It queues the full setup sequence (server IP, APN, timezone, default tracking mode) as SMS commands via DeviceCommandObserver:
Commands are dispatched asynchronously — the observer picks up each DeviceCommand row and routes it through SMSConnector.
Stream routing
JT808 drivers (AOT120Driver, P901Driver) determine whether the device is reachable over the live socket by checking last_signal_at:
When the stream is available, commands are published to a Redis pub/sub channel:
The JT808 TCP server subscribes to this channel and writes the encoded frame to the open socket.
Adding a new driver
- Create a class in
src/that implementsDeviceDriverInterface. - Use the
QueuesSmsCommandstrait if the driver sends SMS commands. - Implement
buildSmsBody(string $commandType, array $params): ?string— return the raw SMS string for each command type, ornullto skip. - Register the driver in your application's
DriverRegistry(provided bytrack-any-device/core).
SMSConnector
TrackAnyDevice\Drivers\Connectors\SMSConnector implements DeviceConnectorInterface and dispatches outgoing messages through SmsGatewayService. It is resolved from the container automatically when bound:
The connector updates the DeviceCommand status to Queued → Sent (or Failed) as the message progresses.
Changelog
See GitHub Releases.
Licence
MIT
All versions of drivers with dependencies
laravel/framework Version ^13.7
track-any-device/core Version ^0.8.0
track-any-device/sms-gateway Version *