meterN 0.8

Talks about metering
Locked
NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sat Jan 21, 2017 9:48 am

just updated time looks good thanks.


Neville

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sat Jan 21, 2017 11:25 pm

An update to last post.

The timings on the graph are correct BUT the issue I had with the graph itself being incorrect still exits.
My current time is just after 8am on the 22 Jan, the last 24 hour graph shows from midnight to present correctly but the period that is expected to be from 8am yesterday to midnight last night is showing data from the 20th. And the accumulated power and cost is this total not the actual last 24 hrs. Hope this is not too confusing. I noticed this not only because of cost but when I updated software last evening it kept cycling to zero and pulsing back to live power consumption (no solar at this time) and the graph had several dips in it, I rebooted system and everything corrected.
The link below is a folder with screen shots showing what I am seeing.
These links I put in these posts seem to have to be copied and pasted into a web browser to work???

https://goo.gl/Javj1G

The following is a link to my web page

https://goo.gl/MJSeiC

I will be interested to what happens at change of day (UTC) which is in about 1.5 hrs, I will let you know

Neville

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sat Jan 21, 2017 11:38 pm

Just to add both solar and consumption have this display error. It just so happens the 2 days were quite different so makes it easy to see.

Neville

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sun Jan 22, 2017 1:03 am

Just gone 10 am (change of day UTC) and when the page updated the correct graphs are displayed.

Neville

jeanmarc
Posts: 1764
Joined: Thu Aug 29, 2013 7:16 am

Re: meterN 0.8

Post by jeanmarc » Sun Jan 22, 2017 7:58 am

Maybe you have an old instance of metern running. Is it ok now ? :?

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sun Jan 22, 2017 9:23 am

This was after a soft reboot last night so should be only one instance.

I was watching the display as we changed day(UTC +10 hrs) and the display updated as normal and the graphs corrected themselves.

At this moment everything is perfect if you look at my web page you will see this, as I write this consumption data and solar is correct.

I do not know when the fault occurs but possibly midnight local time. If I am awake I will check and let you know.

I am running latest versions 123 and metern.

Neville

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sun Jan 22, 2017 3:32 pm

I missed the exact time (missed my alarm) but it is now 29 mins after midnight (local time) and the graphs are faulty.
I have added a screen shot to my last link and you should see it from my web page.

I first checked at 10pm local as that is midday UTC but graphs OK.

The problem occurs as local time changes day and remains at fault until UTC changes day.

Neville

jeanmarc
Posts: 1764
Joined: Thu Aug 29, 2013 7:16 am

Re: meterN 0.8

Post by jeanmarc » Sun Jan 22, 2017 8:36 pm

Hi,
You don't have to wake up so early ;)

Could you try this test.php

Code: Select all

<?php
date_default_timezone_set('GMT');
$today =  date('Ymd');
$yesterday = date('Ymd', time() - 60 * 60 * 24);

echo "GMT it is $today, yesterday was $yesterday<br>";


$DTZ = 'Australia/Brisbane';
date_default_timezone_set($DTZ);
$today =  date('Ymd');
$yesterday = date('Ymd', time() - 60 * 60 * 24);

echo "$DTZ it is $today, yesterday was $yesterday<br>";
?>
Also return from your terminal :

Code: Select all

[root@i3 ~]# timedatectl 
      Local time: Sun 2017-01-22 20:35:39 CET
  Universal time: Sun 2017-01-22 19:35:39 UTC
        RTC time: Sun 2017-01-22 19:35:39
       Time zone: Europe/Brussels (CET, +0100)
 Network time on: yes
NTP synchronized: yes
RTC in local TZ: no
You may need to [root@plugpc ~]# timedatectl set-timezone Australia/Brisbane

NevD
Posts: 147
Joined: Tue Mar 11, 2014 12:22 am

Re: meterN 0.8

Post by NevD » Sun Jan 22, 2017 10:40 pm

Hi

Result from testDT.php

GMT it is 20170122, yesterday was 20170121
Australia/Brisbane it is 20170123, yesterday was 20170122

I do not seem to have timedatectl

I do have a hwclock here is result from date command and a read of the hwclock

Code: Select all

pi@raspberrypi /lib/systemd/system $  cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 7 (wheezy)"
NAME="Raspbian GNU/Linux"
VERSION_ID="7"
VERSION="7 (wheezy)"
ID=raspbian
ID_LIKE=debian
ANSI_COLOR="1;31"
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
pi@raspberrypi /lib/systemd/system $ date
Monday 23 January  07:33:39 AEST 2017
pi@raspberrypi /lib/systemd/system $ sudo hwclock -r
Mon 23 Jan 2017 07:33:54 AEST  -0.778729 seconds
pi@raspberrypi /lib/systemd/system $ timedatectl
-bash: timedatectl: command not found
pi@raspberrypi /lib/systemd/system $ sudo timedatectl
sudo: timedatectl: command not found
pi@raspberrypi /lib/systemd/system $ 
I have timedatectl on another system (came with package) ??

Neville

jeanmarc
Posts: 1764
Joined: Thu Aug 29, 2013 7:16 am

Re: meterN 0.8

Post by jeanmarc » Mon Jan 23, 2017 7:48 am

Maybe

Code: Select all

jeanmarc@hal:~$ ls -al /etc/localtime 
lrwxrwxrwx 1 root root 37 jan 20 17:47 /etc/localtime -> ../usr/share/zoneinfo/Europe/Brussels
Then set using "tzselect". Check also what happen on test.php when it bug.

Locked

Who is online

Users browsing this forum: No registered users and 1 guest