(      DNS,   IP)

### superweatherdaemon ###

 "" (* - ):
-   *
-   *
-   *
-   ( <=5 -> FORCEOFF=1;  >=10 - FORCEOFF=0) 
    : LIGTPWR, LIGTDIST, LIGTTIME
-    (     FORCEOFF=1;      - FORCEOFF=0)
    : POWERED (0 -    , 1 - ) 
- -allsky (   -  " "  " ")
    : CLOUDS, SKYTEMP 

     ""  FORCEOFF ( ==1 - ,   ,
 .. ).

        FORCEOFF. FORCEOFF   WEATHER=3.
 FORCEOFF -   "",    WEATHER.      ,
         .    FORCEOFF,  WEATHER   
.     FORCEOFF,   WEATHER  2. ,    
  2N  (,        )   .

???  "" : LIGTPWR, LIGTDIST, LIGTTIME (,     5,    
 FITS-).

       ,      FORCEOFF.

  UNIX-  :
- forceoff -     / 
- weath -    
- mute/unmute  (   list);   mute,      
- ?



###    (robometeo) ###

 FORCEOFF.  ==1  OFF_T_WAIT ,     5 "":      ,
      ( ).  OFF_T_FORCE       ,
  ,  .   -   .

  , ,    0.    ON_WAIT ,      
  ,  ON_FORCE        .     
  ,    .

    :  OFF_R_WAIT   roboserv, robonas  robostorage;     - 
  .      OFF_R_FORCE .     ON_WAIT ,
       , .

 -: IP-       , , 

telescopes=Astro-M1, Astro-M2...
Astro-M1=192.168.70.33:1:-1  #   telescopes = IP:  :    -1
Astro-M2=192.168.70.35:2:22
...
equipment=roboserv,robonas,robostorage
roboserv=192.168.70.6:11:-1  #     192.168.70.6:-1:11
...

(           ;    , 
   ,   )



### weather proxy ###

  forceoff. 



### Clients ###

    weather_proxy   ,    SHM  .
 ,       /tmp   FITS- (  " " , 
  ).

   WEATHER:
0 -  
1 -  ,    
2 -   ,  ,   
3 -  ,  


##   ##

   WEATHER>1  FORCEOFF=1.


##   ##

   WEATHER>2  FORCEOFF=1.


##   ##

  WEATHER=2  FORCEOFF=1,   WEATHER=3 (  FORCEOFF=1      ).

  HDRTIME // UNIX-time of last activity   ->     sl_dtime()   ( 
 ,  ,   ). 


##      ##

   - .     -  (  
   ,    ,  ). 

  FORCEOFF=1,     .  
 DOMFITSHDR (DOMESTAT= closed), TELFITSHDR (TELSTAT = closed)  MOUNTFITSHDR (HDRTIME    
 30    ).
  ,      ,   -      poweroff.

sync(); // Flush disk buffer to prevent data loss
reboot(RB_POWER_OFF);
 (?): system("shutdown -P now")

