GithubHelp home page GithubHelp logo

red's Introduction

RED

Rapid Embedded Development

Getting started

  1. Use the folders specified below in "Filestructure"
  2. Copy the red/init-sample.conf into config/init.conf

Dependencies

  • configparser
  • pyzmq
  • pyside*
  • sqlalchemy*
  • pyserial*

*can be avoided, but are used by some standard services.

Filestructure

To use RED in your project you need the following file structure:

 <projectfolder>/
 ............... layouts/
 ............... config/
 ............... helpers/
 ............... activities/

Activities

The core of any RED project is the actitivies. Inherit from the red.activity.Activity to create your own activities. To get documentation use:

 pydoc red/activities.py

Config

To use the init.conf you need the following line:

from red.config import config

Usage:

config.get('Section','Option')

Services

Besides activities services are essential. Services run in their own thread, and are used to connect to drivers (See drivers) To create your own service inherit from red.services.base.Service and Thread. The reason we must explicitly inherit from Thread and not just make the base service do so is that the standard sarvice named display must use QThread to work. (If you forget the Thread you will have a deadlock`) Here is an example:

from red.services.base import Service
from threading import Thread

class Keyinput(Service,Thread):

    def processMessage(self,message):
        #Do somthing here
        pass

Drivers

Drivers are the used to connect to physical devices. Currently only one standard drivers is included, namely the NfcReader which wraps the api of an NFC reader.

red's People

Contributors

saspre avatar steiniche avatar abondoa avatar

Watchers

 avatar  avatar  avatar Simon Lennart Sahlin 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.