Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details

If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.

SunTracker - with moving ghost

Questions and comments specific to a particular plugin should go here.
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: SunTracker - with moving ghost

Post by Pako »

Dear Walter!
Very soon I will be releasing a new version of EventGhost.
Some of your plugins are included in the installation file too.
For example SunTracker. I can to include the latest version (ie 1.5.4 beta 1)?
And what about other plugins?

Best regards, Pako
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Dear Pako,
Thanks for reminding me,
Can you allow me to update until tomorrow afternoon latest? I will then see to that the latest versions are uploaded and I will provide you with info which ones

Thank you, very best regards
Walter
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: SunTracker - with moving ghost

Post by Pako »

Dear Walter !
krambriw wrote:Can you allow me to update until tomorrow afternoon latest?
Of course, I'll wait.
One more day, it does not matter.

Best regards, Pako
User avatar
Pako
Plugin Developer
Posts: 2294
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: SunTracker - with moving ghost

Post by Pako »

Dear Walter!
I I'm sorry, but I had to throw dirt on you. :wink:
Check out this topic.
I believe that it is clear. Also __ start__ function should have default values ÔÇïÔÇïfor new parameters (as Configure).

Best regards,
Pako
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Dear Pako,

Sorry did not know about this, I will for sure add default in upcoming versions of all my plugins

Thank you for giving me this very important advice,

Best regards, Walter
piert
Experienced User
Posts: 321
Joined: Tue Jun 14, 2011 2:53 pm

Re: SunTracker - with moving ghost

Post by piert »

Walter,

I am planning on updating the suntracker plugin, but it insists that I disable all instances where I am using the suntracker plugin.

Unfortunately, I have used it extensively, including inside many of my Python scripts (e.g. to check whether the sun is up or down when switching on the TV to see if the lights need to be switched on as well, or when I get alarms at night time to switch on outside lights, otherwise not, etc.).
This means that finding all instances where I am using your plugin will be a humongous task!

Isn't there another way of doing this?

Regards,
Perry
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Hi Perry, I think there is

I have myself messed up things from time to time and then I have done direct editing of the xml files. So if you have an existing configuration xml file working with an older version, it is possible to manually edit a new copy that is compatible with the new version of the plugin.

1) Create a new eg configuration only with the new plugin version, in this case SunTracker, and configure it the same as your current configurations
2) Add one action "Start new or control running SunTracker" (you may accept default settings because we just need the structure for the moment)
3) Save and exit EG

Now, open your two configuration xml files in an editor

1) Copy paste and replace the part with the SunTracker plugin definition from the new to the old xml
2) Copy paste the action part you just created next to similar ones in the old xml
3) Compare the formats and you will easily see where/how you need to modify the ones in the old xml (there are some param fields that most likely needs to be added at the end of each line)
4) Search the file for other SunTracker entries (I doubt you need to change any of them)
5) Once done, save xml file, start EG and open the old configuration xml with your new changes and it should work

If you want, you can send me your xml and I can try to update it to the latest version for you (I think pm does not allow attachements but if we exchange email addresses via pm we could sort it out in this way)

Best regards, Walter
piert
Experienced User
Posts: 321
Joined: Tue Jun 14, 2011 2:53 pm

Re: SunTracker - with moving ghost

Post by piert »

Walter,

Thank you very much indeed for the offer to help out. At the moment I have no extra time to spare (even to create the XML files like you suggested), so it will have to wait a bit, at least till after the weekend. If my attempts then fail, I will surely ask for your help, thanks!

Regards,
Perry
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: SunTracker - with moving ghost

Post by TRIROG1 »

hey!

First of all! Great plugin. I'm using it to open and close the shutters on a daily basis.

I read the readme.txt, because all usecases are more or less taken into consideration but i find it hard to understand without a screenshot of a settings window that matches the description in the readme.txt. Could you provide a screen shot with the settings described?

Another thing. While playing around with the settings i'd line to test the
Instead of waiting for the mother nature to change the weather so i can test some settings of the SunTracker, i'd like to change it myself.
What is the variable i can change to manipulate with the weather condition (the one i get when i use print eg.plugins.Suntracker.GetWeatherCondition())?
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Regarding documentation, yes, I think all settings are described in this topic but it is long and a better readme would of course be justified,,,the topic has many pages now and it is sometimes hard to find what you are looking for...

