Author Topic: [Release] LH_DataViewer (v1.03)  (Read 26129 times)

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.00)
« Reply #15 on: 2011-01-21 14:27:27 »
Indeed. Which is one reason why I created the dataviewer plugin. Output stuff to a text file and the dataviewer will handle the updates for you, text, bars and images. Soon I'll release a version to do speedometers and graphs.

SirReal

  • Administrator
  • Hero Member
  • *****
  • Posts: 735
    • linkdata.se
Re: [Release] LH_DataViewer (v1.00)
« Reply #16 on: 2011-01-21 14:37:38 »
Indeed. Which is one reason why I created the dataviewer plugin. Output stuff to a text file and the dataviewer will handle the updates for you, text, bars and images. Soon I'll release a version to do speedometers and graphs.

Doh'. Of course.

MDP, you can write a layout class with Lua which controls LH_DataViewer output using a text file. lethys or myself can help you with the Lua parts if needed, and Triscopic has written good documentation for LH_DataViewer (see the first post for a PDF link).
« Last Edit: 2011-01-21 14:40:08 by SirReal »

gap

  • Newbie
  • *
  • Posts: 2
Re: [Release] LH_DataViewer (v1.00)
« Reply #17 on: 2011-02-13 02:03:15 »
Hi, is it possible to read simple source files which are only text seperated by line breaks?

I try to use the ts3speaking.txt generated by ts3 (for testing purposes I just wrote 2 lines of text and also tried seperating with : instead of new line).
But when i insert the filename (../../../../AppData/Roaming/ts3speaking.txt) into Data Source it says "Data file type not yet supported"
In my datamap.txt I only have the [Format] block:
Code: [Select]
[Format]
type=txt
delimited=true
delimeter=:
width=0
singleWrite=true
completeAt=20
dataExpiry=10

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.00)
« Reply #18 on: 2011-02-16 17:27:28 »
It should be possible. I'm busy at the moment with Cursor object & menus, but DataView is next in my to-work-on queue and I'll look into why you can't get it to work then. I've got a number changes lined up which should make the dataviewer (a bit) easier to work with.

Can you post the data file here too?

gap

  • Newbie
  • *
  • Posts: 2
Re: [Release] LH_DataViewer (v1.00)
« Reply #19 on: 2011-02-17 18:44:03 »
[...]
Can you post the data file here too?

Do you mean the Data Source? As said it's just a simple text. for testing i tried something like
Code: [Select]
testname1
testname2
as well as
Code: [Select]
testname1:testname2

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.00)
« Reply #20 on: 2011-02-18 18:56:08 »
Ok, the Format block should be fine.

But you must include the [Definitions] block - this is what tells the plugin in what data to pull out of the source file.

Try this:
Code: [Select]
[Definitions]
Item0 1,1
Item1 2,1

That will tell the plugin to take the first value on line 1 and call it "Item0" and the first item on line 2 and call it "Item1", i.e. this will work for:
Code: [Select]
testname1
testname2

For this example:
Code: [Select]
testname1:testname2you would need
Code: [Select]
[Definitions]
Item0 1,1
Item1 1,2
i.e. the first and second items on line one.

Once you add this to the file you can assign the data source and the data map and then add a data text object and set the template value to {0} and it will pull in testname1

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.01)
« Reply #21 on: 2011-02-19 20:14:11 »
Release Notes:

Updated to 1.01:
  • Fixed bug where status was always "Unable to connect"
  • Fixed bug displaying extended characters
  • Added multi-lingual support for lists (for example, add lists.RU.txt, copy in the list blocks and translate them)

Note that due to a bug in A14, the multilingual support requires you to reload the layout if LCDHost opens with it already open. This bug is has already been fixed in A15.



EDIT: Not making a new post as this was released with A15, but things were hectic and I never got round to updating the change log...
Release Notes:

