Author Topic: Trouble installing openLUUP  (Read 2080 times)

Offline flaquito

  • Jr. Member
  • **
  • Posts: 78
  • Karma: +5/-0
Re: Trouble installing openLUUP
« Reply #15 on: May 16, 2018, 06:06:47 pm »
It's there, but empty:

Code: [Select]
      "id":7,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"PluginConfig"

What should it be?

Edit: and how do I change it, if need be?

Offline jswim788

  • Hero Member
  • *****
  • Posts: 788
  • Karma: +57/-2
Re: Trouble installing openLUUP
« Reply #16 on: May 16, 2018, 06:27:07 pm »
It has to be valid JSON, but perhaps it can be minimal: "{}".

You can edit it by stopping openLuup, edit the file (save a copy first!), then start up openLuup.

The bigger question that I'm worried about is why didn't this get set properly initially and what problems will you hit after this?  I'm worried that there are other issues because something went wrong earlier.  But I don't know what that it is, so maybe try this and see what you hit next...

I'm not familiar with the initial installation flow in openLuup with AltUI.

Offline flaquito

  • Jr. Member
  • **
  • Posts: 78
  • Karma: +5/-0
Re: Trouble installing openLUUP
« Reply #17 on: May 16, 2018, 07:03:30 pm »
That seems to have done it! System is up and running, and I haven't gotten any more errors (although I can't get the bridge plugin to clone my vera, but that's an issue for another thread). Thanks for your help!

Offline jswim788

  • Hero Member
  • *****
  • Posts: 788
  • Karma: +57/-2
Re: Trouble installing openLUUP
« Reply #18 on: May 16, 2018, 07:19:44 pm »
amg0, any idea why this isn't set?  Looks like getDefaultConfig didn't get called?  Something went wrong in initialization of AltUI.

Offline amg0

  • Master Member
  • *******
  • Posts: 3028
  • Karma: +204/-8
Re: Trouble installing openLUUP
« Reply #19 on: May 17, 2018, 12:47:05 am »
amg0, any idea why this isn't set?  Looks like getDefaultConfig didn't get called?  Something went wrong in initialization of AltUI.
No . I ll have a look but it should be fine now.
To be sure flaquito can you share the whole device variable list and values ( same http call as you used earlier )

Offline flaquito

  • Jr. Member
  • **
  • Posts: 78
  • Karma: +5/-0
Re: Trouble installing openLUUP
« Reply #20 on: May 17, 2018, 10:04:35 am »
Here you go. Pretty much the only thing I've done so far is add my Vera.