My time is also limited you know...so in the mean time, try the advanced search, it is actually rather good or simply ask the question and we will find an explanation.

Regarding the weather variable

With this python command you can set the update rate (in minutes) and you should set it long enough so that your test has a chance to get executed. For a 50 minutes interval

Code: Select all

eg.plugins.Suntracker.plugin.weatherUpdateRate = 50
Then you can start to elaborate with this python command. As example to set the condition to 'Mostly Cloudy':

Code: Select all

eg.plugins.Suntracker.plugin.currCondition = 'Mostly Cloudy'
You have to use conditions that are 'certified', you find them in the file 'weather_conditions.py' in the SunTracker plugin folder.

Good luck,
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: SunTracker - with moving ghost

Post by TRIROG1 »

Thanks a lot!
I appreciate everything you are doing !
TRIROG1
Posts: 45
Joined: Fri Aug 08, 2014 10:07 pm

Re: SunTracker - with moving ghost

Post by TRIROG1 »

Walter please advise:

I'm using the SunTracker to generate event 20 minutes after sunrise (Suntracker.LowerShutters) and 20 minutes before sunset (Suntracker.RaiseShutters) which lowers (after sunrise) and raises (before sunset) my shutters.

I have discovered a litle problem.
Yesterday there was a severe storm in my area at 22:00. I lowered all of my shutters but there was a short power outage - long enough for the PC running the EG to reset.

After the PC came back online and the EG was started the Suntracker Generated A event (Suntracker.RaiseShutters) and all of my shutters started raising.

I understand that this is a part of the Suntracker functionality but i was wondering if there is a way to have the Suntracker only gerenete this first event when it happens next time e.g. the next day 20 minutes before sunset and not in the middle of the night.

Thanks!
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Hi,
I assume you use the normal action for this where you have defined an offset of -20 minutes?

As I have understood from your description, the automatic function is working as it should, it was only that you made a manual override (you lowered the shutters manually even though the shutters normally would have been raised due to the automatic control)

What is happening is that when you restart the plugin, it will always send out the correct state it is supposed to keep. So in this case, you got the situation that the automatic adjusted the state back to the expected.

It is also they way I have made the logic and it will not be something I would like to change. If possible, we should try to solve it in a different way.

One possibility I am thinking of is to sequentially enable/disable the macros for the automatic function in such a way so that ones "raised", the next possible can only be "lowered"...

It is an interesting case, a bit advanced to begin, but with the flexibility of EventGhost, I think the following should work for you:
Image2.jpg
Image2.jpg (16.62 KiB) Viewed 6899 times
To save the actual settings so that it will be persistent and 'survive' a restart, each macro includes also the python command eg.document.Save()

Every time SunTracker generates an event that matches, the corresponding macro is executed and disables itself, enables the macro for the reverse operation and saves the changed configuration (to recover correctly from any kind of EG or PC restart)

Best regards, Walter
thahim
Posts: 17
Joined: Fri Jul 11, 2014 5:33 am

Re: SunTracker - with moving ghost

Post by thahim »

@krambriw Kindly tell me how to setup the plugin for my location and how to make it work.
EventGhost Version 0.4.1.r1669
Windows 7
krambriw
Plugin Developer
Posts: 2570
Joined: Sat Jun 30, 2007 2:51 pm
Location: Stockholm, Sweden
Contact:

Re: SunTracker - with moving ghost

Post by krambriw »

Dear Thahim, sure I will do,

Have you added the SunTracker plugin to your configuration?

If so, first thing you will see is a configuration view. To help you configure it you can tell me,
- what is your location (where do you live, in what country and city), this is needed to get as precise weather information as possible
- your geo references (longitud lattitude), this is needed to calculate correct sunrise and sunset in your location.

This is needed for the starting point of the configuration. There are other settings in the view as well, we will discuss them if unclear but you can also look at my sample below to get a better understanding of those. I hope that you also have found and read the readme file that is included in the SunTracker plugin folder? This will give you a little introduction to the purpose and functionality (some features that have been added later are not covered but we can discuss and explain when needed).

As event prefix, I recommend you to use 'SunTracker' instead of 'Main' as shown in my example below.

Once we are done with this configuration, we will only have the basic plugin up and running. We will then discuss the various actions that are available in the plugin.

My config looks like in the picture below:
Image3.jpg
Post Reply