Giter Site home page Giter Site logo

langleu / tfstubserver Goto Github PK

View Code? Open in Web Editor NEW

This project forked from playwithit/tfstubserver

0.0 1.0 0.0 5.84 MB

A software emulator for Tinkerforge Hardware

License: GNU General Public License v3.0

Makefile 0.26% C++ 64.50% C 35.21% Shell 0.02% Dockerfile 0.01%

tfstubserver's Introduction

TFStubserver

A software emulator for Tinkerforge Hardware

This software emulates some of the Tinkerforge hardware (see http://www.tinkerforge.com) on network protocol level. A client can connect as if it would connect to 'brickd'.

The emulator fully supports callbacks and configurable sensor values. The configurable sensor values are in some kind "predictable", which is useful for unit testing. In combination with a Qt based UI (see https://github.com/PlayWithIt/TFStubViz), you can manually override/control the sensor values using sliders or buttons (depending on the type). Doing this you can for example test some extreme or very specific combinations.

See this page to get a list of supported Tinkerforge devices and a short introduction: http://www.tinkerunity.org/wiki/index.php/DE/Projekte/Stackemulator_%28stubserver%29

Requirements:

  • Linux (also compiles on Tinkerforge's RED Brick or RasPi)
  • g++ 4.6.3 or higher (as on Raspberry PI, OpenSuse 13.1)
  • clang++ 3.3 (llvm) or higher should work too
  • optional: ALSA devel packages (libasound2-dev on Debian, alsa-devel on OpenSuse)

Compile:

  • run make or make -j4 in the base directory for a debug-build
  • or run make CONFIG=Release for an optimized build
  • or run make USE_LLVM=1 for a build with clang++
  • or run make DONT_USE_ALSA=1 to exclude ALSA support if ALSA is not installed

Example:

  • example configurations are in src/stubserver, look for *.properties (e.g. motion.properties). The properties are used for device configuration
  • Sensors mostly use a 'ValueProvider' which calculates the values or reads the value from a text file (when when value changes + value).
  • see stubserver -? for command-line options
  • src/stubserver/stub is an example to start the server on port 4225
  • your application or brickv can then connect to the emulated devices via localhost:4225

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.