Navigation

    • Register
    • Login
    • Search
    • OpenHardware.io
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. carlyler
    3. Posts
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    Posts made by carlyler

    • RE: openHAB 2.0 binding

      @matt-shepherd What works for me :
      items - just used 1 channel, V_VAR1, but you could keep them separate

      String neoPixelRgb           "RGB LED string"                           (grpLighting)  { channel="mysensors:rgbLight:ethGateway:rgb01:var1" }
      Color neoPixelColor         "RGB LED string"            <colorwheel>    (grpLighting)
      

      rule

      rule "Set RGB value NeoPixelStrip"
      when
          Item neoPixelColor changed
      then
          val hsbValue = neoPixelColor.state as HSBType
      
          val brightness = hsbValue.brightness.intValue
          val redValue = ((((hsbValue.red.intValue * 255) / 100) * brightness) / 100)
          val grnValue = ((((hsbValue.green.intValue * 255) / 100) * brightness) / 100)
          val bluValue = ((((hsbValue.blue.intValue * 255) / 100) * brightness) / 100)
      
          val rgbHexString = String::format("%02X%02X%02X", redValue, grnValue, bluValue)
          sendCommand(neoPixelRgb, rgbHexString)
      end
      
      

      parsed in node

        if (message.type == V_VAR1)
        {
          // Write some debug info
          Serial.print(", New status, V_RGB: ");
          Serial.println(message.getString());
      
          // starting to process the hex code
          String hexstring = message.getString(); //here goes the hex color code coming from through MySensors (like FF9A00)
          long number = (long) strtol( &hexstring[0], NULL, 16);
          RGB_values[0] = number >> 16;
          RGB_values[1] = number >> 8 & 0xFF;
          RGB_values[2] = number & 0xFF;
      
          colorWipe(strip.Color(RGB_values[0], RGB_values[1], RGB_values[2]), 50);
        }
      
      posted in OpenHAB
      carlyler
      carlyler
    • RE: openHAB 2.0 binding

      I am trying to make use of the customSensor using org.openhab.binding.mysensors-2.1.0-SNAPSHOT.jar I see the node 12 var4 message arrive but it is not being assigned to my item; am I doing something wrong? I have tried both string and number item types.

      10:37:37.879 [DEBUG] [rsAbstractConnection$MySensorsReader] - 12;0;1;0;27;1023
      10:37:37.880 [DEBUG] [rs.internal.gateway.MySensorsGateway] - Node 12 found in gateway
      10:37:37.881 [DEBUG] [rs.internal.gateway.MySensorsGateway] - Child 0 found in node 12
      10:37:37.882 [DEBUG] [ensors.handler.MySensorsThingHandler] - Updating channel: var4(27) value to: 1023
      10:37:37.896 [DEBUG] [ensors.handler.MySensorsThingHandler] - Setting last update for node/child 12/0 to 2017-06-03T10:37:37.000-0400
      10:37:37.901 [DEBUG] [rsAbstractConnection$MySensorsReader] - 12;255;3;0;22;63464
      10:37:37.912 [INFO ] [marthome.event.ItemStateChangedEvent] - Sensor12LastUpdate changed from 2017-06-03T10:37:26.000-0400 to 2017-06-03T10:37:37.000-0400
      10:37:37.925 [INFO ] [marthome.event.ItemStateChangedEvent] - mySMsg01 changed from 1;4;1;0;1;64.2 to 12;0;1;0;27;1023
      10:37:37.935 [INFO ] [marthome.event.ItemStateChangedEvent] - mySMsg01 changed from 12;0;1;0;27;1023 to 12;255;3;0;22;63464
      10:37:41.974 [DEBUG] [rsAbstractConnection$MySensorsReader] - 2;0;1;0;17;544
      10:37:41.975 [DEBUG] [rs.internal.gateway.MySensorsGateway] - Node 2 found in gateway
      10:37:41.976 [DEBUG] [rs.internal.gateway.MySensorsGateway] - Child 0 found in node 2
      10:37:41.976 [DEBUG] [ensors.handler.MySensorsThingHandler] - Updating channel: watt(17) value to: 544
      10:37:41.984 [DEBUG] [ensors.handler.MySensorsThingHandler] - Setting last update for node/child 2/0 to 2017-06-03T10:37:41.000-0400
      10:37:41.995 [INFO ] [marthome.event.ItemStateChangedEvent] - watt01 changed from 547 to 544
      10:37:42.005 [DEBUG] [rsAbstractConnection$MySensorsReader] - 2;0;1;0;24;1138982
      10:37:42.006 [INFO ] [marthome.event.ItemStateChangedEvent] - Sensor02LastUpdate changed from 2017-06-03T10:37:27.000-0400 to 2017-06-03
      

      Things

      Bridge mysensors:bridge-eth:ethGatewayPi [ ipAddress="127.0.0.1", tcpPort=5003, sendDelay=200 ]
      {
         /** define things connected to that bridge here */
         humidity         hum01       [ nodeId="1", childId="0" ]
         temperature      temp01      [ nodeId="1", childId="1" ]
         humidity         hum02       [ nodeId="1", childId="2" ]
         temperature      temp02      [ nodeId="1", childId="3" ]
         humidity         hum03       [ nodeId="1", childId="4" ]
         temperature      temp03      [ nodeId="1", childId="5" ]
         power            power01     [ nodeId="2", childId="0" ]
         rgbLight         rgb02       [ nodeId="6", childId="0", requestAck=true ]
         light            relay01     [ nodeId="7", childId="0", requestAck=true ]
         motion           motion01    [ nodeId="8", childId="0", requestAck=true ]
         motion           motion02    [ nodeId="9", childId="0", requestAck=true ]
         light            relay02     [ nodeId="9", childId="1", requestAck=true ]
         cover            cover03     [ nodeId="10", childId="0", requestAck=true, smartSleep=true ]
         cover            cover02     [ nodeId="11", childId="0", requestAck=true, smartSleep=true ]
         customSensor     blind01     [ nodeId="12", childId="0", requestAck=true, smartSleep=true ]
         mySensorsMessage mySMsg01    [ nodeId="999", childId="999" ]
      }
      

      items:

      String blind1BatReading	    "Blind#1 Battery A/D Reading"  	<battery>			{ channel="mysensors:customSensor:ethGatewayPi:blind01:var4" }										
      DateTime Sensor12LastUpdate "Last seen Nd12 [%1$ta %1$tT]"       <clock>    	{ channel="mysensors:customSensor:ethGatewayPi:blind01:lastupdate" }
      

      edit 6/7: I stand corrected, the variables are being updated. I was fooled by the log. For some reason the log does not show the change the way it did it binding 2.0.0. I placed debug messages in my rules and they're updating.

      posted in OpenHAB
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      @Teknor I tend to agree something is wrong, but I think it really on depends how many nodes and how often you're sending data.
      rpi3 + GPIO nrf24l01 + openhab2 + 8 nodes + packet received, on average 1 / 5s :

      top - 06:29:37 up 2 days, 22:33,  2 users,  load average: 0.26, 0.24, 0.19
      KiB Mem:    947732 total,   903420 used,    44312 free,   175364 buffers
      KiB Swap:   102396 total,     4496 used,    97900 free.   391360 cached Mem
      
        PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                               
        681 root      20   0  208840  56532  23684 S   8.9  6.0 214:23.60 Xorg                                                                  
        527 root      20   0   39448  21532  11264 S   4.3  2.3  69:34.28 vncserver-x11-c                                                       
       1154 pi        20   0   50548  17628  12196 S   3.0  1.9  64:05.96 lxterminal                                                            
      30426 openhab   20   0  441764 197592  14960 S   1.6 20.8 284:18.70 java                                                                  
       2467 root      20   0   20024   2456   2300 S   1.3  0.3  62:55.17 mysgw                                                                 
      25634 root      20   0       0      0      0 S   1.0  0.0   0:00.21 kworker/u8:0                                                          
        688 root      20   0   13720   9432   8828 S   0.7  1.0   2:04.96 vncagent                                                              
      25855 pi        20   0    5232   2584   2140 R   0.7  0.3   0:00.49 top                                                                   
          7 root      20   0       0      0      0 S   0.3  0.0   9:15.35 rcu_sched                                                             
         78 root     -51   0       0      0      0 S   0.3  0.0   5:16.50 irq/92-mmc1                                                           
        967 pi        20   0   95656  17716  12028 S   0.3  1.9   6:41.87 lxpanel                                                               
          1 root      20   0   24620   4688   2716 S   0.0  0.5   0:13.08 systemd                                                               
          2 root      20   0       0      0      0 S   0.0  0.0   0:00.27 kthreadd                                                              
      
      posted in Announcements
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      @Oli luizrocha's configuration seems interesting, but just in case your still wanting the serial, from above, has worked for me in the past, but I have since switched to OH2:

      @ysinh said:

      A tiny hint for the users of domoticz :
      ./configure --my-gateway=serial --my-serial-is-pty --my-serial-pty=/dev/ttyUSB20
      make
      sudo ./examples_linux/mysGateway -d

      🙂 i hope this helps
      then in the hardware setup
      MySensors Gateway USB
      serial port: /dev/ttyUSB20

      posted in Announcements
      carlyler
      carlyler
    • RE: MySensors Ethernet Gateway goes to OFFLINE state

      @jogant Thank you. I did not know about the binding restart so I will look into that.

      posted in OpenHAB
      carlyler
      carlyler
    • RE: MySensors Ethernet Gateway goes to OFFLINE state

      @TimO Good news! I finally got it to work; I have been using the dev, 2.1.0, and decided to try master, 2.0.0 and it came right up! I did notice one thing though that you may be interested in: if I start the ethGateway after OH2 is up, or turn it off and back on, the binding does not reconnect. Not sure if there is anything you can do about that.
      One other change to mention (before changing to v2.0.0): I found a note from hek about the node id of gateway local sensors will always be 0; I changed that in my things file and in my sketch.

      16:34:59.286 [DEBUG] [rs.internal.protocol.MySensorsReader] - 0;1;1;0;0;12.5
      16:34:59.291 [DEBUG] [ternal.handler.MySensorsThingHandler] - Setting last update for node 0 to 2016-12-10T16:34:59.289-0500
      16:34:59.300 [DEBUG] [ternal.handler.MySensorsThingHandler] - Setting last update for node 0 to 2016-12-10T16:34:59.297-0500
      16:34:59.333 [INFO ] [marthome.event.ItemStateChangedEvent] - bTemp changed from 12.8 to 12.5
      16:34:59.354 [INFO ] [marthome.event.ItemStateChangedEvent] - bTempF changed from 55.04 to 54.50
      16:34:59.365 [INFO ] [marthome.event.ItemStateChangedEvent] - bTempC_F changed from 12.8 °C / 55.0 °F to 12.5 °C / 54.5 °F
      16:34:59.490 [DEBUG] [al.protocol.ip.MySensorsIpConnection] - Bridge is connected, connection skipped
      16:34:59.583 [DEBUG] [rs.internal.protocol.MySensorsReader] - 0;0;1;0;1;34.1
      16:34:59.593 [INFO ] [marthome.event.ItemStateChangedEvent] - bHum changed from 34.2 to 34.1
      

      @hek I could be wrong, or maybe something has changed configuration wise but as you can see from above posts, dev branch v2.1.0, the radioless ethernet (ESP8266) gateway with local temp & hum sensors was not sending local sensor data. When I switched back to master v2.0.0 it started sending.

      posted in OpenHAB
      carlyler
      carlyler
    • RE: MySensors Ethernet Gateway goes to OFFLINE state

      @TimO DHCP: yes, but it is actually static by way of reserved addresses via MAC in the router.
      IP: same
      ping: yes, works
      telnet, yes, all I see is:

      0;255;3;0;14;Gateway startup complete.
      

      Serial is OK? I do not see the send of the Temp and hum; it is printing it because there is code to do that, but I am expecting the MySensors send command; right? My thought was it is not transmitting them for some reason. This is an area I am not confident about and have yet to find a good explanation of it: how a GW handles local sensors. Thoughts?

      posted in OpenHAB
      carlyler
      carlyler
    • RE: MySensors Ethernet Gateway goes to OFFLINE state

      @TimO thanks for the reply. I changed mysensors:bridge-eth:gateway to mysensors:bridge-eth:ethGateway in things and items, restarted OH2, reset ESP8266, several times, but no luck. If I read this right the GW is not trying to do much, ie get node id, present sensor, send data, etc. Any idea?

      GW serial:

      0;255;3;0;9;MCO:BGN:STP
      0;255;3;0;9;MCO:SLP:MS=2000,SMS=0,I1=255,M1=255,I2=255,M2=255
      0;255;3;0;9;MCO:SLP:WUP=-2
      0;255;3;0;9;MCO:BGN:INIT OK,TSP=NA
      Getting temperature
      T: 20.00
      H: 34.70
      Getting temperature
      T: 20.10
      H: 33.90
      

      I am trying to set node id in sketch:

      // Set this to the pin you connected the DHT's data pin to
      #define DHT_DATA_PIN 2
      
      // Enable debug prints to serial monitor
      #define MY_DEBUG
      #define MY_GATEWAY_ESP8266
      // ethernet settings
      #define MY_ESP8266_SSID "xxxxxx"
      #define MY_ESP8266_PASSWORD "xxxxxxxxxx"
      
      // Enable UDP communication
      //#define MY_USE_UDP
      
      // Set the hostname for the WiFi Client. This is the hostname
      // it will pass to the DHCP server if not static.
      #define MY_ESP8266_HOSTNAME "HuzzahGateway"
      
      // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
      //#define MY_IP_ADDRESS 192,168,213,113
      
      // If using static ip you need to define Gateway and Subnet address as well
      //#define MY_IP_GATEWAY_ADDRESS 192,168,213,1
      //#define MY_IP_SUBNET_ADDRESS 255,255,255,0
      
      // The port to keep open on node server mode
      #define MY_PORT 5003
      // How many clients should be able to connect to this gateway (default 1)
      #define MY_GATEWAY_MAX_CLIENTS 1
      
      // Controller ip address. Enables client mode (default is "server" mode).
      // Also enable this if MY_USE_UDP is used and you want sensor data sent somewhere.
      //#define MY_CONTROLLER_IP_ADDRESS 192,168,213,116
      
      // Flash leds on rx/tx/err
      // Led pins used if blinking feature is enabled above
      #define MY_DEFAULT_ERR_LED_PIN 16  // Error led pin
      #define MY_DEFAULT_RX_LED_PIN  16  // Receive led pin
      #define MY_DEFAULT_TX_LED_PIN  16  // the PCB, on board LED
      #define MY_NODE_ID 3
      
      #include <SPI.h>
      #include <ESP8266WiFi.h>
      #include <MySensors.h>
      #include <DHT.h>
      
      
      posted in OpenHAB
      carlyler
      carlyler
    • RE: MySensors Ethernet Gateway goes to OFFLINE state

      @TimO brief setup: controller and serial gateway on raspberryPi running OH2, serial working OK. Trying to add ESP8266 Huzzah gateway with only local sensor, DHT22 - no radio. It seems I have a similar situation as others, but before I post all my setup and logs a question for you: when using both a serial gateway and ethernet gateway can they be named the same, "gateway", in things file? What bothers me is the "channel" in the items file ends up looking like it is from the same source or am I missing something?

      Things file:

      Bridge mysensors:bridge-ser:gateway [ serialPort="/dev/ttyMySensorsGateway", sendDelay=200 ]
      {
         /** define things connected to that bridge here */
         humidity         hum01   [ nodeId="1", childId="0" ]
         temperature      temp01  [ nodeId="1", childId="1" ]
         humidity         hum02   [ nodeId="1", childId="2" ]
         temperature      temp02  [ nodeId="1", childId="3" ]
         humidity         hum03   [ nodeId="1", childId="4" ]
         temperature      temp03  [ nodeId="1", childId="5" ]
         power            power01 [ nodeId="2", childId="0" ]
         mySensorsMessage mySMsg01    [ nodeId="999", childId="999" ]
      }
      Bridge mysensors:bridge-eth:gateway [ ipAddress="192.168.1.113", tcpPort=5003, sendDelay=200 ]
      {
         /** define things connected to that bridge here */
         humidity         hum04   [ nodeId="3", childId="0" ]
         temperature      temp04  [ nodeId="3", childId="1" ]
      }
      

      Items file snippet (hum02/temp02 on serial GW and hum04/temp04 on eth GW)

      Number mHum                 "Master Humidity [%.0f %%]"             <humidity>      (grpChart,grpTemperatures)  { channel="mysensors:humidity:gateway:hum02:hum" }
      Number mTemp                "Master Temperature"                    <temperature>                               { channel="mysensors:temperature:gateway:temp02:temp" }
      Number bHum                 "Bean's Humidity [%.0f %%]"             <humidity>      (grpChart,grpTemperatures)  { channel="mysensors:humidity:gateway:hum04:hum" }
      Number bTemp                "Bean's Temperature"                    <temperature>                               { channel="mysensors:temperature:gateway:temp04:temp" }
      
      
      posted in OpenHAB
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      @ben999 if you have not already, read through the MySensors OH2 thread. I noticed a recent post by @TimO that talks about setting some permissions and that might be the issue. Otherwise, the manual install is not bad as he gives you step-by-step; I am a new to all this and managed to get it to work...

      posted in Announcements
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      @ben999 try again, because it works great. I assume by online install you mean apt-get; I too had trouble when trying this. However, I tried again following @TimO instructions here:
      wiki, then everything came up nicely. I feel it is some permission issue that I have not tried to figure out yet.

      posted in Announcements
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      @dopeeye I had this issue and unfortunately changed several things at once and got rid of it. However, one thing I noticed was I had different versions of mySensors in my library directory since I downloaded the examples package. Therefore the sensor was likely compiling on a different version than the Gateway. You might want to check that.

      If you could post more of your logs (sensor and gateway) it might help.

      posted in Announcements
      carlyler
      carlyler
    • RE: openHAB 2.0 binding

      @andreacioni after reading this thread I realized you have done a lot of work here as well, thank you.

      I am running:
      pi@raspberrypi:~ $ java -version
      java version "1.8.0_65"
      Java(TM) SE Runtime Environment (build 1.8.0_65-b17)
      Java HotSpot(TM) Client VM (build 25.65-b01, mixed mode)
      pi@raspberrypi:~ $

      posted in OpenHAB
      carlyler
      carlyler
    • RE: openHAB 2.0 binding

      OK, I think I got past that, I reinstalled everything and cleaned up my MySensors libraries.There is a chance I was pulling from different version when compiling the different examples from different packages.

      But, I noticed this exception at OH2 startup:

      06:29:26.838 [INFO ] [me.event.ThingStatusInfoChangedEvent] - 'mysensors:bridge-ser:gateway' changed from UNINITIALIZED to INITIALIZING
      06:29:26.924 [DEBUG] [ternal.handler.MySensorsThingHandler] - Configuration: node 1, chiledId: 1, revertState: false
      06:29:26.924 [DEBUG] [ternal.handler.MySensorsThingHandler] - Configuration: node 1, chiledId: 0, revertState: false
      06:29:26.932 [DEBUG] [ternal.handler.MySensorsThingHandler] - Configuration: node 2, chiledId: 0, revertState: false
      06:29:26.951 [INFO ] [me.event.ThingStatusInfoChangedEvent] - 'mysensors:humidity:gateway:hum01' changed from UNINITIALIZED to INITIALIZING
      06:29:26.946 [DEBUG] [col.serial.MySensorsSerialConnection] - Set skip check on startup to: false
      06:29:26.956 [DEBUG] [col.serial.MySensorsSerialConnection] - Enabling connection watchdog
      06:29:26.964 [INFO ] [me.event.ThingStatusInfoChangedEvent] - 'mysensors:temperature:gateway:temp01' changed from UNINITIALIZED to INITIALIZING
      06:29:26.969 [INFO ] [me.event.ThingStatusInfoChangedEvent] - 'mysensors:power:gateway:power01' changed from UNINITIALIZED to INITIALIZING
      06:29:26.993 [DEBUG] [ternal.factory.MySensorsCacheFactory] - Cache file: given_ids.cached exist.
      06:29:27.001 [DEBUG] [col.serial.MySensorsSerialConnection] - Connecting to /dev/pts/3 [baudRate:115200]
      06:29:27.032 [DEBUG] [ternal.factory.MySensorsCacheFactory] - Cache (given_ids) content: []
      06:29:27.067 [INFO ] [me.event.ThingStatusInfoChangedEvent] - 'mysensors:bridge-ser:gateway' changed from INITIALIZING to UNINITIALIZED (HANDLER_INITIALIZING_ERROR)
      06:29:27.041 [ERROR] [ome.core.thing.internal.ThingManager] - Exception occured while initializing handler of thing 'mysensors:bridge-ser:gateway': java.lang.UnsupportedOperationException
      java.util.concurrent.ExecutionException: java.lang.UnsupportedOperationException
      	at java.util.concurrent.FutureTask.report(FutureTask.java:122)[:1.8.0_65]
      	at java.util.concurrent.FutureTask.get(FutureTask.java:206)[:1.8.0_65]
      	at org.eclipse.smarthome.core.common.SafeMethodCaller.callAsynchronous(SafeMethodCaller.java:186)[99:org.eclipse.smarthome.core:0.9.0.201610220816]
      	at org.eclipse.smarthome.core.common.SafeMethodCaller.call(SafeMethodCaller.java:79)[99:org.eclipse.smarthome.core:0.9.0.201610220816]
      	at org.eclipse.smarthome.core.common.SafeMethodCaller.call(SafeMethodCaller.java:63)[99:org.eclipse.smarthome.core:0.9.0.201610220816]
      	at org.eclipse.smarthome.core.thing.internal.ThingManager$9.run(ThingManager.java:755)[106:org.eclipse.smarthome.core.thing:0.9.0.201610220816]
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_65]
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_65]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)[:1.8.0_65]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)[:1.8.0_65]
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_65]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_65]
      	at java.lang.Thread.run(Thread.java:745)[:1.8.0_65]
      Caused by: java.lang.UnsupportedOperationException
      	at java.util.AbstractList.add(AbstractList.java:148)[:1.8.0_65]
      	at java.util.AbstractList.add(AbstractList.java:108)[:1.8.0_65]
      	at org.openhab.binding.mysensors.internal.handler.MySensorsBridgeHandler.loadCacheFile(MySensorsBridgeHandler.java:176)[10:org.openhab.binding.mysensors:2.0.0.201610021604]
      	at org.openhab.binding.mysensors.internal.handler.MySensorsBridgeHandler.initialize(MySensorsBridgeHandler.java:90)[10:org.openhab.binding.mysensors:2.0.0.201610021604]
      	at org.eclipse.smarthome.core.thing.internal.ThingManager$9$1.call(ThingManager.java:758)[106:org.eclipse.smarthome.core.thing:0.9.0.201610220816]
      	at org.eclipse.smarthome.core.thing.internal.ThingManager$9$1.call(ThingManager.java:1)[106:org.eclipse.smarthome.core.thing:0.9.0.201610220816]
      	at org.eclipse.smarthome.core.common.SafeMethodCaller$CallableWrapper.call(SafeMethodCaller.java:177)[99:org.eclipse.smarthome.core:0.9.0.201610220816]
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_65]
      	... 3 more
      06:29:27.198 [DEBUG] [col.serial.MySensorsSerialConnection] - Final port list: /dev/pts/3
      06:29:27.232 [DEBUG] [col.serial.MySensorsSerialConnection] - Successfully connected to serial port.
      06:29:27.234 [DEBUG] [col.serial.MySensorsSerialConnection] - Waiting 3 seconds to allow correct reset trigger on serial connection opening
      06:29:29.428 [INFO ] [basic.internal.servlet.WebAppServlet] - Started Basic UI at /basicui/app
      06:29:29.897 [INFO ] [assic.internal.servlet.WebAppServlet] - Started Classic UI at /classicui/app
      06:29:30.262 [DEBUG] [rs.internal.protocol.MySensorsReader] - ;255;3;0;14;Gateway startup complete.
      06:29:30.274 [ERROR] [rs.internal.protocol.MySensorsReader] - (java.lang.NumberFormatException: For input string: "") on reading from serial port, message: class org.openhab.binding.mysensors.internal.protocol.serial.MySensorsSerialReader
      06:29:30.283 [DEBUG] [rs.internal.protocol.MySensorsReader] - 0;255;0;0;18;2.0.1-beta
      

      Things still seem to work, but do I have something wrong?

      posted in OpenHAB
      carlyler
      carlyler
    • RE: 💬 Building a Raspberry Pi Gateway

      Appears things are changing, please update wiki:
      Warning: --my-radio is deprecated, please use --my-transport

      posted in Announcements
      carlyler
      carlyler
    • RE: openHAB 2.0 binding

      Having a couple issues:

      1. while adding 2nd node (tried power and temp/hum) OH2 would not assign node ID.
      2. assigned node ID manually (ID=2) and OH2 recognized power node but will not respond to V_VAR1 request.
      16:23:58.850 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;1;1;0;0;20.4
      16:23:58.874 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.3
      16:24:01.910 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:09.293 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.5
      16:24:11.911 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:11.942 [DEBUG] [rs.internal.protocol.MySensorsReader] - 2;0;2;0;24;
      16:24:19.736 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.7
      16:24:21.912 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:26.987 [DEBUG] [rs.internal.protocol.MySensorsReader] - 2;0;2;0;24;
      16:24:30.177 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.6
      16:24:31.913 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:40.604 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.5
      16:24:41.914 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:42.044 [DEBUG] [rs.internal.protocol.MySensorsReader] - 2;0;2;0;24;
      16:24:51.916 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:24:57.102 [DEBUG] [rs.internal.protocol.MySensorsReader] - 2;0;2;0;24;
      16:25:01.917 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:25:11.919 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:25:12.145 [DEBUG] [rs.internal.protocol.MySensorsReader] - 2;0;2;0;24;
      16:25:21.921 [DEBUG] [col.serial.MySensorsSerialConnection] - Bridge is connected, connection skipped
      16:25:22.304 [DEBUG] [rs.internal.protocol.MySensorsReader] - 1;0;1;0;1;47.6
      

      Things:

      Bridge mysensors:bridge-ser:gateway [ serialPort="/dev/pts/2", sendDelay=200 ] {
         /** define things connected to that bridge here */
         humidity        hum01   [ nodeId="1", childId="0" ]
         temperature     temp01  [ nodeId="1", childId="1" ]
         power           power01 [ nodeId="2", childId="0" ]
      }
      

      Items:

      Number hum01   "Humidity"              <humidity> { channel="mysensors:humidity:gateway:hum01:hum" }
      Number temp01  "Temperature"           <temperature> { channel="mysensors:temperature:gateway:temp01:temp" }
      Number temp01F "Temperature [%.1f °F]" <temperature>
      DateTime Sensor01LastUpdate "Last seen [%1$ta %1$tR]" <clock>
      DateTime Sensor02LastUpdate "Last seen [%1$ta %1$tR]" <clock>
      Number watt01  "Current Demand [%.0f Watt]" { channel="mysensors:power:gateway:power01:watt" }
      Number kwh01  "Daily Use [%.1f kWh]"        { channel="mysensors:power:gateway:power01:kwh" }
      
      

      What am i doing wrong?

      posted in OpenHAB
      carlyler
      carlyler
    • RE: openHAB 2.0 binding

      @TimO: Thanks to you this weekend, while kids slept or napped, I managed to setup RPi gateway/controller with NRF24 and OH2.
      Following the OH2 install instructions caused me some trouble, not sure why, but following your install instructions it came right up.
      Thank you for the time and effort here.

      posted in OpenHAB
      carlyler
      carlyler
    • RE: [SOLVED] Wifi gateway crashing ~20min

      Hi sundberg84. Thank you for the reply.
      Currently I just have the 1 ESP8266.
      I think I found the issue. There is a a lot written online about the error and what I got from it was the ESP8266 is being asked to do more than it has time to do. Given that I was only transmitting every 10sec I started looking at what might be tying things up. From the MySensors ESP8266 example I had, naively, changed the sleeps to delays, since I did not want it sleeping. I realized that might be killing the ESP8266. So I changed the loop function to run freely and the code to be executed on interval. I have not seen the error since.

      posted in Troubleshooting
      carlyler
      carlyler
    • RE: Add demand variable to electricity pulse counter

      Hi AWI.
      You have the idea. They watch in 30min intervals the amount of power you consume or average kW. Then they charge you for the largest interval they saw in the billing cycle. I think of as charging and discharging a cap; in code I used a fixed length FIFO and subtract the ends, which are delta 30min.

      I agree, and you likely read how I handled it, would you suggest a different approach? Being new it just took me awhile to realize that I could present a virtual sensor.

      posted in Domoticz
      carlyler
      carlyler
    • RE: Add demand variable to electricity pulse counter

      My thought process and findings:
      I found the custom values, V_VAR[1:5], but I also found a post that says these are not accessible in Domoticz. So this makes me wonder why, and what good are they? Only for developers I surmise.
      I wondered who stipulates that S_POWER will only report V_WATT and V_KWH? Then I realized that probably a lot of changes need to occur on both GW and Cntlr to support another var.
      I found this Domoticz post from a link in MySensors forum, https://www.domoticz.com/forum/viewtopic.php?t=6517, where he suggests just sending up another sensor, a virtual sensor if you will. I tried it and it works great!

       // Register this device as power sensor
         present(CHILD_ID_HEM, S_POWER);
         present(CHILD_ID_HEM2, S_POWER);
      

      0_1474284754959_DomoticzUtility.jpg

      I still feel 1 or custom variables in each sensor type, that you can have access to in the cntlr, might come in handy.

      posted in Domoticz
      carlyler
      carlyler
    • [SOLVED] Wifi gateway crashing ~20min

      Re: WifiGateway crashes after 1 or 2 days

      Similar issue: ESP8266 GW with local pulse counter sensor, no radio, no other children, development branch, v2.0.1-beta. After about 20min Domoticz shows:
      2016-09-18 12:24:49.422 (ESP) Usage (Usage)
      2016-09-18 12:24:49.443 (ESP) General/kWh (Meter)
      2016-09-18 12:24:59.387 (ESP) General/kWh (Meter)
      2016-09-18 12:24:59.454 (ESP) Usage (Usage)
      2016-09-18 12:24:59.479 (ESP) General/kWh (Meter)
      2016-09-18 12:25:38.449 Error: MySensors: The semaphore timeout period has expired
      2016-09-18 12:25:38.449 TCP: Reconnecting in 30 seconds...
      2016-09-18 12:26:08.477 TCP: Reconnecting...

      Watching the serial, the error builds up over time and then boom! See attached file 0_1474217602140_LmacRxBlk Issue.txt.
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      LmacRxBlk:1
      0;255;3;0;9;No free slot available

      Recovers after about 10min, maybe a timeout or cleanup of some sort?
      0;255;3;0;9;No free slot available
      Watt:727
      Interval:4950348
      kWH: 9.84
      0;255;3;0;9;Client 0 disconnected
      Watt:714
      Interval:5035182
      kWH: 9.84
      0;255;3;0;9;Client 0 connected
      Watt:721
      Interval:4988227
      kWH: 9.84
      0;255;3;0;9;Client 0: 0;0;3;0;2;
      Watt:710
      Interval:5068874
      kWH: 9.84

      I tend to agree with the suggestion in the other post about using up the sockets, but I need help with what to do about it.

      Any ideas, please?

      posted in Troubleshooting
      carlyler
      carlyler
    • RE: ESP8266 Gateway with sensor attached

      Hi fahrettine. Good to hear I am not alone, however I felt kind of lonely in here so, even though I really liked the looks of MyNodes, I did a quick popularity survey based on posts and tried Domoticz and my gateway and sensors came right up! I noticed derwish is working on a new project so I am not sure sure of the status of .NET. Good luck, and please do post if you figure something out.

      posted in MyNodes.NET
      carlyler
      carlyler
    • Add demand variable to electricity pulse counter

      Great work here MySensors team and thank you for sharing. I am just getting started.
      After some struggling with my first controller choice I tried Domoticz, with the development branch, and sensors attached to the ESP8266 GW came right up! However, I immediately need help. I cannot find anything that explains how to add a variable to a sensor and get it recognized in the controller. Can someone please share an example? Others have asked, some have come up with a work around and some have went unanswered. I am not deterred by difficulty, but I need at least an outline to begin the journey.
      Why am I trying to do this: Our electric plan has a demand component so it is very handy to see and track that value. Obviously, the pulse rate, or "interval" in the MySensor example, is the demand I just need to get that displayed in the controller.

      edit: sorry, after reading my post and looking at some old code I realized your doing everything and Watt is the instantaneous demand, however what I am needing is the power company's demand, which is calculated over a 30min interval. Since I have Watts, I have 2 choices: 1) record that in the sensor and send it up, or 2) record it in the controller, then that becomes more of a Domoticz question, I guess. Personally I like 1, but could be persuaded.

      Comments/suggestions?

      posted in Domoticz
      carlyler
      carlyler
    • RE: ESP8266 Gateway with sensor attached

      Found this:https://github.com/mysensors/MySensors/pull/532
      So, tried development branch.
      And now gateway is no longer discovered...

      Where is switches from not responding to failed write was a gateway reboot.

      Hosting environment: Production
      Now listening on: http://localhost:1312
      Application started. Press Ctrl+C to shut down.
      9/17/2016 6:06:59 AM: SYSTEM: Connecting to database...
      9/17/2016 6:06:59 AM: SYSTEM: Database connected.
      9/17/2016 6:07:07 AM: SYSTEM: Connecting to gateway...
      9/17/2016 6:07:07 AM: GATEWAY: Trying to connect...
      9/17/2016 6:07:07 AM: GATEWAY: Connected to 192.168.213.113:5003
      9/17/2016 6:07:07 AM: GATEWAY: Trying to communicate...
      9/17/2016 6:07:12 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:17 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:22 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:27 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:32 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:35 AM: GATEWAY: Failed to write data. Port is not connected.
      9/17/2016 6:07:36 AM: GATEWAY: Failed to write data. Port is not connected.
      9/17/2016 6:07:37 AM: GATEWAY: Gateway is not responding.
      9/17/2016 6:07:37 AM: GATEWAY: Failed to write data. Port is not connected.
      9/17/2016 6:07:38 AM: GATEWAY: Failed to write data. Port is not connected.
      9

      henrikekblad created this issue in mysensors/MySensors

      closed Present locally attached sensors and node when missing radio #532

      posted in MyNodes.NET
      carlyler
      carlyler
    • ESP8266 Gateway with sensor attached

      Thanks for the great work on MyNodes.

      I have an ESP8266 (Adafruit Huzzah) and I have attached, to the gateway IO, a DHT22, temperature and humidity sensor. MyNodes detects the gateway but the sensors do not show up, that I see. I read in the docs that it should show up in the upper left hand corner, but I see nothing in the window. Is there a trick to make this work or am I missing something?

      posted in MyNodes.NET
      carlyler
      carlyler