1

I initially asked about a way to use grep/awk directly from an HTML file. I got some feedback but I see that people did not have the whole HTML and so the solutions suggested failed.

Some have mentioned that HTML parsing would be a much better option. I work on Raspberry Pi with standard Linux/Debian Wheezy.

The HTML mentioned is found here, simple HTML...but I guess it's important to see the whole file to be able to help:

https://www.dropbox.com/s/9jdgzen2hwjxhjp/main.htm

So what is required is to:

  • Extract the two values, Pplus and Pminus (18.0000 and 0.00000) and provide them, plus providing the SUM.
  • Both values come from a smart meter (energy meter) that provides the energy generated P- and energy/power taken from the network P+.
  • P- in case of sun and solar plant working, so 18W is at night, 0.0000 means no generation as no sun, just to give you some background information.

I tried to update and ask for support in the original thread but seems that nobody's seen it again since there hasn't been any new feedback the last few days. This is my attempt now to bring this back to the experts here.

3
  • @jasonwryan - but the OP wants to use "other means" instead of grep or awk.
    – slm
    CommentedJun 28, 2014 at 23:37
  • 1
    @slm Yes, I saw that. OP's issue is the same, though. Rather than open a new question, they should edit the original and include sufficient input data for people to suggest viable solutions. This is death by a thousand cuts (well, two anyway)...CommentedJun 29, 2014 at 0:11
  • @jasonwryan - very true, well said....
    – slm
    CommentedJun 29, 2014 at 0:16

1 Answer 1

0

Looking at this sample HTML file:

<DIV ID="idButtonDiv" STYLE="top:143px; left:0px;" ALIGN="CENTER"> <TABLE CELLSPACING="0" CELLPADDING="0" BORDER="0"><TR><TD ID="idButtonTd"> 18.000 </TD></TR></TABLE> </DIV> 

It doesn't appear that this would be easily parse-able.

1
  • why not parse-able?
    – Thufir
    CommentedSep 7, 2017 at 0:06

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.