Code: [Select]
{
  "DataVersion":515043756,
  "Device_Num_3":{
    "Jobs":[],
    "PendingJobs":0,
    "id":3,
    "states":[{
      "id":48,
      "service":"urn:micasaverde-com:serviceId:HaDevice1",
      "value":"0",
      "variable":"CommFailureTime"
    },{
      "id":47,
      "service":"urn:micasaverde-com:serviceId:HaDevice1",
      "value":"0",
      "variable":"CommFailure"
    },{
      "id":24,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ThemeCSS"
    },{
      "id":0,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"Present"
    },{
      "id":34,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"WorkflowsVariableBag"
    },{
      "id":8,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"DeviceType"
    },{
      "id":12,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"DeviceIconFunc"
    },{
      "id":3,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"WorkflowMode"
    },{
      "id":14,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"FavoriteFunc"
    },{
      "id":6,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"Result"
    },{
      "id":30,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ALTUIPath"
    },{
      "id":28,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"{\"ShowMyHomeImages\":\"MQ==\",\"UseMasonryInMyHome\":\"MA==\",\"ShowVideoThumbnail\":\"MQ==\",\"ShowWeather\":\"MQ==\",\"ShowHouseMode\":\"MQ==\",\"ServerSideOptions\":\"MA==\",\"UseVeraFavorites\":\"MA==\",\"SyncLastRoom\":\"MQ==\",\"StickyFooter\":\"MA==\",\"UseUI7Heater\":\"MA==\",\"ShowAllRows\":\"MA==\",\"LockFavoritePosition\":\"MA==\",\"TopStats\":\"MA==\",\"Menu2ColumnLimit\":\"MTU=\",\"TempUnitOverride\":\"Zg==\",\"EditorFontSize\":\"MTI=\",\"Theme\":\"\",\"MainUser\":\"OTU0Yzk3M2YtYTM0OS00Y2NjLTlkYjAtZGY2OTRmNzNmY2Q0\",\"FavoritesOrder\":\"bWV0ZW8saG91c2Vtb2Rl\"}",
      "variable":"ServerOptions"
    },{
      "id":16,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"JsonParameters"
    },{
      "id":29,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"LocalCDN"
    },{
      "id":13,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ControlPanelFunc"
    },{
      "id":50,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"/favicon.ico",
      "variable":"FavIcon"
    },{
      "id":10,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"DeviceDrawFunc"
    },{
      "id":18,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"Volume"
    },{
      "id":42,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"[]",
      "variable":"Timers"
    },{
      "id":45,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"VariablesToSend"
    },{
      "id":44,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"VariablesToWatch"
    },{
      "id":2,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"\"0-0\"",
      "variable":"WorkflowAltuiid"
    },{
      "id":46,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"RemoteVariablesToWatch"
    },{
      "id":41,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"GoogleLastError"
    },{
      "id":23,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"https://hirwatech.com/veralogin/Veralogin.php",
      "variable":"RemoteAccess"
    },{
      "id":40,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"EnableMachineLearning"
    },{
      "id":39,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"PendingReset"
    },{
      "id":22,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"/data_request?id=lr_ALTUI_Handler&command=home",
      "variable":"LocalHome"
    },{
      "id":4,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"\"\"",
      "variable":"TransitionId"
    },{
      "id":25,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ImagePath"
    },{
      "id":19,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"groupDevices"
    },{
      "id":26,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"BackgroundImg"
    },{
      "id":5,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"Url"
    },{
      "id":37,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"[]",
      "variable":"Data_CustomPages_0"
    },{
      "id":21,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"v2.26",
      "variable":"Version"
    },{
      "id":35,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"1500,60",
      "variable":"CtrlOptions"
    },{
      "id":33,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"[]",
      "variable":"WorkflowsActiveState"
    },{
      "id":1,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"Debug"
    },{
      "id":32,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"0",
      "variable":"EnableWorkflows"
    },{
      "id":49,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"3.3.1",
      "variable":"SWVersion"
    },{
      "id":31,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"LocalBootstrap"
    },{
      "id":43,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"{\"Vera@192.168.20.112\":{\"url\":\"http://127.0.0.1:3480/data_request?id=lr_HTTP_VeraBridgeMirror_192.168.20.112\",\"callback\":\"\",\"parameters\":[{\"key\":\"mirror\",\"type\":\"text\",\"default\":\"device.serviceId.name\",\"label\":\"Mirror\"}]},\"IFTTT\":{\"url\":\"\",\"callback\":\"sendValueToStorage_ifttt\",\"parameters\":[{\"type\":\"text\",\"key\":\"webhookkey\",\"label\":\"Web Hook Key\"},{\"default\":\"vera_data_published\",\"type\":\"text\",\"key\":\"eventname\",\"label\":\"Hook Event Name\"}]},\"emoncms\":{\"url\":\"\",\"callback\":\"sendValueToStorage_emoncms\",\"parameters\":[{\"default\":1,\"type\":\"number\",\"key\":\"nodeid\",\"label\":\"Node ID\"},{\"type\":\"number\",\"key\":\"feedid\",\"label\":\"Feed ID\"},{\"type\":\"text\",\"key\":\"inputkey\",\"label\":\"Input Key name\"},{\"type\":\"text\",\"key\":\"readwritekey\",\"label\":\"Read/Write API Key\"},{\"type\":\"url\",\"key\":\"graphicurl\",\"label\":\"Graphic Url\",\"ifheight\":460,\"default\":\"http://emoncms.org/vis/realtime?feedid={1}&embed=1&apikey={3}\"}]},\"thingspeak\":{\"url\":\"\",\"callback\":\"sendValueToStorage_thingspeak\",\"parameters\":[{\"type\":\"number\",\"key\":\"channelid\",\"label\":\"Channel ID\"},{\"type\":\"text\",\"key\":\"readkey\",\"label\":\"Read API Key\"},{\"type\":\"text\",\"key\":\"writekey\",\"label\":\"Write API Key\"},{\"default\":1,\"type\":\"number\",\"key\":\"fieldnum\",\"label\":\"Field Number\"},{\"default\":\"//api.thingspeak.com/channels/{0}/charts/{3}?key={1}&width=450&height=260&results=60&dynamic=true\",\"type\":\"url\",\"key\":\"graphicurl\",\"label\":\"Graphic Url\"}]}}",
      "variable":"DataStorageProviders"
    },{
      "id":9,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ScriptFile"
    },{
      "id":17,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"Message"
    },{
      "id":27,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"ExtraController"
    },{
      "id":15,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"Name"
    },{
      "id":38,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"emoncms.org",
      "variable":"EmonCmsUrl"
    },{
      "id":36,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"VoiceRSS_KEY"
    },{
      "id":7,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"{}",
      "variable":"PluginConfig"
    },{
      "id":20,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"true",
      "variable":"UI7Check"
    },{
      "id":11,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"StyleFunc"
    }],
    "status":-1,
    "tooltip":{"display":"0"}
  },
  "LoadTime":1526515010,
  "LocalTime":"2018-05-17 09:57:46 D",
  "Mode":1,
  "TimeStamp":1526565466,
  "UserData_DataVersion":515017916,
  "alerts":[]
}

