Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
S

samppa

@samppa
About
Posts
92
Topics
13
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Requirements for controller integration/support for MySensors?
    S samppa

    @hek Thanks! Is there any documentation available about the controller integration?

    Controllers

  • Is HTTPS request from LUUP code possible?
    S samppa

    Thanks @hek

    I got it working with CURL:

    local pw = 'xxx'
    local un = 'xxx'
    
    --login request
    local url_1 = 'https://mypages.verisure.com/j_spring_security_check?locale=fi_FI'
    local command_1 = "curl -c '/tmp/log/cmh/cookie.txt' -d 'j_username="..un.."&j_password="..pw.." "..url_1
    local f_1 = assert(io.popen(command_1, 'r'))
    local response_1 = assert(f_1:read('*a'))
    f_1:close(f_1)
    luup.log("Verisure login response: "..response_1)
    
    --armed status request
    local url_2 = 'https://mypages.verisure.com/remotecontrol?_=14616968783849'
    local command_2 = "curl -k -b '/tmp/log/cmh/cookie.txt' "..url_2
    local f_2 = assert(io.popen(command_2, 'r'))
    local response_2 = assert(f_2:read('*a'))
    f_2:close(f_2)
    luup.log("Verisure status response: "..response_2)
    

    This returns the alarm status of Verisure system:

    [{"date":"Today 8:47 PM","notAllowedReason":"","name":"Samppa Turunen","changeAllowed":true,"id":1,"label":"Armed stay","type":"ARM_STATE","status":"armedhome"}]
    

    Now I need to parse the response string into a variable.

    Then I could make a device for it to be used as home / away switch.
    What would be the easiest example to start packaging the code into a device file for Vera? This would be my very first handmade device.. :-)

    Vera

  • Is HTTPS request from LUUP code possible?
    S samppa

    @hek Do you know who could know if saving the cookies is possible with https POST request in luup code?

    Vera

  • Requirements for controller integration/support for MySensors?
    S samppa

    @hek What are the requirements to get a controller fully supported by MySensors?
    I mean technically and API wise. My friend is producing the Cozify controller and planning to open APIs for custom sensor development like MySensors.

    Controllers

  • Is Vera still the best controller (to replace my failing Vera3)?
    S samppa

    Perhaps we could link to https://socialcompare.com/en/comparison/home-automation-controllers-under-400dollar-37r4y81h and add rows for MySensors compatibility..

    Vera

  • Is Vera still the best controller (to replace my failing Vera3)?
    S samppa

    Yes I saw the list and struggling to go through it one by one..
    It would be great to see the main differences and estimation of target audience as a summary table. Level of expertise needed, z-wave, zigbee support etc..

    Vera

  • Is Vera still the best controller (to replace my failing Vera3)?
    S samppa

    I have had Vera3 for a few years and after upgrade to UI7 from UI5 the problems started and the flash memory is degrading with bad blocks so that the unit is no longer stable or reliable.
    What is the best controller for MySensors or are VeraEdge or Vera Plus the best alternatives?
    I have somewhat complex rules and luup scripts with PLG to control things and I like the ability to tinker and code stuff to work together intelligently. And the active community support and developed apps/plugins are important factors.
    So who could suggest the best controller box for my needs?

    By the way, the MySensors site should have controller comparison table as welll as and pors/cons and suggestions.

    Vera

  • My Vera 3 (UI7) keeps on rebooting
    S samppa

    I had the same problem after updating to UI7 from UI5. Finally I was able to reset the box with this help with SSH (using putty on windows) : http://forum.micasaverde.com/index.php?topic=9949.0

    After reset I upgraded the firmware to latest one and then take the settings from saved backup.

    It kind of works now, but I am still struggling to get MySensors Plugin updated.

    Vera

  • Verisure home alarm status as home/away switch
    S samppa

    I am trying to get the status of my Verisure alarm system, but the API requires HTTPS login.
    The only two workaround methods I have figured out so far are:

    1. Monitor the "SmartPlug" that can be configured to turn on or off according to the alarm status
    2. Request the alarm status information for the web site with two HTTPS requests

    The option 2 would be nice, but I am stuck with the HTTPS requests from Vera3 scene LUUP code.
    Not sure if that is even possible. The status page requires first a login HTTPS request and the session tokens to be stored and another HTTPS request to retrieve the actual alarm status.

    Any ideas how to implement the HTTPS requests? Do I need to create a "device" and does that provide better access to SSL libraries like LuaSec? Would that help?

    My Project

  • Is HTTPS request from LUUP code possible?
    S samppa

    Does anyone know if I can make HTTPS request from luup code with cookie support?
    I would login to my pages on Verisure website and get the alarm status to be used in automation as home/away switch. I can do this successfully with two wget HTTPS calls: 1) login and 2) access status page with cookies that store the session authentication. But no luck so far with luup.

    So can that even be done with lua from a scene with luup code?

    Vera

  • Plotting graphs with plot.ly service with luup scene using REST API
    S samppa

    @korttoma The only difference I see is that you put the entire url with parameters in the first argument of the http.request call and "run=run" as the second (don't know why you have that?). I use the base url as the first argument and the field list as the second

     r, s = http.request(baseUrl, "field1=XX&field2=XX") 
    

    Hope that fixes the issue.
    Also You have to setup the "Channel" and "Plugin" in the website accordingly and name the fields there.

    My Project plot.ly graph luup plot

  • REQUEST: Anyone have a sketch for temp/humidity logging?
    S samppa

    I am logging temperatures from sensors in Vera scene once a minute with luup code that gets the sensor variables and makes http request to ThingSpeak website for generating graphs.
    What controller are you using? If you use Vera I might be able to help.

    Plot.ly is also another similar graphing service, but the free tier got new limitations for allowed data frequency.

    Development

  • Plotting graphs with plot.ly service with luup scene using REST API
    S samppa

    I converted my code to use ThingSpeak.
    It is even simpler to call since the formatting is done on the website. Here is how I use it:

    local url = "https://api.thingspeak.com/update?api_key=_YOUR_KEY_HERE_"
    result, status = http.request(url,'field1='..HotWaterTemp..'&field2='..HotWaterPump..'&field3='..HotWaterLimit..'&field4='..PumpTime)
    

    On the https://thingspeak.com website you just define the "channel" that receives all the data and copy the example "plugin" and modify it to render your graph.
    Quite easy. And free at least so far..

    My Project plot.ly graph luup plot

  • Plotting graphs with plot.ly service with luup scene using REST API
    S samppa

    It seems that plot.ly has new limitations to the free API in their price plan:

    • Only one free private graph
    • API rate limits: 50 per day or 30 per hour

    Then you have to pay 20 USD/month to get unlimited access.
    Damn. There goes the cheap solution.

    My Project plot.ly graph luup plot

  • req node id node not found
    S samppa

    Just to reply that I found the bug: ground wire broken, but not consistently so sometimes it got contact (when I measured it) and then not.

    This brings me to think is there any way on the Arduino to detect if something is not connected as it supposed to be? How could I make such extra self checking of the wires? Double wiring? ;-)

    Troubleshooting

  • Windows GUI/Controller for MySensors
    S samppa

    @tekka said:


    To update hit the update button or download here.


    Chrome blocks the download since it is "malicious".

    Controllers myscontroller mysbootloader

  • req node id node not found
    S samppa

    It all started when I was debugging reason for a Dallas sensor (in Nano node) not getting values (other attached sensors like DHT work ok). I checked the wires several times thoroughly and then I tried with another Dallas, but that did not help then I tried with another PIN and still no success. So I replaced the entire Nano and still the Dallas does not work and in addition now the serial monitor just keeps repeating:

      req node id
      send: 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,st=ok:
    

    I removed the node ans sensors from Vera config but still the Vera plugin does not find the sensors presented during inclusion.

    The node has capacitor for RF, I also cleared the EEPROM, and finally I now upgraded ide to 1.6 (used to be 1.05)
    Lib version 1.4.1. No Luck.

    Please help..

    Troubleshooting

  • Plotting graphs with plot.ly service with luup scene using REST API
    S samppa

    @korttoma

    Now plot.ly is back up again.
    Apparently they upgraded the infrastructure and broke something. Hopefully that does not happen too often..

    My Project plot.ly graph luup plot

  • Plotting graphs with plot.ly service with luup scene using REST API
    S samppa

    My graphs stopped as well. I have asked what is going on.. Let's see when it gets back up again..

    My Project plot.ly graph luup plot

  • How to get PLEG condition value from LUUP code? With luup.variable_get()?
    S samppa

    @BulldogLowell

    Actually it started to work after update to 5.37 version of PLEG where Richard made some bugfix for numeric conditions.
    Now the exported condition is shown correctly as a variable in the advanced tab.
    So case resolved. :-D

    Vera
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular