Skip to content

Open-VTS/OVTS-Device

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Open Vehicle Tracking System

OVTS

OVTS Overview

OVTS is an Open-source Vehicle Tracking System project based on GPS. It can track the device based on GPS data and send information to the main server (AKA Center). It can be mounted on a car or any other vehicles. The communication is over on GPRS and SMS. The device has other features like output relay, input voltage sensor, IMU sensor, etc. This project covers Device-side, Server-side and a User Panel.

This project is open source and is independent on ANY ONLINE SERVICES.

The project consists of four separate repositories:

OVTS-Device

OVTS-Device is the device application of OVTS project. This repo contains device application and hardware schematics and PCB gerber files for device manufacturing.

OVTS-Device Features

  • Small Dimensions about 80mm x 58mm x 6mm (HWD).
  • High processing power based on ARM Cortex-M4 STM32F407.
  • Communication over HTTP and SMS message and both (DUAL Mode).
  • Internal report system.
  • Wide input voltage range from 9V to 36V.
  • Nine-Axis (Gyro + Accelerometer + Compass) IMU Device.
  • Built-in relay to turn on/off the vehicle or other devices.
  • Input voltage sensor to detect vehicle start/stop.
  • Built-in RTC (Real Time Clock).
  • Builtin SDCard for saving reports.
  • Built-in Lithium battery with onboard charger (lasts about 6Hours).
  • Sleep mode to save power.
  • Audio Jack for phone communication (in progress).
  • Expansion onboard headers for further developments.
  • Totally open source based on ARM mbed framework.
  • Robust circuit and PCB design.
  • Fully customizable with Desktop App without need to reprogram device (in progress).
  • Work with GPS and AGPS (in progress).
  • Wide operating temperature -30~85 °C (may vary based on hardware components).
  • Works with a wide range of 3.7v Lithium Batteries (Lithium-polymer and Lithium-ion).

Hardware Specifications

  • Supply voltage circuit based on Ti TPS5430/50 DC/DC switching regulator.
  • 3.7v Lithium charger circuit based on Microchip's MCP73831.
  • Based on STM32F407VG a High-performance ARM Cortex-M4 chip.
  • Developed based on ARM mbed-os.
  • Onboard 5v Miniature Relay.
  • Input voltage sensor (5v to 36v).
  • Onboard GSM antenna.
  • Based on Quectel's MC60 GSM/GPRS module.
  • Builtin Opto-couplers (PC817) isolation for input and output.
  • Works with any
  • Software environment fully based on VSCode IDE with configs to generate and debug code.

Usage

For a basic setup you need at least one working device and the OVTS-Server.

Requirements

  • An assembled board.
  • An STM32 programmer (like stlink).
  • GSM Antenna (external and PCB antenna).
  • GPS Active Antenna.
  • CR1220 Coin battery.
  • A Dedicated Server.
  • An SD Card (if you need reports).
  • A working Micro Sim Card.
  • The Server App hosted in the network.

Device

  1. Order the PCB to a PCB Manufacturing service. The PCB is a typical FR4 double layer board. This board needs at least 0.1mm precision manufacturing.
  2. Assemble Parts (You need to have good skills on soldering SMD components if you want to solder by yourself).
  3. Power on the board and the Power LED should turn on.
  4. Edit Server parameters and APN names in both core.h and modem.h .
    1. Set DEFAULT_CENTER_ADDRESS for server address and set center numbers in DEFAULT_CENTER_PARAMS.
    2. Currently, there are two APN names have been defined in modem.h which are OP_MTN and OP_MCI. You need to first find out Your APN name string and add them like the template. For example OP_MTN string would be MTN Irancell and the equivalent APN name (which must be set to access internet connection) is mtnirancell. Also, if you have a custom APN name you need to add it as OP_***_CUSTOM_APN and set the USE_CUSTOM_APN in core.h.
  5. Compile and upload source to the board using compile section
  6. If everything works fine, the Status LED should blink. Also, I suggest you to use the debug cable to see the current output.

Compile Source Code

The workspace is compatible with VSCode and has the ability to directly compile and program the source without any external application. It uses VSCode Tasks mechanism to compile and upload the binary to the device.

  • You need to grab ARM GCC compiler and change the path in launch.json.
  • For upload and debugging you need to grab OpenOCD and set the proper path in tasks.json and launch.json.
  • If everything works fine, you can use build and upload tasks to compile the source and upload binaries to the device.

Troubleshooting

  • Before doing anything first make sure that the server is up and running and can be accessed remotely.

  • After turning the device on, make sure that the modem is up (the LED1 would blink). You can check this by dialing the sim number.

  • If everything works fine, the Status LED would blink.

  • On Startup device would check these in order and if failed on each state the Error LED would blink and then reset the device:

    • Check IMU (1 blink on failure).
    • Check Sim Card (2 blinks on failure).
    • Check the modem network connection (3 blinks on failure).
    • Check internet connection QIACT (4 blinks on failure).
    • Check Center Connection (5 blinks on failure).
    • Check SD Card (6 blinks on failure) no reset on failure.
  • Connect a serial-to-USB cable to header P5 and see the output on a serial monitor app.

  • If you still have other issues you can create a new issue.

  • The project has built and tested with mbed-os v5.13.0 and should work with the most recent version.

TODO

  • Add more secure protocols like HTTPS.
  • Add request report file and remove auto send the report on device.
  • Improve source code and documentation.
  • A 3D printed layout box for the device.
  • Improve README file for better understanding.

Some open-source projects that have been used in this project

Credits

Releases

No releases published

Packages

No packages published