Data collection web application for microcontrollers
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
SensorExamples
apache
config
docker
docs
src
static
teleceptor
teleceptor_connector
unittests
utils
.eslintrc.json
.gitignore
.htmlhintrc
.jshintrc
.sass-lint.yml
MANIFEST.in
README.md
basestationHOWTO.txt
basestation_startup
entrypoint.sh
htmlhint.conf
package-lock.json
package.json
requirements.txt
server_startup
setup.py
teleceptorcmd
webpack.development.config.js
webpack.production.config.js

README.md

Teleceptor

Teleceptor is an open-source data logger and feature-rich dashboard.

Features

Data-sources:

  • Serial
  • TCP
  • xBee
  • Soft sensors

Database support:

  • SQL
  • Postgres
  • ElasticSearch

Getting Started

Dependencies

  • pip 9.0.1
  • node 6.10.2
  • npm 3.10.10

Setting up Teleceptor backend

  1. git clone https://github.com/visgence/teleceptor.git
  2. run npm setup
  3. To install a local config customizable first run ./teleceptorcmd copyconfig app will print path
  4. In your config, you can set your Postgres and ElasticSearch settings.
  5. Run command ./teleceptorcmd runserver 0.0.0.0:8000.
  6. To load test data, run ./teleceptorcmd loadfixtures.
  7. Set up desired sensors and start collecting data.(See below for setting up sensors)

Setting up Teleceptor frontend

  1. Run command npm install

For development

  1. Run command npm run start. This will build the project, sets webpack to watch files, and runs the server at localhost:8000

For production

  1. Run command npm run buildProduction. This only builds the project and runs the optimization plugins for webpack.
  2. Run command ./teleceptorcmd runserver [ip:port]. Runs the server at ip and port if given, default is 0.0.0.0:8000

Example Data

The ./teleceptorcmd loadfixtures command will run a program that will create two datastreams and fill them with an hours worth of data in the form of a sine curve.

Example Sensor

The ./teleceptorcmd btcmote command will run a program that requests data from http://blockchain.info/ticker and sends the data to Teleceptor.

Sensor Firmware

Sensor firmware can be found in the firmware folder. Download the appropriate firmware for your type of sensor, and then upload it to your sensor.

Setting Up Sensors

Serial poller

  1. Plug in your sensor through a USB port.
  • Make sure you have the most current firmware for your sensor.
  1. Run command ./teleceptorcmd serialPoller PathOfSensor. This will begin to look for sensors via USB ports. Note: To find the name of your sensor, in a terminal window, type ls /dev/tty*. This will give you a list of all sensors currently connected.

Teleceptor Front-End Usage

  • To view sensor data that has been collected, click on a sensor stream under the Stream Select tab.
  • To look at a certain time period of data, select a range under the Time Controls tab.
    • Specific data can also be viewed by hovering the mouse on the graph to observe data points and the time it was collected.
    • By clicking and dragging on a certain part of the graph, you can zoom-in on points.
  • Some information about the sensor is editable and will change the graph accordingly such as Units or Calibration.
    • Be sure to save after editing so the configuration information to be available later.
    • Metadata cannot be changed. However, you can change it in the firmware and then re-upload the firmware to the sensor. (See Teleceptor Concepts)
  • If you download updates from Teleceptor but and are not sure if the webpage is up-to-date as well, clear your web browser's cache:
    • Chrome: Right-click in a blank spot on the page -> Inspect element -> Settings (gear symbol) -> Disable cache (while DevTools is open) -> Refresh the page
    • Mozilla Firefox: ctrl+Shift+R will reload the page without cache and/or ctrl+Shift+Delete -> Details -> Cache checkbox -> Clear Now

Setting up an mFi

  • cd .ssh
  • ssh-keygen
  • cat id_rsa.pub
  • copy the key given
  • ssh to mFi
  • vim authorized_keys
  • paste key
  • chmod 600 authorized_keys
  • enter 'save' in command line

Teleceptor Concepts

Sensor

The source location that posts data to the Teleceptor station api. Base data must include the sensors uuid and the names for each input/output source. You can find example firmware and software in the SensorExamples folder.

Datastream

Datastreams connect sensors to readings. If a sensor should fail or need to be replaced, it's uuid will change however its stream and history should remain intact. They also serve as an organizational tool for the front end. Datastreams are automatically created when a Sensor posts to the Teleceptor station api.

Sensor Reading

The raw value coming from a sensor attached to a timestamp of when the reading occurred and the data stream that it is connected to.

In the teleceptor/api folder, you will find a more detailed guide on how the api works.

License

2014 Visgence Inc.

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>

Notes: we don't run webpack using the '-p' flag in production because this auto sets uglyifly to use mangle which breaks angular. Instead we define the production environment ourselves and run uglyifly ourselves.