• Categories
    • Recent
    • Tags
    • Popular
    • Register
    • Login
    1. Home
    2. jkandasa
    Offline
    • Profile
    • Following 2
    • Followers 11
    • Topics 40
    • Posts 1,221
    • Groups 1

    jkandasa

    @jkandasa

    ADMIN
    80
    Reputation
    3.2k
    Profile views
    1.2k
    Posts
    11
    Followers
    2
    Following
    Joined
    Last Online
    Website mycontroller.org

    jkandasa Unfollow Follow
    ADMIN

    Best posts made by jkandasa

    • MyController 2.0.0 released

      MyController v2.0.0 released 🎉

      https://www.mycontroller.org/docs/

      posted in Announcements
      jkandasaJ
      jkandasa
    • Mycontroller 2.x ideas

      Hello everyone,

      MyController was born around August 2015. Currently, version 1.0.0 available for public and before 25, December 2017, version 1.1.0 will be available for the public.

      • I see some performance issues with MyController when we have a number of sensors grow.
      • We need end user-friendly GUI. I believe for now we have only admin friendly GUI.
      • There is no mobile application.
      • Supports more databases. H2DB, MySQL, MariaDB, PostgresSQL. To reduce complexity support only for one DB or maximum two databases.
      • and more

      To rectify all these issues, I am planning to build MyController 2.x from scratch. With the following technologies.

      • Spring boot with Undertow GoLang
      • Angular 4 front end ReactJS
      • Ionic mobile application Reactive native
      • Two type databases
        • RDBMS for sensor metadata In-Memory and MongoDB for data
        • InfluxDB for metrics
      • backup/restore as CSV YAML or JSON file(except metrics data)

      Still, I want to keep MyController's primary platform as Rasberry PI.

      Kindly share your experience with influxDB and raspberry PI in the long run. Also, share your thoughts on this big move.

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: How to set sensor value with javascript

      @seant

      var pingDistance = tankDistanceSensor.value; //Water tank level percent

      You have to use parseInt(tankDistanceSensor.value), Sensor variable always have String value.
      var pingDistance = parseInt(tankDistanceSensor.value); //Water tank level percent

      //THESE 2 LINES DO NOT SEEM TO SET THE VALUES
      tankLitresSensor.setValue(litres);
      tankPercentageSensor.setValue(percentage);

      After these two lines add the following lines,

        mcApi.sensor().sendPayload(tankLitresSensor); 
        mcApi.sensor().sendPayload(tankPercentageSensor); 
      
      posted in Developers Zone
      jkandasaJ
      jkandasa
    • MyController 2.x development work started

      I started working on MyController version 2.x.
      Existing repository renamed to mycontroller-v1-legacy.

      Version 1.x: https://github.com/mycontroller-org/mycontroller-v1-legacy

      Version 2.x: https://github.com/mycontroller-org/backend and https://github.com/mycontroller-org/console-web

      posted in Announcements
      jkandasaJ
      jkandasa
    • RE: Forum logo transparency

      @Avamander Thanks for the pointer. Discourse needs more resources than NodeBB. We do not have that much budget.
      So, for now, we do not have any plans to upgrade.

      posted in Developers Zone
      jkandasaJ
      jkandasa
    • RE: Battery level in rules or chart? [Script Rule to check battery level]

      @DaTTcz For now direct battery support not available on Rules. However you can do it from script. I will update how to handle with script.

      Kindly create a request on github page to support battery level on rules.

      ALL these features are available on SNAPSHOT build

      Enter your condition via script,

      Steps:

      • Create UID Tag for your node,
      • Create script to check node battery level (script type: Condition)
      • Create rule with this condition script
      • Enjoy 🙂
      Create UID Tag:

      0_1479454456642_upload-6bd6f2c1-24c2-431c-b97e-6ae08892003c

      Add script:

      0_1479454321011_upload-df8f276c-45cd-4c6c-9ef2-1de1c50f4445
      Java Script to check battery level,

      var myImports = new JavaImporter(java.io, java.lang, java.util, java.text);
      
      with(myImports) {
        var mcResult = false; //By default this is false. When your condition meets change this to true
        var batteryLevel = mcApi.uidTag().getByUid("node1").resource.batteryLevel;
        if(batteryLevel >= 50){ // Your condition
           mcResult = true;
        }
      }
      
      Add rule:

      0_1479454517098_upload-ec78f98b-ead9-442b-80aa-28eda4e10dd4

      posted in Scripts
      jkandasaJ
      jkandasa
    • RE: Multiple NRF24L01+ gateways

      @skywatch Thanks for the logs. Can you edit and save again gateway2 and see the behavior?

      posted in General
      jkandasaJ
      jkandasa
    • RE: 0.0.3.Final pre-release - volunteers required to test

      @Tetnobic

      Data retore complete log message is show 7 seconds after shutdown message log, but it works

      Looks like taking some time to restore on your machine.
      However, the following message says shutdown complete. Which leads confusion for you. I will sync these messages. Thank you! No worries 😄

      2017-01-17 11:21:28,290 INFO [MyController.org Shutdown-Hook] [org.mycontroller.standalone.AppShutdownHook:36] Bye, Have a nice day! See you soon
      
      
      posted in Announcements
      jkandasaJ
      jkandasa
    • RE: Integrate Blockly

      @blacksheepinc Hi, Yes, I had a look. And looks like we can implement with MyController with some new implementation to support for JSR223 standard(which is used in Java). Kindly create a request on github.com/mycontroller-org/mycontroller/issues When I get time I will work on this. Thank you!

      posted in Developers Zone
      jkandasaJ
      jkandasa
    • How to delete a sensor variable from script

      For now, there is no option to delete a sensor variable alone from the GUI. So I'm providing an option to delete a sensor variable from a script.

      Note: This API available from 1.4.0.Final version.

      • Now get SensorVariable id from Sensors page. Resources >> Sensors >> Click on view details,
        0_1482765833386_upload-d79d7e6b-d0f6-4bc6-b6b6-0366b8968b09
        Now click on edit of sensor variable
        0_1482765892413_upload-5797ae73-a6ee-4dec-b810-928013f4c2d3

      On the URL you can see sensor variable id, This is id is important note it for your target sensor variable
      0_1482765974523_upload-1240a386-2016-4a96-b144-d2444df9fc73

      Add the following script on your controller,
      Extension: JavaScript
      Type: Operation

      var myImports = new JavaImporter(java.io, java.lang, java.util);
      
      with(myImports) {
        // pass sensor variable as bindings, example: { id: 99 }
        mcApi.sensor().deleteSensorVariable(id);
      }
      

      Execute the script as Run now (select the script and in Actions you can see Run now),
      Pass the sensor variable id as bindings, here it is { id: 99 },
      0_1539689727209_cb4a5f9a-3264-4844-9f1f-920f7c76d063-image.png

      Click on Run. All done. Now your Sensor variable removed from MyController.

      posted in Scripts sensor variable sensorvariable script javascript
      jkandasaJ
      jkandasa

    Latest posts made by jkandasa

    • RE: Trouble migrating from executable to docker image.

      Are the mycontroller.yaml setting the same for the binary and the docker container?

      Yes, same file/schema used on binary as well as for container.

      @rayven you have to point to your influx db location, docker container always runs on it's own network space, if you specified http://localhost:8086, it tries inside container. Put your host ip address on it. also enable the metric database.

      • installation with docker container: https://mycontroller.org/docs/installation/quick-installation/docker-container/
      • install influx database: https://mycontroller.org/docs/getting-started/install-influxdb/
      • backend configurations: https://mycontroller.org/docs/installation/advanced-installation/backend-configuration/
      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: JavaScript evaluation question.

      @rayven for now, there is no documentation on it. I will prepare an example for you

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Trouble migrating from executable to docker image.

      @rayven yes, it is possible via backup restore, can share your docker command to run the MyController?

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Request failed with status code 401

      Hi @wint0178, when you logged in to the server, if you see this error, it was happened before login.
      If it comes only one time and all other functions are working as expected, please ignore this error.

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Request failed with status code 401

      @wint0178 can you access the server on the localhost or in LAN?
      Are you seeing the error on UI? Can you share the screen shot?

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Trouble with MC v2 install on RPi 4

      Thanks @wint0178 !!
      I will go through the installation documentation and sync with your update.

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Trouble with MC v2 install on RPi 4

      @wint0178 Thanks for the details
      I see you have an trailing space after \ ("--env TZ="Asia/Kolkata" \ "), that leads restart command not found
      I have updated your timezone and removed the extra space, can you please try the following command to start the MyController server?

      go to your mycontroller directory(root of mc_home and location of mycontroller.yaml) and run the following command

      docker run  --detach --name mycontroller \
        --network mycontroller \
        --publish 8080:8080 \
        --publish 8443:8443 \
        --publish 9443:9443 \
        --volume $PWD/mc_home:/mc_home \
        --volume $PWD/mycontroller.yaml:/app/mycontroller.yaml \
        --env TZ="America/Chicago" \
        --restart unless-stopped \
        docker.io/mycontroller/server:2.0.0
      

      If it doesn't comes up please run the following command, I just removed the --detach(don't run on background) and added --rm (remove the container on termination)

      docker run  --rm --name mycontroller \
        --network mycontroller \
        --publish 8080:8080 \
        --publish 8443:8443 \
        --publish 9443:9443 \
        --volume $PWD/mc_home:/mc_home \
        --volume $PWD/mycontroller.yaml:/app/mycontroller.yaml \
        --env TZ="America/Chicago" \
        --restart unless-stopped \
        docker.io/mycontroller/server:2.0.0
      

      I assume if I uninstall docker to try and update it using the code you include in the documentation, as you suggested, that I will also need to reinstall influxdb, natsio, and mqtt. Is that correct?

      Yes, In the docker just removes the containers and creates from fresh.

      I was just messing with your install from executable binary instructions and I got the MC server running and can pull it up at localhost:8080. When I run docker ps -a I am still getting the same three services running: mqtt, influxdb, and natsio. Is this correct?

      executable is different than the docker. It will not be come under docker ps command.
      It executes directly on the host system.
      I would recommend to use docker version of mycontroller, for the portability and maintainability

      the running server on localhost has a warning that the Metrics database is disabled. I assume this has to do with installing MC from the binary, but it feels like progress anyway.

      This is because, executable which is running on outside of docker network and can not resolve the hostname used inside docker. If you replace hostname of mc_natsio, mc_influxdb to localhost on your mycontroller.yaml [1] should work. However, I would recommend to try the docker version of mycontroller.

      [1] - If you apply this change, it will not work on docker version of mycontroller

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Trouble with MC v2 install on RPi 4

      @wint0178 What is the log do you see on the mycontroller container?

      docker logs mycontroller
      

      and what is the output of,

      docker ps -a
      

      This is where I get hung up, but I'm not sure if I have settings above here incorrect or if there is something wrong with the following install/run commands.

      Can you please elaborate? Does the terminal hung to return?

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Setting up MQTT

      @wint0178 on the other post, I see you were able to see the nodes. Still do you see this issue?

      posted in General Discussion
      jkandasaJ
      jkandasa
    • RE: Setting up MQTT

      @wint0178 Are you using MySensors library?
      Your MQTT broker should be accessible to all of your hardware gateway nodes and MyController server. MyController server is acting as MQTT client, just like another MQTT device in your network.

      posted in General Discussion
      jkandasaJ
      jkandasa