GithubHelp home page GithubHelp logo

node-red-contrib-pythonshell's Introduction

Executing a python script from node-red. Input to the node will become the argument for the python script, output of the script will be sent to output of the node.

Example flow:

[{"id":"a1b2b31b.65fe7","type":"tab","label":"Flow 1"},{"id":"3df34b3a.b6bb8c","type":"pythonshell in","z":"a1b2b31b.65fe7","name":"","pyfile":"/Users/namtrang/main.py","x":341.5,"y":154,"wires":[["f811cd5c.e9dfe8"]]},{"id":"f4dcbeae.1da998","type":"inject","z":"a1b2b31b.65fe7","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":140.5,"y":76,"wires":[["3df34b3a.b6bb8c"]]},{"id":"f811cd5c.e9dfe8","type":"debug","z":"a1b2b31b.65fe7","name":"","active":true,"console":"false","complete":"false","x":537.5,"y":233,"wires":[]}]

And this is the content of the python script:

import sys
print "Got arguments: ", sys.argv

node-red-contrib-pythonshell's People

Contributors

namgk avatar

Watchers

 avatar  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.