Offline bruring

  • Jr. Member
  • **
  • Posts: 58
  • Karma: +1/-0
  • Why not automate everything?
Re: Trouble installing openLUUP
« Reply #21 on: May 17, 2018, 11:42:15 am »
Great!

Adding {} in the value field of PluginConfig also worked for me.

Code: [Select]
      "id":7,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"{}",
      "variable":"PluginConfig"

Thanks everyone for helping out.
Trying to make my house smarter than myself since 2012.
Vera Lite & Vera Edge UI7, 15x Fibaro, 10x Aeotec, 6x Zwave.Me, 3x GreenWave, 3x TKBHome, 1x Y-CAM, 1x Netatmo, Logitech Harmony, Google Home. ESXi with pfSense, openLuup, AltUI, Grafana and Vera Concierge amongst others.

Offline bruring

  • Jr. Member
  • **
  • Posts: 58
  • Karma: +1/-0
  • Why not automate everything?
Re: Trouble installing openLUUP
« Reply #22 on: May 20, 2018, 04:25:51 am »
So everything is all up and running. I've used VeraBridge to clone everything from my main Vera to openLuup.

There is a problem though, and I'm not sure if it's originating from openLuup, AltUI or VeraBridge.
All devices and scenes show up. Devices show battery status and other information, pulled from the main Vera.

The devices don't show controls, though. There are no on/off switches or sliders for the dimmers, for example. I've checked the device configuration and dimmers correctly have the device_file D_DimmableLight1.xml.

When I run a scene that changes dimmable lights, it works. I only don't get the controls in the UI. I've tried with different browsers but no luck.
Trying to make my house smarter than myself since 2012.
Vera Lite & Vera Edge UI7, 15x Fibaro, 10x Aeotec, 6x Zwave.Me, 3x GreenWave, 3x TKBHome, 1x Y-CAM, 1x Netatmo, Logitech Harmony, Google Home. ESXi with pfSense, openLuup, AltUI, Grafana and Vera Concierge amongst others.

Offline amg0

  • Master Member
  • *******
  • Posts: 3028
  • Karma: +204/-8
Re: Trouble installing openLUUP
« Reply #23 on: May 20, 2018, 04:32:01 am »
Goto altui device setting panel and press reset button
Plugin config must then be filled with a big json structure.
After that reload LUUP

Also note I am not sure about Vera bridge side effect in case there is also a altui device on the vera.
Between openluup and Vera , make sure you configure the openluup one is openluup is your main controller ( controlleur 0 )

Offline bruring

  • Jr. Member
  • **
  • Posts: 58
  • Karma: +1/-0
  • Why not automate everything?
Re: Trouble installing openLUUP
« Reply #24 on: May 20, 2018, 04:56:21 am »
Hi amg0,

Thanks for helping out. I resetted AltUI, and indeed plugin config got filled with a big json structure.
Then I reloaded LUUP, but this didn't fix the problem.

I've checked the log files, and it seems the device XML file's can't be found (small snippet):
Code: [Select]
2018-05-20 10:54:21.485   openLuup.chdev:: ERROR: unable to read XML file D_SceneController1.xml
2018-05-20 10:54:21.485   luup.create_device:: [10157] D_SceneController1.xml /  /
2018-05-20 10:54:21.485   openLuup.chdev:: ERROR: unable to read XML file D_DimmableLight1.xml
2018-05-20 10:54:21.485   luup.create_device:: [10165] D_DimmableLight1.xml /  /
2018-05-20 10:54:21.485   openLuup.chdev:: ERROR: unable to read XML file D_SceneController1.xml
2018-05-20 10:54:21.485   luup.create_device:: [10170] D_SceneController1.xml /  /
2018-05-20 10:54:21.485   openLuup.chdev:: ERROR: unable to read XML file D_CountdownTimer1.xml
2018-05-20 10:54:21.485   luup.create_device:: [10171] D_CountdownTimer1.xml /  /
2018-05-20 10:54:21.485   openLuup.chdev:: ERROR: unable to read XML file D_CountdownTimer1.xml
2018-05-20 10:54:21.485   luup.create_device:: [10172] D_CountdownTimer1.xml /  /
2018-05-20 10:54:21.486   openLuup.chdev:: ERROR: unable to read XML file D_Siren1.xml
2018-05-20 10:54:21.486   luup.create_device:: [10173] D_Siren1.xml /  /

