×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Weather SImulator

  • Posts: 112
  • Thank you received: 9

Weather SImulator was created by kamisan

The Weather Simulator offers an input control for "Weather".
It accepts only two values: 0 or 1.

How do I modify it to accept a range from 0.00 to 1.00 in steps of 0.01?
My guess is that there is an XML file somewhere that I can tweak. If so can someone tell me the path to the file?

Thank you.
4 years 3 months ago #46801

Please Log in or Create an account to join the conversation.

Replied by Jasem Mutlaq on topic Weather SImulator

I think that value is hard-coded into the driver itself.
4 years 3 months ago #46803

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
You need to modify line 96 in weathersimulator.cpp from
IUFillNumber(&ControlWeatherN[CONTROL_WEATHER], "Weather", "Weather", "%.f", 0, 1, 1, 0);
to
IUFillNumber(&ControlWeatherN[CONTROL_WEATHER], "Weather", "Weather", "%.f", 0, 1, 0.01, 0);
4 years 3 months ago #46825

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

Thank you, Wolfgang.
4 years 3 months ago #46826

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

Wolfgang,

I made the change you suggested above, locally in a VM. Works great! Now I can test some more.

Thanks!
4 years 3 months ago #46879

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

Wolfgang,

I found a bug in the scheduler. You can recreate it offline using the Weather Simulator, CCD Simulator, and Telescope Simulator:

1. Create a simple capture sequence (ESQ): 10 frames at 10 seconds.
2. Create a simple schedule:
a. Locate M35 currently rising in the east this time of year.
b. Select our simple capture sequence.
c. Check: Track, Uncheck all others because we are using the CCD Simulator.
d. Check: Weather.
e. Add the job to the schedule.
3. Go to INDI control panel's Weather Simulator:
a. Set the POLL to 5 seconds.
b. Set WEATHER to 1 (i.e. Danger).
c. Return to the Ekos Scheduler module and wait for the weather icon to light up DANGER.
4. Run the schedule
a. You should see that it begins to run even while the weather is dangerous.
b. Try this to get it to abort while the sequence is running:
A. Change the WEATHER to 0 (OK) and wait a few seconds.
B. Change the WEATHER to 1 (DANGER) again. This time the sequence will abort!

I have a theory as to what is happening but I'll keep it to myself since I have zero experience with INDI programming.
The following user(s) said Thank You: Wolfgang Reissenberger
4 years 3 months ago #46895

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
I have a suspicion, needs to be confirmed. When the scheduler is started, the weather condition is not checked.

I would not be surprised if the scheduler keeks running when started during weather alert status.

Nevertheless, I do not consider this as critical, since you should know what you are doing when starting the scheduler. More critical is when an alert occurs somewhen during the night..
Last edit: 4 years 3 months ago by Wolfgang Reissenberger.
4 years 3 months ago #46938

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

Sure, I understand that there is "critical" and then there is "CRITICAL".

I ran another test which is closer to how I would use it:

I use three forecasting services: Clear Outside, Clear Dark Sky, and College of DuPage Meteorology. Let's say they are in agreement that skies will clear by 2am. The problem is I've got a meeting at 8am. At 10pm I would like to start the scheduler to wake up at 2am, check the weather, continue if clear or abort if cloudy. I tested this scenario. The problem is that the scheduler appears to constantly monitor the weather from 10pm to 2am and prematurely aborts when the weather changes. Like I said I am only really interested at the weather conditions at 2am.
4 years 3 months ago #46953

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
Please take a look at this tread , here is also a discussion ongoing about reacting on weather changes.

As I expected, the scheduler does not consider bad weather at startup - I think that's simply a bug.

Regarding your ideas about checking the weather only during the planned capturing time: hm, are you really sure? Rain on a telescope is always a bad idea, even if it is not capturing. I think we need a general approach for observatory automation with the weather situation so that the observatory goes into a safe position when weather turns bad and starts up as soon as clear sky is back again. But that needs a bunch of work...

- Wolfgang
4 years 3 months ago #46954

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

I'll read that thread, thanks Wolfgang.

>> Rain on a telescope is always a bad idea, even if it is not capturing.

I fully agree. I was thinking ahead to when I have an observatory. In my example I wanted to launch the scheduler at 10pm with the knowledge that the weather is currently wet. My expectation however, according to forecasts, is that it will clear by 2am. So my expectation is that Ekos will keep the observatory sealed. When the job awakens at 2am it will first check the weather and then abort if still raining -- the observatory will remain sealed. In other words, check the weather first and then open the observatory only if the weather is OK, otherwise keep it sealed and abort the remaining jobs in the schedule.
4 years 3 months ago #46956

Please Log in or Create an account to join the conversation.

  • Posts: 112
  • Thank you received: 9

Replied by kamisan on topic Weather SImulator

Maybe I am not understanding something. Does the dome open as soon as I click the "run schedule" button even though I tell it to defer execution of the first job until 2am? If that is the case then I see your point. What I am saying is: open the dome (if it is not already open) upon execution of the first job. I'll have to test some more.
4 years 3 months ago #46957

Please Log in or Create an account to join the conversation.

  • Posts: 1185
  • Thank you received: 370
I tested it with simulators. The done stays closed until the scheduled job is ready. If then weather has alarm status, the scheduler will try to open the dome, but the dome itself refuses to open due to the alarm.
4 years 3 months ago #46963

Please Log in or Create an account to join the conversation.

Time to create page: 0.824 seconds