I'm no programmer, so please bear with me

;
Let me start of by saying I admire the work done. But the description isn't fool proof yet, so I stumbled on some things.
For starters: is it still necessary to create a dummy device? The P1 USB cable I'm using in combination with Domoticz P1 Smart Meter USB shows all the correct data, so I wonder if we can use those data instead of having to create a dummy device?
When I create the dummy device, the data shows "0.000 Kwh".
The the lua scripts:
I didn't see this line, but I did have to install lua separately (sudo apt-get install lua5.2). It wasn't installed yet.
It took a bit of work, but then I did find out that you start the script with "lua <scirpt-name>. What I cannot find is if I need to add a cronjob for this, and how we are going to make it so that it only uploads data from sunrise untill sunset (better yet: 15 minutes before sunrise untill 30 minutes after sunset). I do see that there's a line stating that uploads should take place every 5 minutes.
How can I see if there is a script running in lua? What happens if I start the lua-script several times?
How can I debug the script? I did set DEBUG=YES, but I don't see any output arriving in dmesg. Am I looking in the wrong place?
In /var/log/messages I do get errors though:
Mar 21 16:29:07 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:30:07 2016 [try
http://www.rsyslog.com/e/2007 ]
Mar 21 16:30:08 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:31:08 2016 [try
http://www.rsyslog.com/e/2007 ]
Mar 21 16:31:11 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:32:11 2016 [try
http://www.rsyslog.com/e/2007 ]
Mar 21 16:32:12 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:33:12 2016 [try
http://www.rsyslog.com/e/2007 ]
Mar 21 16:33:17 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:34:17 2016 [try
http://www.rsyslog.com/e/2007 ]
Mar 21 16:34:19 DomoUpload rsyslogd-2007: action 'action 17' suspended, next retry is Mon Mar 21 16:35:19 2016 [try
http://www.rsyslog.com/e/2007 ]
< etc, one every minute >
But I'm not sure if they're even related
When I start the script I get a message:
pi@DomoUpload:~/domoticz/scripts/lua$ lua script_time_upload_to_PVoutput.lua
Time to go before upload to PVoutput: 3 minutes
This sounds wonderful, but no data is collected at PVOutput.
So I'm hoping someone can shed some light onto these newbie-questions, thanks for "listening".