Updated to 1.02:
  • Implemented a new way to reference data, via keywords instead of numbers (Sepa's idea). Makes managing data MUCH easier
  • remove shared memory
  • added dials
  • Added loading of data in directly from the data source without using a template file
« Last Edit: 2011-04-23 17:40:03 by Triscopic »

cgrinds

  • Newbie
  • *
  • Posts: 22
Re: [Release] LH_DataViewer (v1.02)
« Reply #22 on: 2011-05-04 08:11:14 »
I am having trouble getting the mappings right, it's just not updating like I expect (at all?).  It looks like the data that is shown via the plugin isn't the most recent from the output file from the app.

I'm also not sure I have the formats right, the documentation seems to be missing details on the definitions.

Here's a sample of the raw data I have:
Code: [Select]
06:09:55: ( 3 , T=P#R=C#222646706605584201 , T=N#R=O#9223372040008898815 , T=X#R=X#0 , T=X#R=X#0 , Ciegrayndez , Boss Practice Dummy , 34 , 1283573061 , Auto Attack ) Ciegrayndez's Auto Attack hits Boss Practice Dummy for 34 Physical damage.
06:09:56: ( 3 , T=P#R=C#222646706605584201 , T=N#R=O#9223372040008898815 , T=X#R=X#0 , T=X#R=X#0 , Ciegrayndez , Boss Practice Dummy , 198 , 666372164 , Debilitating Strike ) Ciegrayndez's Debilitating Strike hits Boss Practice Dummy for 198 Physical damage.
06:09:56: ( 8 , T=P#R=C#222646706605584201 , T=N#R=O#9223372040008898815 , T=X#R=X#0 , T=X#R=X#0 , Ciegrayndez , Boss Practice Dummy , 0 , 666372164 , Debilitating Strike ) Boss Practice Dummy is afflicted by Ciegrayndez's Debilitating Strike.

I was just trying to show fields from it as an example, Here's my data map:
Code: [Select]
[Format]
type=txt
delimited=true
delimiter=,
singleWrite=true

[Definitions]
Player 5
Target 6
;Last Damage 7 ; this one works!
; Also tried these:
Player 1,6
Target 1,7

Although the data is updated and then I see it in the plugin I don't believe it's the current lines because when I check the source file the data doesn't match what the plugin displayed and it's showing old details.  I also wasn't able to have it pull field 0 for the timestamp.

Not really sure what I'm missing, any advice at all would be helpful here :D

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.02)
« Reply #23 on: 2011-05-04 22:14:03 »
Package up your whole layout with a sample data file and I'll check it out. PM/email me if you want to keep the layout under wraps until it's finished.

cgrinds

  • Newbie
  • *
  • Posts: 22
Re: [Release] LH_DataViewer (v1.02)
« Reply #24 on: 2011-05-05 04:14:02 »
I've tried various combinations of all the options for delimiters (figured I could use spaces and commas?), and also the singleWrite and update options.  This is what I last had when I was working it.

I never seemed to have 'current' data, but it did seem to detect when the file was being updated or not.

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.02)
« Reply #25 on: 2011-05-06 23:28:14 »
Sorry for not getting back sooner, but with A16's deadline hurtling towards us I've been a bit occupied.

Anyway, I see what's going on here...

Firstly v1.02 basically assumes the entire data file is relevant, i.e. it gets completely refreshed and old data is deleted. Currently to make this read from this sort of "log file" that you're working with... well the problem is that row 0 is the first row, row 1 is the second... etc etc and since you don't know what the last number is you can't explicitly access it. Essentially the data file is a CSV file and the data items point to a row & column.

That said, I've managed to find the time to add a small feature to DataViewer v1.03 which will be bundled with A16 that will solve this, allowing you to specify the number of new rows each update adds to the log file, in other words it can ignore all the old lines and just pick up the new data.

Attached is a working layout that requires DataViewer 1.03 in order to work. If you open it with 1.02 (i.e. with A15 still running) it won't be able to pick up the end data and will still show the first item in the log file, but that's ok, when A16 is out that will fix itself. In the mean time you can still play around with the layout and rename the items in the map file.

There are two layouts in here, one uses the documented method of numerical references, the other a new method currently "in-progress" that makes layout building easier by assigning names to data instead of the index-based approach I (stupidly) implemented in 1.00.

Either way works, both are fully supported going forwards, but the new one is likely to be easier to work with going forwards even though I've not got round to documenting it yet.

Triscopic

  • Moderator
  • Hero Member
  • *****
  • Posts: 729
  • ˙ǝıl ɐ sı ǝʞɐɔ ǝɥʇ
Re: [Release] LH_DataViewer (v1.03)
« Reply #26 on: 2011-05-07 09:51:17 »
    Release Notes:

    Updated to 1.03:
    • Added "updatelength" property for files that are appended in a "log file" style by a game or application
    • Fixed bug with uninitialised property values causing strange behaviours
    • Fixed text scrolling


    Available with A16[/list]
    « Last Edit: 2011-05-07 19:07:11 by Triscopic »

    cgrinds

    • Newbie
    • *
    • Posts: 22
    Re: [Release] LH_DataViewer (v1.02)
    « Reply #27 on: 2011-05-07 17:53:18 »
    Sorry for not getting back sooner...

    No worries, I wasn't in a rush and had too much other stuff (mostly work) so couldn't do anything at the time.  This weekend will offer some time.

    I've not got round to documenting it yet

    I am very good with technical documentation, if you need help let me know.

    SirReal

    • Administrator
    • Hero Member
    • *****
    • Posts: 735
      • linkdata.se
    Re: [Release] LH_DataViewer (v1.03)
    « Reply #28 on: 2011-05-07 20:03:41 »
    There's a wiki to fill with your discoveries!

    cgrinds

    • Newbie
    • *
    • Posts: 22
    Re: [Release] LH_DataViewer (v1.02)
    « Reply #29 on: 2011-05-08 01:20:06 »
    Anyway, I see what's going on here...

    I believe you nailed it.  Just running what you returned confirms it's doing what I was expecting to happen.  The screen can't update fast enough to be as useful as I was expecting (1 update/sec max?) but I believe the plugin is keeping up with the log file.

    I think I can still make do with what I need just with some regex.  Thanks for making parenthesis work properly.

    Should enhancements to plugins be requested to the tracker or just here in the plugin's forum?