I know we have lul_device, and searching the fora makes me think we don’t have lul_settings (or whatever it is). How about access to the luup_devices table? In my I-file, I’m initializing a local table of strings, indexed by device description. This makes the code easier for me to maintain. If need be, I can make the indices lul_device, but would prefer not.
Is the luup_devices table available in device startup and other I-file functions, or just in actions/jobs?
And 100 pardons if this shows up twice…I thought I had posted it before, but see no evidence that the post went anywhere.
–Richard
Of course, I meant luup.devices.
[quote=“rlmalisz, post:1, topic:186520”]I know we have lul_device, and searching the fora makes me think we don’t have lul_settings (or whatever it is). How about access to the luup_devices table? In my I-file, I’m initializing a local table of strings, indexed by device description. This makes the code easier for me to maintain. If need be, I can make the indices lul_device, but would prefer not.
Is the luup_devices table available in device startup and other I-file functions, or just in actions/jobs?
And 100 pardons if this shows up twice…I thought I had posted it before, but see no evidence that the post went anywhere.
–Richard[/quote]
The variable lul_device is provided during initialization and also during action calls. The table lul_settings is only provided for action calls.
While these variables are magically provided at the points where your code is entered, that does not mean that they are valid everywhere. If you want to use them in a function, pass them as arguments from the original entry point.
The variable luup.devices and all the other luup variables and functions are available at any point in your code.
Thank you very much.
–Richard
[quote=“RexBeckett, post:3, topic:186520”]The variable lul_device is provided during initialization and also during action calls. The table lul_settings is only provided for action calls.
While these variables are magically provided at the points where your code is entered, that does not mean that they are valid everywhere. If you want to use them in a function, pass them as arguments from the original entry point.
The variable luup.devices and all the other luup variables and functions are available at any point in your code.[/quote]