Edit: also, I don't have altUI running on my main Vera.

Edit 2: After choosing "download files" in the VeraBridge plugin, the /files directory got propagated with all the device xml files. Everything is working now!
« Last Edit: May 20, 2018, 06:09:30 am by bruring »
Trying to make my house smarter than myself since 2012.
Vera Lite & Vera Edge UI7, 15x Fibaro, 10x Aeotec, 6x Zwave.Me, 3x GreenWave, 3x TKBHome, 1x Y-CAM, 1x Netatmo, Logitech Harmony, Google Home. ESXi with pfSense, openLuup, AltUI, Grafana and Vera Concierge amongst others.

Offline parkerc

  • Sr. Hero Member
  • ******
  • Posts: 2461
  • Karma: +35/-48
  • Life Moves Pretty Fast....
Re: Trouble installing openLUUP
« Reply #25 on: May 24, 2018, 03:58:14 pm »
Hi

Just installed openLuup on Debian 9, and I get the same error mentioned earlier when I access it via 192.168.1.122:3480/data_request?id=lr_ALTUI_Handler&command=home%23

Code: [Select]
error in callback [lr_ALTUI_Handler] : [string "L_ALTUI.lua"]:2306: attempt to index local 'tbl' (a nil value
Please can someone confirm exactly what file in /cmd_ludl/ I need to edit (to add {} etc.) as I can see that is not present via 192.168.1.122:3480/data_request?id=status&output_format=xml&DeviceNum=3

Code: [Select]
    },{
      "id":7,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"",
      "variable":"PluginConfig"
    },{
« Last Edit: May 24, 2018, 04:04:14 pm by parkerc »

Offline jswim788

  • Hero Member
  • *****
  • Posts: 788
  • Karma: +57/-2
Re: Trouble installing openLUUP
« Reply #26 on: May 24, 2018, 04:37:15 pm »
1) stop openLuup
2) edit user_data.json and update the value below (save a copy before editing):
Code: [Select]
      "id":7,
      "service":"urn:upnp-org:serviceId:altui1",
      "value":"{}",
      "variable":"PluginConfig"
3) start up openLuup

Offline rafale77

  • Hero Member
  • *****
  • Posts: 1247
  • Karma: +62/-23
Re: Trouble installing openLUUP
« Reply #27 on: May 24, 2018, 04:49:16 pm »
I found the trouble spot. in the userdata.lua file, in the device_table function:

edit the line:

Code: [Select]
        value = item.value or {},
I will submit to akbooer on github
« Last Edit: May 24, 2018, 05:04:09 pm by rafale77 »
openLuup (97 devices, 134 scenes, 20 apps) controlling HomeAss + VeraPlus (138 zwave nodes, 8 Zigbee nodes, 205 devices, 20 scenes , 2 app) Bridged to Homekit and Alexa. VeraPlus ExtRooted!

Offline parkerc

  • Sr. Hero Member
  • ******
  • Posts: 2461
  • Karma: +35/-48
  • Life Moves Pretty Fast....
Re: Trouble installing openLUUP
« Reply #28 on: May 24, 2018, 05:15:50 pm »
Thanks all

Some quick questions

How do I stop/start openLuup, when I can?t access the UI?
@rafale77 My userdata.lua file only has 617 lines?
I found the trouble spot. in the userdata.lua file, in the device_table function:

edit the line:

Code: [Select]
        value = item.value or {},
I will submit to akbooer on github

Offline jswim788

  • Hero Member
  • *****
  • Posts: 788
  • Karma: +57/-2
Re: Trouble installing openLUUP
« Reply #29 on: May 24, 2018, 05:27:02 pm »
This will stop it:
Code: [Select]
http://127.0.0.1:3480/data_request?id=exit(Change IP if not local.)  Start it just as you did initially.