1

This question already has an answer here:

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.

marked as duplicate by jasonwryan, Ramesh, cuonglm, Braiam, slm Jun 29 '14 at 0:18

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • @jasonwryan - but the OP wants to use "other means" instead of grep or awk. – slm Jun 28 '14 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)... – jasonwryan Jun 29 '14 at 0:11
  • @jasonwryan - very true, well said.... – slm Jun 29 '14 at 0:16
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.

  • why not parse-able? – Thufir Sep 7 '17 at 0:06

Not the answer you're looking for? Browse other questions tagged or ask your own question.