Giter Site home page Giter Site logo

bs_lot's Introduction

BS_loT

2021 ZJU BS

目录结构

  • client-mqtt
    • backend:原有的IDEA iotclient工程,有做微小的修改
    • mqtt:从mqtt服务器接收数据发给后端
  • frontend-backend
    • frontend:前端,基于React
    • backend:后端,基于Flask

开发环境设置

可以按照以下顺序操作:

  • 启动mosquitto服务器。

  • client-mqtt/backend:

    原有的IDEA iotclient工程,按照原来方式运行即可。

    jar文件在target目录下,可以直接运行java -jar iotclient-1.0.0.jar

  • frontend-backend/backend:

    后端程序,可能需要配置,设置python虚拟环境:

    $ pipenv install --dev
    $ pipenv shell

    或者直接在本地安装环境:

    $ pip install -r requirements.txt

    运行:

    $ flask init-db # 建表并初始化,如果建过表会清空数据
    $ flask run # 启动后端
  • client-mqtt/mqtt:

    直接运行python mqtt.py即可,如果缺失库需要安装。

  • frontend-backend/frontend:

    $ npm install
    $ npm start

其中,client-mqtt/mqtt和frontend-backend/frontend的运行一定要在frontend-backend/backend后端程序之后,因为要和后端建立连接。

bs_lot's People

Contributors

bebinca avatar

Stargazers

 avatar  avatar  avatar

Watchers

 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.