Fix speed display in energy graph

I will admit that the idiotic number versus string confusion in javascript
really drives me angry. I am now trying to go out of my way to avoid
implicit conversions by making them explicit and hoping that the variables
don't suddenly change type on me again.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Only load new page if date range is non-empty

There is no point to loading a new page if from is after to, so let's just
not do it.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Draw points as well as lines for average consumption

Otherwise in single day mode you can't see the value.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add tooltip to SOC chart

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add cumulative energy used / regen to energy chart

This shows is the explanation below the graph how much energy was spent
and how much energy was regenerated. Seems like interesting data to me.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
More integer vs. string confusion

This caused the map application to occasionally draw lines to and from GPS
(0,0) (the ocean West of central Africa). Oops.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Merge pull request #31 from dirkhh/moreFixes

More fixes
zzz mode fix
Get started on a trip tracker page

So far this is just a static ugly html page that gets sent to the browser.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Trip page: hook up start/stop function and create server backend

Add a new AJAX call for a single data array at a specific time and acquire
that data when the start/stop button is pressed.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Deal with variable scope and start/stop confusion

It still doesn't update the button text correctly, but at least now it
correctly registers start / stop and retrieves the data.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Fixed silly bug using jQuery to change button text

Now the button text changes.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Use callbacks instead of trying to return data from getData

This is javascript, not C...

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Disable the cost display - this isn't enabled on the back end

This is still missing the actual "storing of the named trip", but at least
it's a useful proof of concept.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add rated range to the SOC chart

Rated range actually has higer resolution (chargeState call gets us tenths
of a mile, so that's about half a permille resolution compared to one
percent resolution on the SOC - kind of sad that we can't get higher
resolution SOC).

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Make the marker flicker slightly less annoying

But it's still rather bad when the car is moving fast. This needs to be
solved differently, I think. Maybe this would be better with an overlay?

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
respect -p argument