Giter VIP home page Giter VIP logo

mobject-io's Introduction

mobject-io's People

Contributors

benhar-dev avatar txae avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mobject-io's Issues

Read Me:

Nothing in the Read me mentions that this project is only for TwinCats.

There are some repo topic tags but they are not obvious.

I would recommend making it clear in the Read Me that this is just for TwinCats.

I was interested in this for Vanilla Codesys, but it seems like it would be a main to maintain a fork on my own.

mobject-json - cycle time

You could save a massive amount of cycle time if you don't recreate the json path with dynmaically created function blocks, but call the FindMember method directly while parsing the path.

cyclic call happens via index and not via enumerator

Since each module is first searched for in the linked list via index, the loop is 100 * (100+1)/2 = 5050 for 100 modules. With 500 modules it is 125,250 and with 1000 modules 500500. It is faster to run through the linked list with an enumerator.

Diffrent point of view about class .CyclicCall() usage

First, thank you for this amazing work. This is THE thing I searched to get a decent coding guidelines. Just one thing:

https://github.com/benhar-dev/mobject-core/blob/3b642c1ad05c211ea7a5e8be90324150d8932271/docs/coding-guide.md?plain=1#L115-L117

Ok this make total sense for most of the things (I do) in OOP. But I am against the CyclicCall method.

For cyclic call I would prefer to use my FB not as 'pure' class but let them live in the real-time / cyclic context and thus use the body, the INPUT_VAR and OUTPUT_VAR section. Since we can call SUPER^() to call the implementation of the body of the parent class, I don't see why it should be avoided?

Imagine something like this:

// Real time part, all fb are used as usual
gripper(sensorRP  := IN.I101_ST101_gripper_RP,
        sensorWP  := IN.I102_ST101_gripper_WP,
        out_valve => OUT.Q101_ST101_gripper);

// station step management
CASE stepCurrent OF
// ~ some code ~
ST101_Step_e.PICK_PIECE:

    gripper.Pick();

    // IF gripper.IsPicked() THEN or
    IF gripper.piecePicked THEN
        stepCurrent := ST101_Step_e.DO_SOMETHING;
    END_IF
// ~ some code ~
END_CASE

Isn't that beautiful? How could you do this using the cyclical call method? How the hardware input should be used by the function block? Of course a property is way more powerfull as a standard input, but do we need this power? Is there advantages of such a CyclicCall method?

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.