GithubHelp home page GithubHelp logo

michaelchi08 / embedded Goto Github PK

View Code? Open in Web Editor NEW

This project forked from minxinfeng/embedded

0.0 2.0 0.0 1020 KB

The final project about the Embedded System & Embedded Linux Development Class: GPS Location and Calculation Route Project

QMake 1.92% C++ 98.08%

embedded's Introduction

GPSMapProject

The final project about the Embedded System & Embedded Linux Development Class: GPS Location and Calculation Route Project

Project Requirement

  1. Make the map data.
    • Map format: make your university campus map by the specific format( should include longitude and latitude ).
    • Construct road network.
    • Map block: divide map into some blocks averagely.
  2. Load the map block which the current point belongs to in the screen when moving GPS.
  3. Show latitude and longitude of the current point in the screen when moving GPS.
  4. Calculate the route of start point and end point.
    • if there is no enough power cord, you may save the start point to file, when restart ARM board load the start point again, then calculate the rout after set the end piont.

SubProject

The process flow as following:

  1. Show latitude and longitude of the current point in the screen when moving GPS. When click the "start" button,capture the position data: latitude and longitude, and save these data into file "/data/map/start.txt", and marked this point as the start position on the map.

  2. When click "stop" button, find the road from start to the end. Show the road and mark the end position on the map.

get the road

How to get the road?

  1. Read all the nodes info we collected before from the file "data/map/node.txt", which save the info of the posNode:
	int id;		//the unique id of the node
    int x;
	int y;
	float latitude;
	float longitude;

All the node info will store in: list nodes

  1. Read all the map info from file "/data/map/graph.txt", and all the data store in a two-dimensional array -- map[i][j]: means weather i and j is connected, 0 is not, 1 is connected.

  2. Read file "/data/map/start.txt" to get the start position, and find the nearest point of the start point.

  3. Find the nearest node we collected of the start node and end node.

  4. Get the shorted path node id by floyd algorithm, all the ids store in: list ids;

  5. Get the detail info of the nodes and return the list pathNodes

embedded's People

Contributors

minxinfeng avatar kylewang1005 avatar lcmm avatar yangruiemma avatar

Watchers

James Cloos avatar Michael 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.