Create Infolabel (or modify existing one)
#1
I want to repeatedly change a infolabel using my script.
And use this to display text on my LCD/VFD screen.

Best would be to create a new infolabel, but i will probably be easyer to
change the content of an unused infolabel (e.g. Weather.Conditions or AudioScrobbler.ConnectState)

Anyone have a simple example for creating a label to be used in XBMC ?

I've tried code below, but without result ...
titel = 'Newlabel.test'
line = 'test infolabel'
listitem = xbmcgui.ListItem(titel, iconImage='img', thumbnailImage='img')
listitem.setInfo('Newlabel', {'test': line} )


Ive been searching a lot .. but can't find the right info ..
http://nullege.com/codes/search/xbmc.getInfoLabel
http://pastebin.com/x8ELs49x
http://xbmc-scripting.googlecode.com/svn.../tvrage.py
Reply
#2
The only thing you can do from python is add a property to a window and retrieve that using Window.Property(foo).
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#3
(2012-06-25, 23:07)jmarshall Wrote: The only thing you can do from python is add a property to a window and retrieve that using Window.Property(foo).

Thanks for your reply Smile

I don't think so .. but can i use this in my .xbmc/userdata/LCD.xml file to display on my VFD ?
since i want to do this while the screensaver is active the Window.Property would be Screensaver.Property() ?

Reply
#4
What exactly do you want to do? Perhaps with more detail someone can suggest a solution.

Yes, the LCD can take any infolabel that XBMC supports. You'd use something like Window(ScreenSaver).Property(foo), assuming your script set a property on the screensaver window.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#5
I'm running XBMCbuntu Eden and i've got an Arduino board witch
has temperature/hygrometer and air pressure sensors attached.

I've found a python library to gather the information from the USB interface on the Arduino
And i would like to have my VFD display this info (two lines) during XBMC-screensaver time
Since XBMC uses infolabels in the LCD.xml configuration the easiest option would be
to use an infolabel for this
Reply
#6
Do you know whether you're in the screensaver in LCD.xml anyway? That's the first obstacle.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#7
(2012-06-26, 01:23)jmarshall Wrote: Do you know whether you're in the screensaver in LCD.xml anyway? That's the first obstacle.

I now use Date and time labels during screensaver time and this works fine
so i recon other infolabels should work as well ..
Config in LCD.xml:
<screensaver>
<line>$INFO[System.Date]</line>
<line>$INFO[System..Time]</line>-->
</screensaver>
Reply
#8
Ok, so next obstacle is generating a script that sets a Window Property. It doesn't matter which window you set it on (eg you could set the property on the Home window and use Window(Home).Property(foo)) in LCD.xml

Cheers,
Jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#9
(2012-06-26, 08:02)jmarshall Wrote: Ok, so next obstacle is generating a script that sets a Window Property. It doesn't matter which window you set it on (eg you could set the property on the Home window and use Window(Home).Property(foo)) in LCD.xml

Since it's weather info i think it would be best to add a property to the "Weather" window

I'm a bit lost here .. can you please give me some directions on how to add a property ?

The "Weather" window has the following property's i would like to set
"Window(Weather).Property(key)"
- Location
- Current.Temperature,
- Current.Humidity

And would be great if i can add a property with
"Window(Weather).Property(key)"
- Current.AirPressure
- Current.Temperature2
Reply
#10
The same way the existing weather addons work? They're python - take a look at the code.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#11
i am stil clueless HuhHuh
Anyone have a hint for me on where to start ?

The "Weather" window has the following property's i would like to set
"Window(Weather).Property(key)"
- Location
- Current.Temperature,
- Current.Humidity

And would be great if i can add a property with
"Window(Weather).Property(key)"
- Current.AirPressure
- Current.Temperature2
Reply

Logout Mark Read Team Forum Stats Members Help
Create Infolabel (or modify existing one)0