Giter VIP home page Giter VIP logo

usv-backend's Introduction

usv-backend

Python Linter

The system is under the project Robotx in National Chiao Tung University (Taiwan). Robotx aimed to build an intelligent system for unmanned surface vehicles, and this backend system is responsible for receiving sensor data from vehicles through the MQTT protocol, as well as providing APIs for administrators to access data.

Important parts of the system include a web server with Flask (Python), Database (MySQL), and an MQTT broker.

Run Services

Start Services

$ docker-compose up -d

Close Services

$ docker-compose down

Testing

$ docker-compose exec -e FLASK_APP=commands.py web flask test

DB migrations

$ docker-compose exec web flask db migrate -m "message"
$ docker-compose exec web flask db upgrade

Send Files through MQTT

  • Event: image
  • Size Limit: < 268435455 bytes (256 MB)
  • File Name Limit: < 256 characters
  • File Type: any
  • Dest: Files or Images will be storaged in /images by default

Format

  • File Name: File name with right-padding null characters. (256 chars)
  • Image Size: Image size with right-padding null characters. (16 chars)
  • File Content

Example

file_name_to_be_sent\0\0\0...\0 (<- total 256 chars)
107\0\0\0...\0 (<- total 16 chars)
\x89\x11\xa4...\x99

Testing

You can send files to the local mqtt broker with the test client:

$ docker-compose exec mqtt-recv python3 mqttrecv/test-sender.py images/test-tosend/example.png

Credits

This system is developed under Dr. Hsueh-Cheng Nick Wang's supervision. If you are intrested in this project, please contact [email protected] https://robotx-nctu.github.io/

usv-backend's People

Contributors

cowbonlin avatar hchengwang avatar zlewe avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.