• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

kstars

indidevapi.h

Go to the documentation of this file.
00001 #if 0
00002     INDI
00003     Copyright (C) 2003 Elwood C. Downey
00004 
00005     This library is free software; you can redistribute it and/or
00006     modify it under the terms of the GNU Lesser General Public
00007     License as published by the Free Software Foundation; either
00008     version 2.1 of the License, or (at your option) any later version.
00009 
00010     This library is distributed in the hope that it will be useful,
00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013     Lesser General Public License for more details.
00014 
00015     You should have received a copy of the GNU Lesser General Public
00016     License along with this library; if not, write to the Free Software
00017     Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
00018 
00019 #endif
00020 
00021 #ifndef INDI_DEVAPI_H
00022 #define INDI_DEVAPI_H
00023 
00044 /*******************************************************************************
00045  * get the data structures
00046  */
00047 
00048 #include "indiapi.h"
00049 
00050 /*******************************************************************************
00051  *******************************************************************************
00052  *
00053  *   Functions the INDI device driver framework defines which the Driver calls
00054  *
00055  *******************************************************************************
00056  *******************************************************************************
00057  */
00058 
00059 #ifdef __cplusplus
00060 extern "C" {
00061 #endif
00062 
00067 
00072 extern void IDDefText (const ITextVectorProperty *t, const char *msg, ...)
00073 #ifdef __GNUC__
00074         __attribute__ ( ( format( printf, 2, 3 ) ) )
00075 #endif
00076 ;
00077 
00082 extern void IDDefNumber (const INumberVectorProperty *n, const char *msg, ...)
00083 #ifdef __GNUC__
00084         __attribute__ ( ( format( printf, 2, 3 ) ) )
00085 #endif
00086 ;
00087 
00092 extern void IDDefSwitch (const ISwitchVectorProperty *s, const char *msg, ...)
00093 #ifdef __GNUC__
00094         __attribute__ ( ( format( printf, 2, 3 ) ) )
00095 #endif
00096 ;
00097 
00102 extern void IDDefLight (const ILightVectorProperty *l, const char *msg, ...)
00103 #ifdef __GNUC__
00104         __attribute__ ( ( format( printf, 2, 3 ) ) )
00105 #endif
00106 ;
00107 
00112 extern void IDDefBLOB (const IBLOBVectorProperty *b, const char *msg, ...)
00113 #ifdef __GNUC__
00114     __attribute__ ( ( format( printf, 2, 3 ) ) )
00115 #endif
00116 ;
00117 
00118 
00125 
00130 extern void IDSetText (const ITextVectorProperty *t, const char *msg, ...)
00131 #ifdef __GNUC__
00132         __attribute__ ( ( format( printf, 2, 3 ) ) )
00133 #endif
00134 ;
00135 
00140 extern void IDSetNumber (const INumberVectorProperty *n, const char *msg, ...)
00141 #ifdef __GNUC__
00142         __attribute__ ( ( format( printf, 2, 3 ) ) )
00143 #endif
00144 ;
00145 
00150 extern void IDSetSwitch (const ISwitchVectorProperty *s, const char *msg, ...)
00151 #ifdef __GNUC__
00152         __attribute__ ( ( format( printf, 2, 3 ) ) )
00153 #endif
00154 ;
00155 
00160 extern void IDSetLight (const ILightVectorProperty *l, const char *msg, ...)
00161 #ifdef __GNUC__
00162         __attribute__ ( ( format( printf, 2, 3 ) ) )
00163 #endif
00164 ;
00165 
00170 extern void IDSetBLOB (const IBLOBVectorProperty *b, const char *msg, ...)
00171 #ifdef __GNUC__
00172     __attribute__ ( ( format( printf, 2, 3 ) ) )
00173 #endif
00174 ;
00175 
00186 extern void IDMessage (const char *dev, const char *msg, ...)
00187 #ifdef __GNUC__
00188         __attribute__ ( ( format( printf, 2, 3 ) ) )
00189 #endif
00190 ;
00191 
00198 extern void IDDelete (const char *dev, const char *name, const char *msg, ...)
00199 #ifdef __GNUC__
00200         __attribute__ ( ( format( printf, 3, 4 ) ) )
00201 #endif
00202 ;
00203 
00210 extern void IDLog (const char *msg, ...)
00211 #ifdef __GNUC__
00212         __attribute__ ( ( format( printf, 1, 2 ) ) )
00213 #endif
00214 ;
00215 
00222      
00223  /* signature of a callback, timout caller and work procedure function */
00224 
00226 typedef void (IE_CBF) (int readfiledes, void *userpointer);
00228 typedef void (IE_TCF) (void *userpointer);
00230 typedef void (IE_WPF) (void *userpointer);
00231 
00232 /* functions to add and remove callbacks, timers and work procedures */
00233 
00241 extern int  IEAddCallback (int readfiledes, IE_CBF *fp, void *userpointer);
00242 
00247 extern void IERmCallback (int callbackid);
00248 
00258 extern int  IEAddTimer (int millisecs, IE_TCF *fp, void *userpointer);
00259 
00264 extern void IERmTimer (int timerid);
00265 
00272 extern int  IEAddWorkProc (IE_WPF *fp, void *userpointer);
00273 
00278 extern void IERmWorkProc (int workprocid);
00279 
00288 
00289 
00296 extern IText   *IUFindText  (const ITextVectorProperty *tp, const char *name);
00297 
00304 extern INumber *IUFindNumber(const INumberVectorProperty *tp, const char *name);
00305 
00312 extern ISwitch *IUFindSwitch(const ISwitchVectorProperty *tp, const char *name);
00313 
00321 extern ISwitch *IUFindOnSwitch (const ISwitchVectorProperty *tp);
00322 
00327 extern void IUResetSwitches(const ISwitchVectorProperty *svp);
00328 
00337 extern int IUUpdateSwitches(ISwitchVectorProperty *svp, ISState *states, char *names[], int n);
00338 
00347 extern int IUUpdateNumbers(INumberVectorProperty *nvp, double values[], char *names[], int n);
00348 
00352 extern void IUUpdateMinMax(INumberVectorProperty *nvp);
00353 
00358 extern void IUSaveText (IText *tp, const char *newtext);
00359 
00366 extern void fillSwitch(ISwitch *sp, const char *name, const char * label, ISState s);
00367 
00378 extern void fillNumber(INumber *np, const char *name, const char * label, const char *format, double min, double max, double step, double value);
00379 
00386 extern void fillText(IText *tp, const char *name, const char * label, const char *initialText);
00387 
00401 extern void fillSwitchVector(ISwitchVectorProperty *svp, ISwitch *sp, int nsp, const char * dev, const char *name, const char *label, const char *group, IPerm p, ISRule r, double timeout, IPState s);
00402 
00415 extern void fillNumberVector(INumberVectorProperty *nvp, INumber *np, int nnp, const char * dev, const char *name, const char *label, const char* group, IPerm p, double timeout, IPState s);
00416 
00429 extern void fillTextVector(ITextVectorProperty *tvp, IText *tp, int ntp, const char * dev, const char *name, const char *label, const char* group, IPerm p, double timeout, IPState s);
00430 
00433 /*******************************************************************************
00434  *******************************************************************************
00435  *
00436  *   Functions the INDI Device Driver framework calls which the Driver must
00437  *   define.
00438  *
00439  *******************************************************************************
00440  *******************************************************************************
00441  */
00442 
00443 
00447 extern void ISGetProperties (const char *dev);
00448 
00449 
00456 
00465 extern void ISNewText (const char *dev, const char *name, char *texts[],
00466     char *names[], int n); 
00467 
00476 extern void ISNewNumber (const char *dev, const char *name, double *doubles,
00477     char *names[], int n); 
00478 
00487 extern void ISNewSwitch (const char *dev, const char *name, ISState *states,
00488     char *names[], int n); 
00489 
00502 extern void ISNewBLOB (const char *dev, const char *name, int sizes[],
00503     char *blobs[], char *formats[], char *names[], int n); 
00504 
00507 #ifdef __cplusplus
00508 }
00509 #endif
00510 
00511 #endif

kstars

Skip menu "kstars"
  • Main Page
  • Modules
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

API Reference

Skip menu "API Reference"
  • keduca
  • kstars
Generated for API Reference by doxygen 1.5.9
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal