UI5 Mysensors library 2.0 gateway issues



  • I'm having issues with my new gateway.

    I recently updated my gateway node with library version 2.0 and was successful uploading. However, it doesn't look that the device in ui5 is updating. it still shows version 1.5.1

    also trying to include my new DHT11/motion node times out

    0_1469389500544_1.png
    0_1469389507960_2.png


  • Contest Winner

    @rchamp i'm not sure about the DHT's inclucion but you're right about the wrong library version.

    This version is NOT updated. If i trace down the debug i notice that the version ID string is not sent to the GW.
    Well at least not correct

    0;255;3;0;9;Starting gateway (RNNGAS, 2.0.0)
    0;255;3;0;9;TSM:INIT
    0;255;3;0;9;TSM:RADIO:OK
    0;255;3;0;9;TSM:GW MODE
    0;255;3;0;9;TSM:READY
    0;255;3;0;14;Gateway startup complete.
    0;255;0;0;18;2.0.0
    0;255;3;0;9;No registration required
    0;255;3;0;9;Init complete, id=0, parent=0, distance=0, registration=1
    

    This can be the lirbrary version number but is has 18 as internal message ID (I_HEARTBEAT)
    0;255;0;0;18;2.0.0
    While i would expect 2 (I_VERSION) so this message
    0;255;0;0;2;2.0.0

    @hek or @tekka can you confirm this?


  • Admin


  • Plugin Developer

    @BartE said:

    0;255;0;0;18;2.0.0

    This is a presentation message not an internal message. It's presenting the node (gateway) as a repeater, payload is library version.


  • Admin

    Yes, of course @martinhjelmare , you're right. It's this that kicks in:
    https://github.com/mysensors/MySensors/blob/934ccf30b205afad2086c908a367c4205ce580cd/core/MySensorsCore.cpp#L285

    Hmm.. Wonder why the Vera plugin isn't sending I_VERSION like it should then...


  • Contest Winner

    @hek andf @martinhjelmare i did some debugging this evening and came to the following findings

    My previous comment on start-up behavior was based on a stand alone GW (so disconnected from the Vera Controller)
    And i found out that the Library version is NOT pushed by the gateway but requested by the controller on plugin startup.

    And this part (on GW side is working) --> Sending "0;0;0;3;0;2;Get Version" to the GW is being answered with "0;255;3;0;2;2.0.0"

    So it must be the Vera plugin and then i found this line in my Vera box

    02      07/30/16 23:23:43.694   luup_log:64: Arduino: Incoming internal command '0;255;3;0;2;2.0.0' discarded for child: nil <0x6c14>
    

    So the MySensors v2.0.0 GW responses with alt-id 0;255 i.s.o 0;0
    By updating this line https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L370 by... auhm what is already in the current git version it works.

    So the final conclusion: just update the Vera plugin with the development branch and it works...



  • 👍

    Note. i left the plugin in place, and was able to enroll the node after some time.

    I have a feeling it just took Vera / plugin longer than I expected to detect the USB serial connection to the GW.

    node ID's seem to come in fine and libversion displays as 2.0.0 for the node. the 2 nodes (+ the updated GW) all appear to be running stable. if i run into another issue i will go for the development branch for the plugin



  • Im on UI7 and have the same issue, on the github development all files are many many months old, the should be newer than like 8 months???

    Regards,
    Jan


  • Contest Winner

    @stofakiller no the 8 month old files where OK for me (UI5)



  • Hi, I have the same issue. I installed the plugin and serial Gateway with no apparent issues, but can't add any sensors. I have triple-checked the wiring on the sensors and gateway with no success. One thing I have notice some of the Arduino LUUP Files on Vera display the following message when you open/view them.

    This page contains the following errors:

    error on line 1 at column 1: Document is empty
    Below is a rendering of the page up to the first error.



  • @BartE
    Hi, my plugin still shows version 1.5 even though I am using Version 2.0, I have not been able to include a single sensor. I have created 3 of them and not one can be found by the Plugin after the Inclusion button is pressed, any input would be greatly appreciated.


  • Admin

    The vera plugin still has version 1.5. It does not correlate to MySensors Arduino library versions.

    https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L20

    Are you on UI7 or UI5?

    When pressing inclusion mode button, does anything happen in the UI? (the text changes in the device to "found devices...")



  • hi, I am using UI5. After pressing the Start button it indicates that "0 devices found"


  • Admin

    Ok, so at least you have a contact with the gateway.

    After starting inclusion mode, do you restart the wireless node? It usually only sends its presentation messages during startup.



  • Yes, I start by having the sensor unplugged, that right after the Start button is pressed I plug in the sensor. One thing I noticed though, is that if I go to the LUUP files and try to "view" them, som of them display the folling message:

    This page contains the following errors:

    error on line 1 at column 1: Document is empty
    Below is a rendering of the page up to the first error.

    but if I download the same LUUP file and open it in Notepad the file is there


  • Admin

    Just to verify. You mean that you plug in the wireless sensor (with a radio)? Not the gateway?

    If so, you should have a look in the serial log of the gateway (Serial Monitor in Arduino IDE) while it is connected to your computer. Restart the (wireless) node an capture the log.



  • yes the wireless sensor with radio, not the Gateway. The gateway is plugged in on the Vera's USB port. Ok will do.
    Thanks



  • @hek ok the serial monitor comes up blank, with this in the upper left corner:

    "1Öyô¹¹q0"

    nothing happens after the wireless sensor is powered.....


  • Admin

    Did you set the correct baudrate?

    https://www.mysensors.org/build/debug



  • after switching to 115200 baud, the following poped up:

    0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
    0;255;3;0;9;TSM:INIT
    0;255;3;0;9;TSM:RADIO:OK
    0;255;3;0;9;TSM:GW MODE
    0;255;3;0;9;TSM:READY
    0;255;3;0;14;Gateway startup complete.
    0;255;0;0;18;2.0.0
    0;255;3;0;9;No registration required
    0;255;3;0;9;Init complete, id=0, parent=0, distance=0, registration=1

    no changed occurred when wireless sensor was re-started


  • Admin

    Ok, so your communication is not working.



  • should I wire up a new radio, should I wire up a complete gateway with radio (or both)?


  • Admin

    You should probably look at the nodes log.



  • @hek ok, I plugged in the Motion Sensor to check the Serial log and nothing came up. I opened the sketch on wordpad and noticed that there is no entry on Baud rate whatsoever (I no nothing about code so I don't know if that means anything).

    in regards to my other Sensor which is a Temp/Humidity Sensor, the sketch is not on my Library it was not included on the downloaded Zip file, so I downloaded it from here:

    https://www.mysensors.org/build/humidity

    but the downloaded copy does not have any entry for the radio and the baud rate is set 9600 so that's why the Gateway cant communicate with them,,I think.


  • Admin

    The baud rate has nothing to do with the radio communication. It's only used for the serial communication. That is debug prints or communication with controller.

    I don't understand what you mean by "the downloaded copy does not have any entry for the radio".



  • include "DHT.h"

    DHT dht;

    void setup()
    {
    Serial.begin(9600);
    Serial.println();
    Serial.println("Status\tHumidity (%)\tTemperature (C)\t(F)");

    dht.setup(2); // data pin 2
    }

    void loop()
    {
    delay(dht.getMinimumSamplingPeriod());

    float humidity = dht.getHumidity();
    float temperature = dht.getTemperature();

    Serial.print(dht.getStatusString());
    Serial.print("\t");
    Serial.print(humidity, 1);
    Serial.print("\t\t");
    Serial.print(temperature, 1);
    Serial.print("\t\t");
    Serial.println(dht.toFahrenheit(temperature), 1);
    }


  • Admin

    wot? That isn't the example you linked above.



  • Example
    "This example uses the external DTH library found here. Please install it and restart the Arduino IDE before trying to compile."

    if you click the "here", that's what downloads


  • Admin

    "This example" refers to the example found on the mysensors page.
    "uses the external DHT library" means you have to install the library in your ide by downloading it and install in your IDEs library path.

    If you want to fetch all the examples and support libraries in one schwong, use this link:
    https://github.com/mysensors/MySensorsArduinoExamples/archive/master.zip



  • got it thanks



  • @hek hi, this is what the Motion Sensor Log displays:

    0_1479059941596_upload-ad51ad8d-215b-4334-9e15-f7121e53a15f



  • @hek I got my sensors working now. The radio unit on the GW was defective, so I swapped it out and things are working fine, just need to change the readings on my DHT from C to F, how would I do that?


  • Admin

    The unit format is normally updated from the controller. When the sensor starts it asks for the configuration.

    But you can always hard code none-metric by setting it to false here:
    https://github.com/mysensors/MySensorsArduinoExamples/blob/master/examples/DhtTemperatureAndHumiditySensor/DhtTemperatureAndHumiditySensor.ino#L69

    .. and removing this line:

    https://github.com/mysensors/MySensorsArduinoExamples/blob/master/examples/DhtTemperatureAndHumiditySensor/DhtTemperatureAndHumiditySensor.ino#L85



  • @hek got it
    Thanks



  • @hek hi, how can I activate repeater mode on a particular sensor?, I've had to build 2 repeating nodes so far to be able to reach a couple of my sensors. I am adding more sensors as we speak and and they are getting farther and farther, I know I will need a ton of repeaters, but I hate to waste a radio and an Arduino board just for repeaters.
    Thanks


  • Admin



  • thanks so much, I am becoming a pro at this, one day YOU will come to me for questions lol.


  • Admin

    Hope so, I might soon get senile 😉



  • @hek said:

    senile
    are the the sensors/nodes awake at all times by default?



  • I had started a different thread that relates to this one and wasn't getting much for response, In my digging on the issue, I found this thread.

    I have owned my new Vera Plus for over a week now and I cannot get my sensors communicating with Vera. I am running UI7 I believe, and I have my gateway built with a pro mini and an Easy Newbie board from OpenHardware.IO. I appear to be getting communication from nodes over the gateway according to what I am seeing in the log, but I am not able to include my sensors. CLearly, when I press start and stop, inclusion mode is starting and stopping as I see it in the logs. My issue though goes back to a post in this thread from 5 months ago where he addresses an issue with incomming commands being discarded. Here is a snippet from my log that shows the process:
    0_1482849578478_image.png
    I posted as an image so you can better see the highlighting. For my TemperatureAndHumidity node, I have manually set the node ID to 84 as can be seen in the logs. The 3 lines in yellow look to me to be the sensor attempting to present itself, but the presentation messages are being discarded. I have seen this both with my humidity sensor node and my garage door sensor node. In the post I referred to from 5 months ago from BartE, he linked to the development version of the plugin, so I even tried that. The log snippet shown above is from the development branch plugin. I was originally using the UI7 branch linked in the Vera how-to setup guide on the website. This had a bit of a different look, but the logs looked the same when I would attempt inclusion.

    It is getting a bit discouraging since I have owned the controller for over a week now and I can't get the MySensors part working, which is mainly why I got it. If it means anything, I had my gateway and sensors working in Domoticz.

    You guys have been GREAT so far, so any help is appreciated.


  • Admin

    @dbemowsk

    This message appears when a none included node receives data.
    https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L466

    I can't see any presentation message from your node (84).. It should say "c=0" something.



  • @hek, thanks for the quick reply.
    You say "This message appears when a none included node receives data." but the only time I see those yellow lines is when I present the node.

    I see under the last discarded command:

    50	12/27/16 9:12:38.441	luup_log:10: Arduino: Log: TSP:MSG:READ 84-84-0 s=0,c=0,t=7,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 9:12:38.443	luup_log:10: Arduino: Presentation: 84;0;0;0;7; <0x73e23520>
    50	12/27/16 9:12:38.446	luup_log:10: Arduino: Log: TSP:MSG:READ 84-84-0 s=1,c=0,t=6,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 9:12:38.448	luup_log:10: Arduino: Presentation: 84;1;0;0;6; <0x73e23520>
    

    The two TSP:MSG:READ lines contain c=0. Is this what you were referring to?


  • Admin

    Yes, very strange. Presentation comes in. How could I miss that.

    I still run UI5 on my Vera. Wondering if they changed any behaviour in recent firmware updates?



  • I find it hard to believe that no one here has used UI7 and not seen this. It is a bit frustrating.


  • Admin

    What happens if you let vera hand out id?

    Clear eeprom and re-upload sketch. And try to include again.



  • That was one of my questions in the other thread. I was thinking that Vera wasn't handing out IDs, which is why I manually assigned it. I will try clearing eeprom and try again. I'll post the log results.


  • Admin

    Yes, the Vera plugin hands out ids.

    I can't really explain the weird behaviour you're seeing. Communication seems to work...


  • Hero Member

    Thanks @hek for chipping in an looking at the problem @dbemowsk is experiencing. This is really beyond my knowledge an I cannot understan why it is not working. I am running the latest UI7 firmware on my Veralite test device, am I cannot reproduce this issue. Including MySensor devices is no problem even if I use static node adress.



  • So I cleared the eeprom and re-uploaded the humidity sensor sketch. Had to rebuild it from the example because the arduino IDE crashed and erased it. That has happened to me a couple times now since starting with the IDE. This is with debug turned on and viewing the serial monitor. To me it looks like it fails to get an ID from Vera. This is what I was seeing before which was why I manually assigned the ID.

    Starting sensor (RNNNA-, 2.0.0)
    TSM:INIT
    TSM:RADIO:OK
    TSM:FPAR
    TSP:MSG:SEND 255-255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=bc:
    TSM:FPAR
    TSP:MSG:SEND 255-255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=bc:
    TSP:MSG:READ 0-0-255 s=255,c=3,t=8,pt=1,l=1,sg=0:0
    TSP:MSG:FPAR RES (ID=0, dist=0)
    TSP:MSG:PAR OK (ID=0, dist=1)
    TSM:FPAR:OK
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    TSM:ID 
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0 l=0,sg=0,ft=0,st=ok:
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    !TSM:CHKID:FAIL (ID=255)
    !TSM:FAILURE
    TSM:PDT
    

    This is the Vera log from start to stop inclusion with the node trying to get an ID. Here I see no c=0 or presentation entries.

    ,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:41.287	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    08	12/27/16 12:24:42.769	JobHandler_LuaUPnP::HandleActionRequest device: 10 service: urn:upnp-arduino-cc:serviceId:arduino1 action: StartInclusion <0x73c23520>
    08	12/27/16 12:24:42.770	JobHandler_LuaUPnP::HandleActionRequest argument DeviceNum=10 <0x73c23520>
    08	12/27/16 12:24:42.770	JobHandler_LuaUPnP::HandleActionRequest argument serviceId=urn:upnp-arduino-cc:serviceId:arduino1 <0x73c23520>
    08	12/27/16 12:24:42.770	JobHandler_LuaUPnP::HandleActionRequest argument action=StartInclusion <0x73c23520>
    50	12/27/16 12:24:42.772	luup_log:10: Arduino: Sending: 0;0;3;0;5;1 <0x779ea320>
    04	12/27/16 12:24:42.774	 <0x779ea320>
    50	12/27/16 12:24:43.305	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:43.307	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    50	12/27/16 12:24:45.325	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:45.327	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    50	12/27/16 12:24:51.308	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:51.310	luup_log:10: Arduino: Log: TSP:MSG:BC <0x73e23520>
    50	12/27/16 12:24:51.314	luup_log:10: Arduino: Log: TSP:MSG:FPAR REQ (sender=255) <0x73e23520>
    50	12/27/16 12:24:51.316	luup_log:10: Arduino: Log: TSP:CHKUPL:OK <0x73e23520>
    50	12/27/16 12:24:51.319	luup_log:10: Arduino: Log: TSP:MSG:GWL OK <0x73e23520>
    50	12/27/16 12:24:52.259	luup_log:10: Arduino: Log: TSP:MSG:SEND 0-0-255-255 s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=bc:0 <0x73e23520>
    50	12/27/16 12:24:53.331	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:53.332	luup_log:10: Arduino: Log: TSP:MSG:BC <0x73e23520>
    50	12/27/16 12:24:53.334	luup_log:10: Arduino: Log: TSP:MSG:FPAR REQ (sender=255) <0x73e23520>
    50	12/27/16 12:24:53.339	luup_log:10: Arduino: Log: TSP:CHKUPL:OK (FLDCTRL) <0x73e23520>
    50	12/27/16 12:24:53.340	luup_log:10: Arduino: Log: TSP:MSG:GWL OK <0x73e23520>
    50	12/27/16 12:24:54.252	luup_log:10: Arduino: Log: TSP:MSG:SEND 0-0-255-255 s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=bc:0 <0x73e23520>
    50	12/27/16 12:24:57.369	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:57.370	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    50	12/27/16 12:24:59.388	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:24:59.390	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    50	12/27/16 12:25:01.408	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:25:01.410	luup_log:10: Arduino: Sending: 255;255;3;0;4;255 <0x73e23520>
    50	12/27/16 12:25:13.497	luup_log:10: Arduino: Log: TSP:MSG:READ 255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0: <0x73e23520>
    50	12/27/16 12:25:13.499	luup_log:10: Arduino: Log: TSP:MSG:BC <0x73e23520>
    50	12/27/16 12:25:13.503	luup_log:10: Arduino: Log: TSP:MSG:FPAR REQ (sender=255) <0x73e23520>
    50	12/27/16 12:25:13.505	luup_log:10: Arduino: Log: TSP:CHKUPL:OK <0x73e23520>
    50	12/27/16 12:25:13.507	luup_log:10: Arduino: Log: TSP:MSG:GWL OK <0x73e23520>
    08	12/27/16 12:25:13.563	JobHandler_LuaUPnP::HandleActionRequest device: 10 service: urn:upnp-arduino-cc:serviceId:arduino1 action: StopInclusion <0x74423520>
    08	12/27/16 12:25:13.564	JobHandler_LuaUPnP::HandleActionRequest argument DeviceNum=10 <0x74423520>
    08	12/27/16 12:25:13.564	JobHandler_LuaUPnP::HandleActionRequest argument serviceId=urn:upnp-arduino-cc:serviceId:arduino1 <0x74423520>
    08	12/27/16 12:25:13.564	JobHandler_LuaUPnP::HandleActionRequest argument action=StopInclusion <0x74423520>
    50	12/27/16 12:25:13.565	luup_log:10: Arduino: Sending: 0;0;3;0;5;0 <0x779ea320>
    04	12/27/16 12:25:13.567	 <0x779ea320>
    

    I am not sure what to do next.


  • Admin

    Hmm.. it looks like your Vera is sending out id 255.. (255;255;3;0;4;255) which usually means that all ids has been used up.

    https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L299

    The table of used ids is build during plugin startup.. here:
    https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L686

    I have no idea why this get filled up (or why the plugin thinks so..) when you don't have any child devices to your gateway.



  • @hek Is there any way for me to debug what is happening with the availableIds[i] array? or at least finding where it is stored and clearing it? If not, maybe I'll try restoring my unit to default and try again. I am assuming that would clear the availableIds array. The only thing I currently have set up on the unit is my 1-Wire temp sensors, and there is only 7 of them. I can rebuild those easy enough.


  • Admin

    Well, it iterates over all vera devices (luup.devices) and checks if anyone is has the current device as parent... which means it is a child device.

    For each child device it adds it to the array. The problem here is that it shouldn't find any child devices.. thus the availableIds should all be filled with false.

    Maybe you could add some debug logging in the section I pointed out to see what kind of devices it picks up?



  • I am more than interested in trying, I just need a little guidance on how to do that.

    In the nextAvailiableRadioId() function I could do the following before it searches for an ID, I am just not sure what code to use to find out what device is defined for that ID.

    
    	for i=1,255 do 
    		if (availableIds[i] == false) then
    			--add code to log what device is holding this spot
    		end
    	end
    

  • Admin

    It might be more interesting if you'd add some logging in this area, which should appear in the log when you reload the luup engine:
    https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L682-L687

    v contains the device. See what it contains under "variable: devices" here:
    http://wiki.micasaverde.com/index.php/Luup_Lua_extensions



  • OK, so here is what I did:

    	-- build an lookup table for child device ids (altid -> id)
    	local lastDev = 0
    	for k, v in pairs(luup.devices) do
    		-- for debugging only remove for production run
    		for k2, v2 in pairs(v) do
    			if (k ~= lastDev) then
    				luup.log("Device #" .. k .. ":" .. k2 .. "=" .. tostring(v2))
    			else
    				luup.log("           " .. k2 .. "=" .. tostring(v2))
    			end
    			lastDev = k
    		end
    		-- end debugging
    		-- if I am the parent device
    		if v.device_num_parent == ARDUINO_DEVICE then
    			childIdLookupTable[v.id] = k
    			local split = v.id:split(";")
    			local radioId = tonumber(split[1])
    			availableIds[radioId] = false;
    		end
    	end
    

    I did this to show me every attribute of every device that the system sees. After the luup engine restarts, I get this in the logs:

    
    50	12/27/16 15:58:48.117	luup_log:19: Initialising One Wire Server <0x76be5520>
    50	12/27/16 15:58:48.221	luup_log:27: Arduino plugin: loading library L_Arduino ... <0x76be5520>
    50	12/27/16 15:58:48.239	luup_log:27: Arduino plugin: library L_Arduino loaded <0x76be5520>
    50	12/27/16 15:58:48.239	luup_log:27: Arduino: urn:upnp-arduino-cc:serviceId:arduino1,PluginVersion, 1.5, 27 <0x76be5520>
    50	12/27/16 15:58:48.239	luup_log:27: Arduino: Trying for a serial connection <0x76be5520>
    50	12/27/16 15:58:48.240	luup_log:27: Arduino: Serial port is connected <0x76be5520>
    50	12/27/16 15:58:48.240	luup_log:27: Arduino: Baud is 115200 <0x76be5520>
    50	12/27/16 15:58:48.240	luup_log:27: Device #1:mac= <0x76be5520>
    50	12/27/16 15:58:48.241	luup_log:27:            category_num=19 <0x76be5520>
    50	12/27/16 15:58:48.241	luup_log:27:            description=ZWave <0x76be5520>
    50	12/27/16 15:58:48.241	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.242	luup_log:27:            id= <0x76be5520>
    50	12/27/16 15:58:48.242	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.242	luup_log:27:            ip= <0x76be5520>
    50	12/27/16 15:58:48.242	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.242	luup_log:27:            udn=uuid:4d494342-5342-5645-0001-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.243	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:ZWaveNetwork:1 <0x76be5520>
    50	12/27/16 15:58:48.244	luup_log:27: Device #2:mac=000D6F000C5BC6E6 <0x76be5520>
    50	12/27/16 15:58:48.244	luup_log:27:            category_num=0 <0x76be5520>
    50	12/27/16 15:58:48.244	luup_log:27:            description=Zigbee Network <0x76be5520>
    50	12/27/16 15:58:48.244	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.245	luup_log:27:            id= <0x76be5520>
    50	12/27/16 15:58:48.245	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.245	luup_log:27:            ip= <0x76be5520>
    50	12/27/16 15:58:48.245	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.245	luup_log:27:            udn=uuid:4d494342-5342-5645-0002-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.246	luup_log:27:            subcategory_num=-1 <0x76be5520>
    50	12/27/16 15:58:48.246	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.246	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.246	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.246	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:ZigbeeNetwork:1 <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27: Device #3:mac=B4:A5:EF:ED:58:1D <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27:            category_num=0 <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27:            description=Bluetooth Network <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.247	luup_log:27:            id= <0x76be5520>
    50	12/27/16 15:58:48.248	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.248	luup_log:27:            ip= <0x76be5520>
    50	12/27/16 15:58:48.248	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.248	luup_log:27:            udn=uuid:4d494342-5342-5645-0003-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            subcategory_num=-1 <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.249	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:BluetoothNetwork:1 <0x76be5520>
    50	12/27/16 15:58:48.250	luup_log:27: Device #20:mac= <0x76be5520>
    50	12/27/16 15:58:48.250	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.250	luup_log:27:            description=Bar South Temp <0x76be5520>
    50	12/27/16 15:58:48.250	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.250	luup_log:27:            id=FE0000047CE7AE28:Temperature <0x76be5520>
    50	12/27/16 15:58:48.251	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.251	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.251	luup_log:27:            room_num=10 <0x76be5520>
    50	12/27/16 15:58:48.251	luup_log:27:            udn=uuid:4d494342-5342-5645-0014-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.251	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.252	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.252	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.252	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.252	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.252	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.253	luup_log:27: Device #21:mac= <0x76be5520>
    50	12/27/16 15:58:48.253	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.253	luup_log:27:            description=Guest Bedroom Temp <0x76be5520>
    50	12/27/16 15:58:48.253	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.253	luup_log:27:            id=9A02146426ECFF28:Temperature <0x76be5520>
    50	12/27/16 15:58:48.254	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.254	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.254	luup_log:27:            room_num=9 <0x76be5520>
    50	12/27/16 15:58:48.254	luup_log:27:            udn=uuid:4d494342-5342-5645-0015-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.254	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.255	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.255	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.255	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.255	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.255	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.256	luup_log:27: Device #22:mac= <0x76be5520>
    50	12/27/16 15:58:48.256	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.256	luup_log:27:            description=Office Temp <0x76be5520>
    50	12/27/16 15:58:48.256	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.257	luup_log:27:            id=C80000047D69C028:Temperature <0x76be5520>
    50	12/27/16 15:58:48.257	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.257	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.257	luup_log:27:            room_num=7 <0x76be5520>
    50	12/27/16 15:58:48.257	luup_log:27:            udn=uuid:4d494342-5342-5645-0016-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.258	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.259	luup_log:27: Device #23:mac= <0x76be5520>
    50	12/27/16 15:58:48.259	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.259	luup_log:27:            description=Master Bedroom Temp <0x76be5520>
    50	12/27/16 15:58:48.259	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.259	luup_log:27:            id=5602146472A5FF28:Temperature <0x76be5520>
    50	12/27/16 15:58:48.260	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.260	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.260	luup_log:27:            room_num=8 <0x76be5520>
    50	12/27/16 15:58:48.260	luup_log:27:            udn=uuid:4d494342-5342-5645-0017-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.260	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.261	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.261	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.261	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.261	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.261	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.262	luup_log:27: Device #24:mac= <0x76be5520>
    50	12/27/16 15:58:48.262	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.262	luup_log:27:            description=Kitchen Hall Temp <0x76be5520>
    50	12/27/16 15:58:48.262	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.262	luup_log:27:            id=9E000003A827AF28:Temperature <0x76be5520>
    50	12/27/16 15:58:48.263	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.263	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.263	luup_log:27:            room_num=3 <0x76be5520>
    50	12/27/16 15:58:48.263	luup_log:27:            udn=uuid:4d494342-5342-5645-0018-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.263	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.264	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.264	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.264	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.264	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.264	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.265	luup_log:27: Device #25:mac= <0x76be5520>
    50	12/27/16 15:58:48.265	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.265	luup_log:27:            description=Bar North Temp <0x76be5520>
    50	12/27/16 15:58:48.265	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.265	luup_log:27:            id=7A000003A7472828:Temperature <0x76be5520>
    50	12/27/16 15:58:48.266	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.266	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.266	luup_log:27:            room_num=10 <0x76be5520>
    50	12/27/16 15:58:48.266	luup_log:27:            udn=uuid:4d494342-5342-5645-0019-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.266	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.267	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.267	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.267	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.267	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.267	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.268	luup_log:27: Device #26:mac= <0x76be5520>
    50	12/27/16 15:58:48.268	luup_log:27:            category_num=17 <0x76be5520>
    50	12/27/16 15:58:48.268	luup_log:27:            description=Outside Temp <0x76be5520>
    50	12/27/16 15:58:48.268	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.268	luup_log:27:            id=F60000047DA93228:Temperature <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            room_num=13 <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            udn=uuid:4d494342-5342-5645-001a-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.269	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.270	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.270	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.270	luup_log:27:            device_num_parent=19 <0x76be5520>
    50	12/27/16 15:58:48.270	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:TemperatureSensor:1 <0x76be5520>
    50	12/27/16 15:58:48.270	luup_log:27: Device #27:mac= <0x76be5520>
    50	12/27/16 15:58:48.271	luup_log:27:            category_num=0 <0x76be5520>
    50	12/27/16 15:58:48.271	luup_log:27:            description=MySensors Plugin <0x76be5520>
    50	12/27/16 15:58:48.271	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.271	luup_log:27:            id= <0x76be5520>
    50	12/27/16 15:58:48.271	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.272	luup_log:27:            ip= <0x76be5520>
    50	12/27/16 15:58:48.272	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.272	luup_log:27:            udn=uuid:4d494342-5342-5645-001b-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.272	luup_log:27:            subcategory_num=-1 <0x76be5520>
    50	12/27/16 15:58:48.272	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.273	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.273	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.273	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.273	luup_log:27:            device_type=urn:schemas-arduino-cc:device:arduino:1 <0x76be5520>
    50	12/27/16 15:58:48.273	luup_log:27: Device #5:mac= <0x76be5520>
    50	12/27/16 15:58:48.274	luup_log:27:            category_num=0 <0x76be5520>
    50	12/27/16 15:58:48.274	luup_log:27:            description=Serial_Portlist_2144272085 <0x76be5520>
    50	12/27/16 15:58:48.274	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.274	luup_log:27:            id=50009936 <0x76be5520>
    50	12/27/16 15:58:48.274	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.275	luup_log:27:            ip=127.0.0.1 <0x76be5520>
    50	12/27/16 15:58:48.275	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.275	luup_log:27:            udn=uuid:4d494342-5342-5645-0005-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.275	luup_log:27:            subcategory_num=-1 <0x76be5520>
    50	12/27/16 15:58:48.275	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.276	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.276	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.276	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.276	luup_log:27:            device_type=urn:micasaverde-org:device:SerialPortRoot:1 <0x76be5520>
    50	12/27/16 15:58:48.276	luup_log:27: Device #4:mac= <0x76be5520>
    50	12/27/16 15:58:48.277	luup_log:27:            category_num=14 <0x76be5520>
    50	12/27/16 15:58:48.277	luup_log:27:            description=_Scene Controller <0x76be5520>
    50	12/27/16 15:58:48.277	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.277	luup_log:27:            id=1 <0x76be5520>
    50	12/27/16 15:58:48.277	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            ip= <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            udn=uuid:4d494342-5342-5645-0004-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.278	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.279	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.279	luup_log:27:            device_num_parent=1 <0x76be5520>
    50	12/27/16 15:58:48.279	luup_log:27:            device_type=urn:schemas-micasaverde-com:device:SceneController:1 <0x76be5520>
    50	12/27/16 15:58:48.279	luup_log:27: Device #6:mac= <0x76be5520>
    50	12/27/16 15:58:48.279	luup_log:27:            category_num=13 <0x76be5520>
    50	12/27/16 15:58:48.280	luup_log:27:            description=pl2303 <0x76be5520>
    50	12/27/16 15:58:48.280	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.280	luup_log:27:            id=usb-xhci-hcd-1.1 <0x76be5520>
    50	12/27/16 15:58:48.280	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.280	luup_log:27:            ip=127.0.0.1 <0x76be5520>
    50	12/27/16 15:58:48.281	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.281	luup_log:27:            udn=uuid:4d494342-5342-5645-0006-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.281	luup_log:27:            subcategory_num=0 <0x76be5520>
    50	12/27/16 15:58:48.281	luup_log:27:            invisible=true <0x76be5520>
    50	12/27/16 15:58:48.281	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.282	luup_log:27:            embedded=true <0x76be5520>
    50	12/27/16 15:58:48.282	luup_log:27:            device_num_parent=5 <0x76be5520>
    50	12/27/16 15:58:48.282	luup_log:27:            device_type=urn:micasaverde-org:device:SerialPort:1 <0x76be5520>
    50	12/27/16 15:58:48.282	luup_log:27: Device #19:mac= <0x76be5520>
    50	12/27/16 15:58:48.282	luup_log:27:            category_num=0 <0x76be5520>
    50	12/27/16 15:58:48.283	luup_log:27:            description=OWServer <0x76be5520>
    50	12/27/16 15:58:48.283	luup_log:27:            user= <0x76be5520>
    50	12/27/16 15:58:48.283	luup_log:27:            id= <0x76be5520>
    50	12/27/16 15:58:48.283	luup_log:27:            pass= <0x76be5520>
    50	12/27/16 15:58:48.283	luup_log:27:            ip=192.168.1.11 <0x76be5520>
    50	12/27/16 15:58:48.284	luup_log:27:            room_num=0 <0x76be5520>
    50	12/27/16 15:58:48.284	luup_log:27:            udn=uuid:4d494342-5342-5645-0013-000002fb1750 <0x76be5520>
    50	12/27/16 15:58:48.284	luup_log:27:            subcategory_num=-1 <0x76be5520>
    50	12/27/16 15:58:48.284	luup_log:27:            invisible=false <0x76be5520>
    50	12/27/16 15:58:48.284	luup_log:27:            hidden=false <0x76be5520>
    50	12/27/16 15:58:48.285	luup_log:27:            embedded=false <0x76be5520>
    50	12/27/16 15:58:48.285	luup_log:27:            device_num_parent=0 <0x76be5520>
    50	12/27/16 15:58:48.285	luup_log:27:            device_type=urn:cd-jackson-com:device:OWServer:1 <0x76be5520>
    50	12/27/16 15:58:48.286	luup_log:27: Arduino: Sending: 0;0;3;0;2;Get Version <0x76be5520>
    50	12/27/16 15:58:49.066	luup_log:27: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x739e5520>
    50	12/27/16 15:58:49.067	luup_log:27: Arduino: Sending: 255;255;3;0;4;1 <0x739e5520>
    50	12/27/16 15:58:50.547	luup_log:27: Arduino: Log: TSP:SANCHK:OK <0x739e5520>
    50	12/27/16 15:58:51.085	luup_log:27: Arduino: Log: TSP:MSG:READ 255-255-0 s=255,c=3,t=3,pt=0,l=0,sg=0: <0x739e5520>
    50	12/27/16 15:58:51.086	luup_log:27: Arduino: Sending: 255;255;3;0;4;2 <0x739e5520>
    

    The highest device # it shows is 27 which doesn't even come close to hitting the 254 mark. I am baffled.



  • Out of curiosity, what is the difference between log() and luup.log()?


  • Admin

    log is a local function defined a bit higher up in the file.

    Ok, what does the availableIds contain after the device loop?

    for i=1,MAX_RADIO_ID do
    log(availableIds[i]);
    end



  • So here is the code now:

    	-- build an lookup table for child device ids (altid -> id)
    	local lastDev = 0
    	for k, v in pairs(luup.devices) do
    		-- for debugging only remove for production run
    		for k2, v2 in pairs(v) do
    			if (k ~= lastDev) then
    				luup.log("Device #" .. k .. ":" .. k2 .. "=" .. tostring(v2))
    			else
    				luup.log("           " .. k2 .. "=" .. tostring(v2))
    			end
    			lastDev = k
    		end
    		-- end debugging
    		-- if I am the parent device
    		if v.device_num_parent == ARDUINO_DEVICE then
    			childIdLookupTable[v.id] = k
    			local split = v.id:split(";")
    			local radioId = tonumber(split[1])
    			availableIds[radioId] = false;
    		end
    	end
    
    	for i=1, MAX_RADIO_ID do
    		log("id #" .. i .. ": " .. (availableIds[i] and "TRUE" or "FALSE"));
    	end
    

    Just doing:

    log(availableIds[i]);
    

    crashed the script because the log method apparently couldn't handle boolean values. So I had it print the ID number and used a ternary operator to display true or false. I think that use of a ternary is correct for lua. Anyways, here is the log:

    
    50	12/27/16 19:45:33.285	luup_log:27: Device #19:mac= <0x77383520>
    50	12/27/16 19:45:33.285	luup_log:27:            category_num=0 <0x77383520>
    50	12/27/16 19:45:33.285	luup_log:27:            description=OWServer <0x77383520>
    50	12/27/16 19:45:33.285	luup_log:27:            user= <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            id= <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            pass= <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            ip=192.168.1.11 <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            room_num=0 <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            udn=uuid:4d494342-5342-5645-0013-000002fb1750 <0x77383520>
    50	12/27/16 19:45:33.286	luup_log:27:            subcategory_num=-1 <0x77383520>
    50	12/27/16 19:45:33.287	luup_log:27:            invisible=false <0x77383520>
    50	12/27/16 19:45:33.287	luup_log:27:            hidden=false <0x77383520>
    50	12/27/16 19:45:33.287	luup_log:27:            embedded=false <0x77383520>
    50	12/27/16 19:45:33.287	luup_log:27:            device_num_parent=0 <0x77383520>
    50	12/27/16 19:45:33.287	luup_log:27:            device_type=urn:cd-jackson-com:device:OWServer:1 <0x77383520>
    50	12/27/16 19:45:33.288	luup_log:27: Arduino: id #1: TRUE <0x77383520>
    50	12/27/16 19:45:33.288	luup_log:27: Arduino: id #2: TRUE <0x77383520>
    50	12/27/16 19:45:33.288	luup_log:27: Arduino: id #3: TRUE <0x77383520>
    50	12/27/16 19:45:33.288	luup_log:27: Arduino: id #4: TRUE <0x77383520>
    50	12/27/16 19:45:33.289	luup_log:27: Arduino: id #5: TRUE <0x77383520>
    50	12/27/16 19:45:33.289	luup_log:27: Arduino: id #6: TRUE <0x77383520>
    50	12/27/16 19:45:33.289	luup_log:27: Arduino: id #7: TRUE <0x77383520>
    50	12/27/16 19:45:33.289	luup_log:27: Arduino: id #8: TRUE <0x77383520>
    50	12/27/16 19:45:33.289	luup_log:27: Arduino: id #9: TRUE <0x77383520>
    50	12/27/16 19:45:33.290	luup_log:27: Arduino: id #10: TRUE <0x77383520>
    50	12/27/16 19:45:33.290	luup_log:27: Arduino: id #11: TRUE <0x77383520>
    50	12/27/16 19:45:33.290	luup_log:27: Arduino: id #12: TRUE <0x77383520>
    50	12/27/16 19:45:33.290	luup_log:27: Arduino: id #13: TRUE <0x77383520>
    50	12/27/16 19:45:33.291	luup_log:27: Arduino: id #14: TRUE <0x77383520>
    50	12/27/16 19:45:33.291	luup_log:27: Arduino: id #15: TRUE <0x77383520>
    50	12/27/16 19:45:33.291	luup_log:27: Arduino: id #16: TRUE <0x77383520>
    50	12/27/16 19:45:33.291	luup_log:27: Arduino: id #17: TRUE <0x77383520>
    50	12/27/16 19:45:33.292	luup_log:27: Arduino: id #18: TRUE <0x77383520>
    50	12/27/16 19:45:33.292	luup_log:27: Arduino: id #19: TRUE <0x77383520>
    50	12/27/16 19:45:33.292	luup_log:27: Arduino: id #20: TRUE <0x77383520>
    50	12/27/16 19:45:33.292	luup_log:27: Arduino: id #21: TRUE <0x77383520>
    50	12/27/16 19:45:33.292	luup_log:27: Arduino: id #22: TRUE <0x77383520>
    50	12/27/16 19:45:33.293	luup_log:27: Arduino: id #23: TRUE <0x77383520>
    50	12/27/16 19:45:33.293	luup_log:27: Arduino: id #24: TRUE <0x77383520>
    50	12/27/16 19:45:33.293	luup_log:27: Arduino: id #25: TRUE <0x77383520>
    50	12/27/16 19:45:33.293	luup_log:27: Arduino: id #26: TRUE <0x77383520>
    50	12/27/16 19:45:33.294	luup_log:27: Arduino: id #27: TRUE <0x77383520>
    50	12/27/16 19:45:33.294	luup_log:27: Arduino: id #28: TRUE <0x77383520>
    50	12/27/16 19:45:33.294	luup_log:27: Arduino: id #29: TRUE <0x77383520>
    50	12/27/16 19:45:33.294	luup_log:27: Arduino: id #30: TRUE <0x77383520>
    50	12/27/16 19:45:33.294	luup_log:27: Arduino: id #31: TRUE <0x77383520>
    50	12/27/16 19:45:33.295	luup_log:27: Arduino: id #32: TRUE <0x77383520>
    50	12/27/16 19:45:33.295	luup_log:27: Arduino: id #33: TRUE <0x77383520>
    50	12/27/16 19:45:33.295	luup_log:27: Arduino: id #34: TRUE <0x77383520>
    50	12/27/16 19:45:33.295	luup_log:27: Arduino: id #35: TRUE <0x77383520>
    50	12/27/16 19:45:33.295	luup_log:27: Arduino: id #36: TRUE <0x77383520>
    50	12/27/16 19:45:33.296	luup_log:27: Arduino: id #37: TRUE <0x77383520>
    50	12/27/16 19:45:33.296	luup_log:27: Arduino: id #38: TRUE <0x77383520>
    50	12/27/16 19:45:33.296	luup_log:27: Arduino: id #39: TRUE <0x77383520>
    50	12/27/16 19:45:33.296	luup_log:27: Arduino: id #40: TRUE <0x77383520>
    50	12/27/16 19:45:33.296	luup_log:27: Arduino: id #41: TRUE <0x77383520>
    50	12/27/16 19:45:33.297	luup_log:27: Arduino: id #42: TRUE <0x77383520>
    50	12/27/16 19:45:33.297	luup_log:27: Arduino: id #43: TRUE <0x77383520>
    50	12/27/16 19:45:33.297	luup_log:27: Arduino: id #44: TRUE <0x77383520>
    50	12/27/16 19:45:33.297	luup_log:27: Arduino: id #45: TRUE <0x77383520>
    50	12/27/16 19:45:33.297	luup_log:27: Arduino: id #46: TRUE <0x77383520>
    50	12/27/16 19:45:33.298	luup_log:27: Arduino: id #47: TRUE <0x77383520>
    50	12/27/16 19:45:33.298	luup_log:27: Arduino: id #48: TRUE <0x77383520>
    50	12/27/16 19:45:33.298	luup_log:27: Arduino: id #49: TRUE <0x77383520>
    50	12/27/16 19:45:33.298	luup_log:27: Arduino: id #50: TRUE <0x77383520>
    50	12/27/16 19:45:33.298	luup_log:27: Arduino: id #51: TRUE <0x77383520>
    50	12/27/16 19:45:33.299	luup_log:27: Arduino: id #52: TRUE <0x77383520>
    50	12/27/16 19:45:33.299	luup_log:27: Arduino: id #53: TRUE <0x77383520>
    50	12/27/16 19:45:33.299	luup_log:27: Arduino: id #54: TRUE <0x77383520>
    50	12/27/16 19:45:33.299	luup_log:27: Arduino: id #55: TRUE <0x77383520>
    50	12/27/16 19:45:33.299	luup_log:27: Arduino: id #56: TRUE <0x77383520>
    50	12/27/16 19:45:33.300	luup_log:27: Arduino: id #57: TRUE <0x77383520>
    50	12/27/16 19:45:33.300	luup_log:27: Arduino: id #58: TRUE <0x77383520>
    50	12/27/16 19:45:33.300	luup_log:27: Arduino: id #59: TRUE <0x77383520>
    50	12/27/16 19:45:33.300	luup_log:27: Arduino: id #60: TRUE <0x77383520>
    50	12/27/16 19:45:33.301	luup_log:27: Arduino: id #61: TRUE <0x77383520>
    50	12/27/16 19:45:33.301	luup_log:27: Arduino: id #62: TRUE <0x77383520>
    50	12/27/16 19:45:33.301	luup_log:27: Arduino: id #63: TRUE <0x77383520>
    50	12/27/16 19:45:33.301	luup_log:27: Arduino: id #64: TRUE <0x77383520>
    50	12/27/16 19:45:33.302	luup_log:27: Arduino: id #65: TRUE <0x77383520>
    50	12/27/16 19:45:33.302	luup_log:27: Arduino: id #66: TRUE <0x77383520>
    50	12/27/16 19:45:33.302	luup_log:27: Arduino: id #67: TRUE <0x77383520>
    50	12/27/16 19:45:33.302	luup_log:27: Arduino: id #68: TRUE <0x77383520>
    50	12/27/16 19:45:33.302	luup_log:27: Arduino: id #69: TRUE <0x77383520>
    50	12/27/16 19:45:33.303	luup_log:27: Arduino: id #70: TRUE <0x77383520>
    50	12/27/16 19:45:33.303	luup_log:27: Arduino: id #71: TRUE <0x77383520>
    50	12/27/16 19:45:33.303	luup_log:27: Arduino: id #72: TRUE <0x77383520>
    50	12/27/16 19:45:33.303	luup_log:27: Arduino: id #73: TRUE <0x77383520>
    50	12/27/16 19:45:33.303	luup_log:27: Arduino: id #74: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #75: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #76: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #77: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #78: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #79: TRUE <0x77383520>
    50	12/27/16 19:45:33.304	luup_log:27: Arduino: id #80: TRUE <0x77383520>
    50	12/27/16 19:45:33.305	luup_log:27: Arduino: id #81: TRUE <0x77383520>
    50	12/27/16 19:45:33.305	luup_log:27: Arduino: id #82: TRUE <0x77383520>
    50	12/27/16 19:45:33.305	luup_log:27: Arduino: id #83: TRUE <0x77383520>
    50	12/27/16 19:45:33.305	luup_log:27: Arduino: id #84: TRUE <0x77383520>
    50	12/27/16 19:45:33.306	luup_log:27: Arduino: id #85: TRUE <0x77383520>
    50	12/27/16 19:45:33.306	luup_log:27: Arduino: id #86: TRUE <0x77383520>
    50	12/27/16 19:45:33.306	luup_log:27: Arduino: id #87: TRUE <0x77383520>
    50	12/27/16 19:45:33.306	luup_log:27: Arduino: id #88: TRUE <0x77383520>
    50	12/27/16 19:45:33.306	luup_log:27: Arduino: id #89: TRUE <0x77383520>
    50	12/27/16 19:45:33.307	luup_log:27: Arduino: id #90: TRUE <0x77383520>
    50	12/27/16 19:45:33.307	luup_log:27: Arduino: id #91: TRUE <0x77383520>
    50	12/27/16 19:45:33.307	luup_log:27: Arduino: id #92: TRUE <0x77383520>
    50	12/27/16 19:45:33.307	luup_log:27: Arduino: id #93: TRUE <0x77383520>
    50	12/27/16 19:45:33.307	luup_log:27: Arduino: id #94: TRUE <0x77383520>
    50	12/27/16 19:45:33.308	luup_log:27: Arduino: id #95: TRUE <0x77383520>
    50	12/27/16 19:45:33.308	luup_log:27: Arduino: id #96: TRUE <0x77383520>
    50	12/27/16 19:45:33.308	luup_log:27: Arduino: id #97: TRUE <0x77383520>
    50	12/27/16 19:45:33.308	luup_log:27: Arduino: id #98: TRUE <0x77383520>
    50	12/27/16 19:45:33.308	luup_log:27: Arduino: id #99: TRUE <0x77383520>
    50	12/27/16 19:45:33.309	luup_log:27: Arduino: id #100: TRUE <0x77383520>
    50	12/27/16 19:45:33.309	luup_log:27: Arduino: id #101: TRUE <0x77383520>
    50	12/27/16 19:45:33.309	luup_log:27: Arduino: id #102: TRUE <0x77383520>
    50	12/27/16 19:45:33.309	luup_log:27: Arduino: id #103: TRUE <0x77383520>
    50	12/27/16 19:45:33.309	luup_log:27: Arduino: id #104: TRUE <0x77383520>
    50	12/27/16 19:45:33.310	luup_log:27: Arduino: id #105: TRUE <0x77383520>
    50	12/27/16 19:45:33.310	luup_log:27: Arduino: id #106: TRUE <0x77383520>
    50	12/27/16 19:45:33.310	luup_log:27: Arduino: id #107: TRUE <0x77383520>
    50	12/27/16 19:45:33.310	luup_log:27: Arduino: id #108: TRUE <0x77383520>
    50	12/27/16 19:45:33.310	luup_log:27: Arduino: id #109: TRUE <0x77383520>
    50	12/27/16 19:45:33.311	luup_log:27: Arduino: id #110: TRUE <0x77383520>
    50	12/27/16 19:45:33.311	luup_log:27: Arduino: id #111: TRUE <0x77383520>
    50	12/27/16 19:45:33.311	luup_log:27: Arduino: id #112: TRUE <0x77383520>
    50	12/27/16 19:45:33.311	luup_log:27: Arduino: id #113: TRUE <0x77383520>
    50	12/27/16 19:45:33.312	luup_log:27: Arduino: id #114: TRUE <0x77383520>
    50	12/27/16 19:45:33.312	luup_log:27: Arduino: id #115: TRUE <0x77383520>
    50	12/27/16 19:45:33.312	luup_log:27: Arduino: id #116: TRUE <0x77383520>
    50	12/27/16 19:45:33.312	luup_log:27: Arduino: id #117: TRUE <0x77383520>
    50	12/27/16 19:45:33.313	luup_log:27: Arduino: id #118: TRUE <0x77383520>
    50	12/27/16 19:45:33.313	luup_log:27: Arduino: id #119: TRUE <0x77383520>
    50	12/27/16 19:45:33.313	luup_log:27: Arduino: id #120: TRUE <0x77383520>
    50	12/27/16 19:45:33.313	luup_log:27: Arduino: id #121: TRUE <0x77383520>
    50	12/27/16 19:45:33.313	luup_log:27: Arduino: id #122: TRUE <0x77383520>
    50	12/27/16 19:45:33.314	luup_log:27: Arduino: id #123: TRUE <0x77383520>
    50	12/27/16 19:45:33.314	luup_log:27: Arduino: id #124: TRUE <0x77383520>
    50	12/27/16 19:45:33.314	luup_log:27: Arduino: id #125: TRUE <0x77383520>
    50	12/27/16 19:45:33.314	luup_log:27: Arduino: id #126: TRUE <0x77383520>
    50	12/27/16 19:45:33.314	luup_log:27: Arduino: id #127: TRUE <0x77383520>
    50	12/27/16 19:45:33.315	luup_log:27: Arduino: id #128: TRUE <0x77383520>
    50	12/27/16 19:45:33.315	luup_log:27: Arduino: id #129: TRUE <0x77383520>
    50	12/27/16 19:45:33.315	luup_log:27: Arduino: id #130: TRUE <0x77383520>
    50	12/27/16 19:45:33.315	luup_log:27: Arduino: id #131: TRUE <0x77383520>
    50	12/27/16 19:45:33.315	luup_log:27: Arduino: id #132: TRUE <0x77383520>
    50	12/27/16 19:45:33.316	luup_log:27: Arduino: id #133: TRUE <0x77383520>
    50	12/27/16 19:45:33.316	luup_log:27: Arduino: id #134: TRUE <0x77383520>
    50	12/27/16 19:45:33.316	luup_log:27: Arduino: id #135: TRUE <0x77383520>
    50	12/27/16 19:45:33.316	luup_log:27: Arduino: id #136: TRUE <0x77383520>
    50	12/27/16 19:45:33.316	luup_log:27: Arduino: id #137: TRUE <0x77383520>
    50	12/27/16 19:45:33.317	luup_log:27: Arduino: id #138: TRUE <0x77383520>
    50	12/27/16 19:45:33.317	luup_log:27: Arduino: id #139: TRUE <0x77383520>
    50	12/27/16 19:45:33.317	luup_log:27: Arduino: id #140: TRUE <0x77383520>
    50	12/27/16 19:45:33.317	luup_log:27: Arduino: id #141: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #142: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #143: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #144: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #145: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #146: TRUE <0x77383520>
    50	12/27/16 19:45:33.318	luup_log:27: Arduino: id #147: TRUE <0x77383520>
    50	12/27/16 19:45:33.319	luup_log:27: Arduino: id #148: TRUE <0x77383520>
    50	12/27/16 19:45:33.319	luup_log:27: Arduino: id #149: TRUE <0x77383520>
    50	12/27/16 19:45:33.319	luup_log:27: Arduino: id #150: TRUE <0x77383520>
    50	12/27/16 19:45:33.319	luup_log:27: Arduino: id #151: TRUE <0x77383520>
    50	12/27/16 19:45:33.319	luup_log:27: Arduino: id #152: TRUE <0x77383520>
    50	12/27/16 19:45:33.320	luup_log:27: Arduino: id #153: TRUE <0x77383520>
    50	12/27/16 19:45:33.320	luup_log:27: Arduino: id #154: TRUE <0x77383520>
    50	12/27/16 19:45:33.320	luup_log:27: Arduino: id #155: TRUE <0x77383520>
    50	12/27/16 19:45:33.320	luup_log:27: Arduino: id #156: TRUE <0x77383520>
    50	12/27/16 19:45:33.320	luup_log:27: Arduino: id #157: TRUE <0x77383520>
    50	12/27/16 19:45:33.321	luup_log:27: Arduino: id #158: TRUE <0x77383520>
    50	12/27/16 19:45:33.321	luup_log:27: Arduino: id #159: TRUE <0x77383520>
    50	12/27/16 19:45:33.321	luup_log:27: Arduino: id #160: TRUE <0x77383520>
    50	12/27/16 19:45:33.321	luup_log:27: Arduino: id #161: TRUE <0x77383520>
    50	12/27/16 19:45:33.322	luup_log:27: Arduino: id #162: TRUE <0x77383520>
    50	12/27/16 19:45:33.322	luup_log:27: Arduino: id #163: TRUE <0x77383520>
    50	12/27/16 19:45:33.322	luup_log:27: Arduino: id #164: TRUE <0x77383520>
    50	12/27/16 19:45:33.322	luup_log:27: Arduino: id #165: TRUE <0x77383520>
    50	12/27/16 19:45:33.323	luup_log:27: Arduino: id #166: TRUE <0x77383520>
    50	12/27/16 19:45:33.323	luup_log:27: Arduino: id #167: TRUE <0x77383520>
    50	12/27/16 19:45:33.323	luup_log:27: Arduino: id #168: TRUE <0x77383520>
    50	12/27/16 19:45:33.323	luup_log:27: Arduino: id #169: TRUE <0x77383520>
    50	12/27/16 19:45:33.323	luup_log:27: Arduino: id #170: TRUE <0x77383520>
    50	12/27/16 19:45:33.324	luup_log:27: Arduino: id #171: TRUE <0x77383520>
    50	12/27/16 19:45:33.324	luup_log:27: Arduino: id #172: TRUE <0x77383520>
    50	12/27/16 19:45:33.324	luup_log:27: Arduino: id #173: TRUE <0x77383520>
    50	12/27/16 19:45:33.324	luup_log:27: Arduino: id #174: TRUE <0x77383520>
    50	12/27/16 19:45:33.324	luup_log:27: Arduino: id #175: TRUE <0x77383520>
    50	12/27/16 19:45:33.325	luup_log:27: Arduino: id #176: TRUE <0x77383520>
    50	12/27/16 19:45:33.325	luup_log:27: Arduino: id #177: TRUE <0x77383520>
    50	12/27/16 19:45:33.325	luup_log:27: Arduino: id #178: TRUE <0x77383520>
    50	12/27/16 19:45:33.325	luup_log:27: Arduino: id #179: TRUE <0x77383520>
    50	12/27/16 19:45:33.326	luup_log:27: Arduino: id #180: TRUE <0x77383520>
    50	12/27/16 19:45:33.326	luup_log:27: Arduino: id #181: TRUE <0x77383520>
    50	12/27/16 19:45:33.326	luup_log:27: Arduino: id #182: TRUE <0x77383520>
    50	12/27/16 19:45:33.326	luup_log:27: Arduino: id #183: TRUE <0x77383520>
    50	12/27/16 19:45:33.326	luup_log:27: Arduino: id #184: TRUE <0x77383520>
    50	12/27/16 19:45:33.327	luup_log:27: Arduino: id #185: TRUE <0x77383520>
    50	12/27/16 19:45:33.327	luup_log:27: Arduino: id #186: TRUE <0x77383520>
    50	12/27/16 19:45:33.327	luup_log:27: Arduino: id #187: TRUE <0x77383520>
    50	12/27/16 19:45:33.327	luup_log:27: Arduino: id #188: TRUE <0x77383520>
    50	12/27/16 19:45:33.327	luup_log:27: Arduino: id #189: TRUE <0x77383520>
    50	12/27/16 19:45:33.328	luup_log:27: Arduino: id #190: TRUE <0x77383520>
    50	12/27/16 19:45:33.328	luup_log:27: Arduino: id #191: TRUE <0x77383520>
    50	12/27/16 19:45:33.328	luup_log:27: Arduino: id #192: TRUE <0x77383520>
    50	12/27/16 19:45:33.328	luup_log:27: Arduino: id #193: TRUE <0x77383520>
    50	12/27/16 19:45:33.328	luup_log:27: Arduino: id #194: TRUE <0x77383520>
    50	12/27/16 19:45:33.329	luup_log:27: Arduino: id #195: TRUE <0x77383520>
    50	12/27/16 19:45:33.329	luup_log:27: Arduino: id #196: TRUE <0x77383520>
    50	12/27/16 19:45:33.329	luup_log:27: Arduino: id #197: TRUE <0x77383520>
    50	12/27/16 19:45:33.329	luup_log:27: Arduino: id #198: TRUE <0x77383520>
    50	12/27/16 19:45:33.329	luup_log:27: Arduino: id #199: TRUE <0x77383520>
    50	12/27/16 19:45:33.330	luup_log:27: Arduino: id #200: TRUE <0x77383520>
    50	12/27/16 19:45:33.330	luup_log:27: Arduino: id #201: TRUE <0x77383520>
    50	12/27/16 19:45:33.330	luup_log:27: Arduino: id #202: TRUE <0x77383520>
    50	12/27/16 19:45:33.330	luup_log:27: Arduino: id #203: TRUE <0x77383520>
    50	12/27/16 19:45:33.330	luup_log:27: Arduino: id #204: TRUE <0x77383520>
    50	12/27/16 19:45:33.331	luup_log:27: Arduino: id #205: TRUE <0x77383520>
    50	12/27/16 19:45:33.331	luup_log:27: Arduino: id #206: TRUE <0x77383520>
    50	12/27/16 19:45:33.331	luup_log:27: Arduino: id #207: TRUE <0x77383520>
    50	12/27/16 19:45:33.331	luup_log:27: Arduino: id #208: TRUE <0x77383520>
    50	12/27/16 19:45:33.331	luup_log:27: Arduino: id #209: TRUE <0x77383520>
    50	12/27/16 19:45:33.332	luup_log:27: Arduino: id #210: TRUE <0x77383520>
    50	12/27/16 19:45:33.332	luup_log:27: Arduino: id #211: TRUE <0x77383520>
    50	12/27/16 19:45:33.332	luup_log:27: Arduino: id #212: TRUE <0x77383520>
    50	12/27/16 19:45:33.332	luup_log:27: Arduino: id #213: TRUE <0x77383520>
    50	12/27/16 19:45:33.333	luup_log:27: Arduino: id #214: TRUE <0x77383520>
    50	12/27/16 19:45:33.333	luup_log:27: Arduino: id #215: TRUE <0x77383520>
    50	12/27/16 19:45:33.333	luup_log:27: Arduino: id #216: TRUE <0x77383520>
    50	12/27/16 19:45:33.333	luup_log:27: Arduino: id #217: TRUE <0x77383520>
    50	12/27/16 19:45:33.333	luup_log:27: Arduino: id #218: TRUE <0x77383520>
    50	12/27/16 19:45:33.334	luup_log:27: Arduino: id #219: TRUE <0x77383520>
    50	12/27/16 19:45:33.334	luup_log:27: Arduino: id #220: TRUE <0x77383520>
    50	12/27/16 19:45:33.334	luup_log:27: Arduino: id #221: TRUE <0x77383520>
    50	12/27/16 19:45:33.334	luup_log:27: Arduino: id #222: TRUE <0x77383520>
    50	12/27/16 19:45:33.334	luup_log:27: Arduino: id #223: TRUE <0x77383520>
    50	12/27/16 19:45:33.335	luup_log:27: Arduino: id #224: TRUE <0x77383520>
    50	12/27/16 19:45:33.335	luup_log:27: Arduino: id #225: TRUE <0x77383520>
    50	12/27/16 19:45:33.335	luup_log:27: Arduino: id #226: TRUE <0x77383520>
    50	12/27/16 19:45:33.335	luup_log:27: Arduino: id #227: TRUE <0x77383520>
    50	12/27/16 19:45:33.335	luup_log:27: Arduino: id #228: TRUE <0x77383520>
    50	12/27/16 19:45:33.336	luup_log:27: Arduino: id #229: TRUE <0x77383520>
    50	12/27/16 19:45:33.336	luup_log:27: Arduino: id #230: TRUE <0x77383520>
    50	12/27/16 19:45:33.336	luup_log:27: Arduino: id #231: TRUE <0x77383520>
    50	12/27/16 19:45:33.336	luup_log:27: Arduino: id #232: TRUE <0x77383520>
    50	12/27/16 19:45:33.336	luup_log:27: Arduino: id #233: TRUE <0x77383520>
    50	12/27/16 19:45:33.337	luup_log:27: Arduino: id #234: TRUE <0x77383520>
    50	12/27/16 19:45:33.337	luup_log:27: Arduino: id #235: TRUE <0x77383520>
    50	12/27/16 19:45:33.337	luup_log:27: Arduino: id #236: TRUE <0x77383520>
    50	12/27/16 19:45:33.337	luup_log:27: Arduino: id #237: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #238: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #239: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #240: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #241: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #242: TRUE <0x77383520>
    50	12/27/16 19:45:33.338	luup_log:27: Arduino: id #243: TRUE <0x77383520>
    50	12/27/16 19:45:33.339	luup_log:27: Arduino: id #244: TRUE <0x77383520>
    50	12/27/16 19:45:33.339	luup_log:27: Arduino: id #245: TRUE <0x77383520>
    50	12/27/16 19:45:33.339	luup_log:27: Arduino: id #246: TRUE <0x77383520>
    50	12/27/16 19:45:33.339	luup_log:27: Arduino: id #247: TRUE <0x77383520>
    50	12/27/16 19:45:33.339	luup_log:27: Arduino: id #248: TRUE <0x77383520>
    50	12/27/16 19:45:33.340	luup_log:27: Arduino: id #249: TRUE <0x77383520>
    50	12/27/16 19:45:33.340	luup_log:27: Arduino: id #250: TRUE <0x77383520>
    50	12/27/16 19:45:33.340	luup_log:27: Arduino: id #251: TRUE <0x77383520>
    50	12/27/16 19:45:33.340	luup_log:27: Arduino: id #252: TRUE <0x77383520>
    50	12/27/16 19:45:33.340	luup_log:27: Arduino: id #253: TRUE <0x77383520>
    50	12/27/16 19:45:33.341	luup_log:27: Arduino: id #254: TRUE <0x77383520>
    50	12/27/16 19:45:33.341	luup_log:27: Arduino: id #255: TRUE <0x77383520>
    50	12/27/16 19:45:33.342	luup_log:27: Arduino: Sending: 0;0;3;0;2;Get Version <0x77383520>
    50	12/27/16 19:45:36.719	luup_log:27: Arduino: Log: TSP:MSG:READ 255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0: <0x74183520>
    50	12/27/16 19:45:36.721	luup_log:27: Arduino: Log: TSP:MSG:BC <0x74183520>
    50	12/27/16 19:45:36.724	luup_log:27: Arduino: Log: TSP:MSG:FPAR REQ (sender=255) <0x74183520>
    50	12/27/16 19:45:36.727	luup_log:27: Arduino: Log: TSP:CHKUPL:OK <0x74183520>
    50	12/27/16 19:45:36.729	luup_log:27: Arduino: Log: TSP:MSG:GWL OK <0x74183520>
    50	12/27/16 19:45:37.738	luup_log:27: Arduino: Log: TSP:MSG:SEND 0-0-255-255 s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=bc:0 <0x74183520>
    


  • OK, here is another code change I did for testing. I added some logging to the nextAvailableRadioId() method which when I ran it brought up some questions in my head. Here is the code:

    local function nextAvailiableRadioId()
    	for i=1,255 do 
    		if (availableIds[i] == true) then
    			availableIds[i] = false
    			log("Setting next available radio ID to " .. i)
    			return i
    		end
    	end
    
    	log("No available IDs")
    	return 255
    end
    

    I started the luup engine with the node powered off (battery disconnected). I waited a bit for the engine to initialize and then plugged in the battery. Below is the log as I see it with some annotations:
    0_1482904200466_upload-76e2a0fe-d517-45bf-b92e-f325cd17c7d3
    If any of the annotations in the screen shot are incorrect, please correct me. Now for my questions:

    • Shouldn't the nextAvailiableRadioId() method only be called when in inclusion mode? Clearly there were a few requests which tried to assign out IDs prior to my starting inclusion.
    • It appears that the node is not responding to the node ID response. What should I see in the serial monitor from the debug information in the node debug log to tell if it receives the response and if it responds back?
    • If a node doesn't respond back that it accepted that node ID, should the plugin mark that ID as unavailable? Clearly that is what is happening. Is there even a way to tell if the node responds back saying that it got the ID?
    • Is the availableIds[] array of 255 items only for the MySensors plugin, or is it global to all the plugins?
      I think the main part in this test is that the node is not accepting the ID given to it by Vera. When I ran Domoticz, I had no trouble with ID assignments. The next part though is to see what happens once the node parent ID is accepted and presentation starts. I am wondering if I am going to run into the same issues I ran into when I statically set the node ID.

  • Admin

    nextAvailiableRadioId will be called if an id request comes in (even if inclusion mode is off). The array is not global. It's one array per gatewateway.

    I wonder why https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L299-L307 does not return the first available id in your setup.



  • @hek said:

    I wonder why https://github.com/mysensors/Vera/blob/development/L_Arduino.lua#L299-L307 does not return the first available id in your setup.

    My point was that it DOES in fact return ID 1, which is the first available ID. If you look at my notations on the screen shot next to "Plugged battery in here" you will see it. But when the node doesn't accept that ID it makes another ID request, which then the Vera plugin tries to hand out another ID. Since it already tried to hand out ID 1, it moves on to attempting to hand out ID 2. This also gets no response from the node to accept it. If I leave the node plugged in searching for an ID, the plugin will run through all 255 IDs in the availableIds[] array at which point the nextAvailiableRadioId() method will log "No available IDs" because it had gone through all of the IDs and filled the array with false values. This is what brought up this question:

    • If a node doesn't respond back that it accepted that node ID, should the plugin mark that ID as unavailable? Clearly that is what is happening. Is there even a way to tell if the node responds back saying that it got the ID?

    The way I see it, if the node does an ID request and the plugin tries to hand one out but the node does not respond that it accepted it (for whatever reason), the plugin should notify the user that there was a request that wasn't accepted. And that is why I asked this question:

    • It appears that the node is not responding to the node ID response. What should I see in the serial monitor from the debug information in the node debug log to tell if it receives the response and if it responds back?

    Knowing the answer to that will help with what I think should be the next logical step, and that is to figure out if the node receives the ID handed to it by the Vera plugin and if so, is the node processing it correctly.


  • Admin

    There is no special command for accepting an id. The node normally stops asking after receiving one.

    Yes, somehow the gateway have problem transmitting the node id. Do you have capacitor mounted on the gw-radio?



  • When I first set up the gateway for Domoticz I had a standard nRF24L01+ radio. for that I had a 4.7uf cap mounted on the newbie PCB. I later switched it with a NRF24L01+PA+LNA that I had from another node project and that had a 10uf cap mounted across the power rails right on the radio. This whole setup worked perfectly in Donoticz. Domoticz handed out the IDs fine. The node I am testing was added to my Domoticz setup after switching to the PA+LNA radio. Here is an image of my Vera setup.
    0_1482941469652_upload-d7bc840e-10f8-4ed6-9512-7e09f818ecc0
    If you look at the gateway board, you can see the caps. One is purple and mounted to the PCB next to the radio connector. The other one is black and mounted on top of the radio. Since parallel capacitance adds, that should be about 14.7uf of capacitance at the radio.

    What should I see in the serial monitor on the node when the gateway responds?


  • Admin

    You should see 255;255;3;0;4;<new node id>



  • I will check that in a few minutes.



  • I meant what should I see in the serial monitor? This is what is being reported:

    TSM:INIT
    TSM:RADIO:OK
    TSM:FPAR
    TSP:MSG:SEND 255-255-255-255 s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=bc:
    TSP:MSG:READ 0-0-255 s=255,c=3,t=8,pt=1,l=1,sg=0:0
    TSP:MSG:FPAR RES (ID=0, dist=0)
    TSP:MSG:PAR OK (ID=0, dist=1)
    TSM:FPAR:OK
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    TSM:ID
    TSP:MSG:SEND 255-255-0-0 s=255,c=3,t=3,pt=0,l=0,sg=0,ft=0,st=ok:
    !TSM:CHKID:FAIL (ID=255)
    !TSM:FAILURE
    TSM:PDT
    

    I am guessing I should see something like "TSP:MSG:READ..."


  • Admin

    Yes, it is a "read" for incoming data.



  • @dbemowsk said:

    TSP:MSG:READ 0-0-255 s=255,c=3,t=8,pt=1,l=1,sg=0:0

    I know there is somewhere that explains this format seen in the serial monitor, but I can't remember where. The serial API message structure page explains the format that you referred to (255;255;3;0;4;<new node id>), but I need to understand what the s, c, pt, l , sg, ft and st all mean, as well as other information seen in the serial monitor.


  • Admin



  • Perfect, thanks. Exactly what I was looking for. Just couldn't remember where it was.



  • Just a note. The debug page explains s, c, p, pt, l and sg, but it doesn't explain ft and st. I would assume that an st=ok means that the transmission was successful, but unsure on what ft is. maybe that could be added to the troubleshooting page.

    EDIT: my appologies, I see it on the transport messages page.



  • I still do not have this working. Here is a list of things I have tried

    • having the sensor right next to the gateway
    • changed radios on the gateway
    • changed capacitor on the gateway from a 4.7uf to a 47uf
    • changed radios on the sensor
    • cleared eeprom several times and tried pairing
    • tried pairing 2 different sensors (both which worked with Domoticz)
    • tried both the development and standard UI7 versions of the plugin

    One of the things that I have not tried as of yet is changing the USB FTDI adapter. I am pretty sure I have a spare in the parts box. IF not, I will try the one that I use for programming my sensors. I will also test the FTDI I have connected to Vera for programming my sensors to see if it can do that.



  • So it appears that the saga has been solved. The problem in fact WAS with the FTDI adapter. In all of the testing that I did I am guessing that the FTDI's receive data was working, but the transmit data was the issue. I put my spare FTDI on and Vera was detecting devices left and right. I think I am going to have to redo the inclusion because it said that there were 5 devices found, but nothing was added to Vera, but like I say, the devices did not appear to be presenting at the time.

    I want to say though that I appreciate all the time that people spent trying to help me get this going. This forum is a GREAT crowd of people.


 

Suggested Topics

295
Online

7.5k
Users

8.4k
Topics

90.4k
Posts