3
Copyright (C) 2003-2006 Elwood C. Downey
5
Modified by Jasem Mutlaq (2003-2006)
7
This library is free software; you can redistribute it and/or
8
modify it under the terms of the GNU Lesser General Public
9
License as published by the Free Software Foundation; either
10
version 2.1 of the License, or (at your option) any later version.
12
This library is distributed in the hope that it will be useful,
13
but WITHOUT ANY WARRANTY; without even the implied warranty of
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15
Lesser General Public License for more details.
17
You should have received a copy of the GNU Lesser General Public
18
License along with this library; if not, write to the Free Software
19
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
26
/** \file indidevapi.h
27
\brief Interface to the reference INDI C API device implementation on the Device Driver side.
28
\author Elwood C. Downey
31
This file is divided into two main sections:\n
32
<ol><li> Functions the INDI device driver framework defines which the Driver may
35
<ul><li>IDxxx functions to send messages to an INDI client.</li>
36
<li>IExxx functions to implement the event driven model.</li>
37
<li>IUxxx functions to perform handy utility functions.</li></ul>
39
<li>Functions the INDI device driver framework calls which the Driver must
42
<ul><li>ISxxx to respond to messages from a Client.</li></ul></ol>
44
<p>These functions are the interface to the INDI C-language Device Driver
45
reference implementation library. Any driver that uses this interface is
46
expected to #include "indidevapi.h" and to link with indidrivermain.o and
47
eventloop.o. Indidevapi.h further includes indiapi.h. The former contains
48
the prototypes for the functions documented here, although many functions
49
take arguments defined in the latter.</p>
51
<p>These functions make it much easier to write a compliant INDI driver than
52
starting from scratch, and also serve as a concrete
53
example of the interactions an INDI driver, in any language, is expected to
56
<p>The reference driver framework and the optimizations made within the reference
57
indiserver both assume and require that one driver program implements exactly
58
one logical INDI device.</p>
60
<p>The functions in this framework fall into two broad categories. Some are
61
functions that a driver must define because they are called by the reference
62
framework; these functions begin with IS. The remaining functions are library
63
utilities a driver may use to do important operations.</p>
65
<p>A major point to realize is that an INDI driver built with this framework
66
does not contain the C main() function. As soon as a driver begins executing,
67
it listens on stdin for INDI messages. Only when a valid and appropriate
68
message is received will it then call the driver via one of the IS functions.
69
The driver is then expected to respond promptly by calling one of the ID
70
library functions. It may also use any of the IU utility functions as desired
71
to make processing a message easier.</p>
73
<p>Rather separate from these IS, ID and IU functions are a collection of
74
functions that utilize the notion of a callback. In a callback design,
75
the driver registers a function with the framework to be called under
76
certain circumstances. When said circumstances occur, the framework will
77
call the callback function. The driver never calls these callbacks directly.
78
These callback functions begin with IE. They can arrange for a callback
79
function to be called under three kinds of circumstances: when a given file
80
descriptor may be read without blocking (because either data is available
81
or EOF has been encountered), when a given time interval has elapsed, or
82
when the framework has nothing urgent to do. The callback functions for each
83
circumstance must be written according to a well defined prototype since,
84
after all, the framework must know how to call the callback correctlty.</p>
89
/*******************************************************************************
90
* get the data structures
96
/*******************************************************************************
97
*******************************************************************************
99
* Functions the INDI device driver framework defines which the Driver may call
101
*******************************************************************************
102
*******************************************************************************
110
* \defgroup d2cFunctions IDDef Functions: Functions drivers call to define their properties to clients.
112
<p>Each of the following functions creates the appropriate XML formatted
113
INDI message from its arguments and writes it to stdout. From there, is it
114
typically read by indiserver which then sends it to the clients that have
115
expressed interest in messages from the Device indicated in the message.</p>
117
<p>In addition to type-specific arguments, all end with a printf-style format
118
string, and appropriate subsequent arguments, that form the \param msg
119
attribute within the INDI message. If the format argument is NULL, no message
120
attribute is included with the message. Note that a \e timestamp
121
attribute is also always added automatically based on the clock on the
122
computer on which this driver is running.</p>
129
/** \brief Tell client to create a text vector property.
130
\param t pointer to the vector text property to be defined.
131
\param msg message in printf style to send to the client. May be NULL.
133
extern void IDDefText (const ITextVectorProperty *t, const char *msg, ...)
135
__attribute__ ( ( format( printf, 2, 3 ) ) )
139
/** \brief Tell client to create a number number property.
140
\param n pointer to the vector number property to be defined.
141
\param msg message in printf style to send to the client. May be NULL.
143
extern void IDDefNumber (const INumberVectorProperty *n, const char *msg, ...)
145
__attribute__ ( ( format( printf, 2, 3 ) ) )
149
/** \brief Tell client to create a switch vector property.
150
\param s pointer to the vector switch property to be defined.
151
\param msg message in printf style to send to the client. May be NULL.
153
extern void IDDefSwitch (const ISwitchVectorProperty *s, const char *msg, ...)
155
__attribute__ ( ( format( printf, 2, 3 ) ) )
159
/** \brief Tell client to create a light vector property.
160
\param l pointer to the vector light property to be defined.
161
\param msg message in printf style to send to the client. May be NULL.
163
extern void IDDefLight (const ILightVectorProperty *l, const char *msg, ...)
165
__attribute__ ( ( format( printf, 2, 3 ) ) )
169
/** \brief Tell client to create a BLOB vector property.
170
\param b pointer to the vector BLOB property to be defined.
171
\param msg message in printf style to send to the client. May be NULL.
173
extern void IDDefBLOB (const IBLOBVectorProperty *b, const char *msg, ...)
175
__attribute__ ( ( format( printf, 2, 3 ) ) )
183
* \defgroup d2cuFunctions IDSet Functions: Functions drivers call to tell clients of new values for existing properties.
187
/** \brief Tell client to update an existing text vector property.
188
\param t pointer to the vector text property.
189
\param msg message in printf style to send to the client. May be NULL.
191
extern void IDSetText (const ITextVectorProperty *t, const char *msg, ...)
193
__attribute__ ( ( format( printf, 2, 3 ) ) )
197
/** \brief Tell client to update an existing number vector property.
198
\param n pointer to the vector number property.
199
\param msg message in printf style to send to the client. May be NULL.
201
extern void IDSetNumber (const INumberVectorProperty *n, const char *msg, ...)
203
__attribute__ ( ( format( printf, 2, 3 ) ) )
207
/** \brief Tell client to update an existing switch vector property.
208
\param s pointer to the vector switch property.
209
\param msg message in printf style to send to the client. May be NULL.
211
extern void IDSetSwitch (const ISwitchVectorProperty *s, const char *msg, ...)
213
__attribute__ ( ( format( printf, 2, 3 ) ) )
217
/** \brief Tell client to update an existing light vector property.
218
\param l pointer to the vector light property.
219
\param msg message in printf style to send to the client. May be NULL.
221
extern void IDSetLight (const ILightVectorProperty *l, const char *msg, ...)
223
__attribute__ ( ( format( printf, 2, 3 ) ) )
227
/** \brief Tell client to update an existing BLOB vector property.
228
\param b pointer to the vector BLOB property.
229
\param msg message in printf style to send to the client. May be NULL.
231
extern void IDSetBLOB (const IBLOBVectorProperty *b, const char *msg, ...)
233
__attribute__ ( ( format( printf, 2, 3 ) ) )
240
* \defgroup d2duFunctions ID Functions: Functions to delete properties, and log messages locally or remotely.
245
/** \brief Function Drivers call to send log messages to Clients.
247
If dev is specified the Client shall associate the message with that device; if dev is NULL the Client shall treat the message as generic from no specific Device.
249
\param dev device name
250
\param msg message in printf style to send to the client.
252
extern void IDMessage (const char *dev, const char *msg, ...)
254
__attribute__ ( ( format( printf, 2, 3 ) ) )
258
/** \brief Function Drivers call to inform Clients a Property is no longer available, or the entire device is gone if name is NULL.
260
\param dev device name. If device name is NULL, the entire device will be deleted.
261
\param name property name to be deleted.
262
\param msg message in printf style to send to the client.
264
extern void IDDelete (const char *dev, const char *name, const char *msg, ...)
266
__attribute__ ( ( format( printf, 3, 4 ) ) )
270
/** \brief Function Drivers call to log a message locally.
272
The message is not sent to any Clients.
274
\param msg message in printf style to send to the client.
276
extern void IDLog (const char *msg, ...)
278
__attribute__ ( ( format( printf, 1, 2 ) ) )
285
* \defgroup snoopFunctions ISnoop Functions: Functions drivers call to snoop on other drivers.
291
/** \typedef BLOBHandling
292
\brief How drivers handle BLOBs incoming from snooping drivers */
295
B_NEVER=0, /*!< Never receive BLOBs */
296
B_ALSO, /*!< Receive BLOBs along with normal messages */
297
B_ONLY /*!< ONLY receive BLOBs from drivers, ignore all other traffic */
300
/** \brief Function a Driver calls to snoop on another Device. Snooped messages will then arrive via ISSnoopDevice.
301
\param snooped_device name of the device to snoop.
302
\param snooped_property name of the snooped property in the device.
304
extern void IDSnoopDevice (const char *snooped_device, char *snooped_property);
306
/** \brief Function a Driver calls to control whether they will receive BLOBs from snooped devices.
307
\param snooped_device_name name of the device to snoop.
308
\param bh How drivers handle BLOBs incoming from snooping drivers.
310
extern void IDSnoopBLOBs (const char *snooped_device, BLOBHandling bh);
315
* \defgroup deventFunctions IE Functions: Functions drivers call to register with the INDI event utilities.
317
Callbacks are called when a read on a file descriptor will not block. Timers are called once after a specified interval. Workprocs are called when there is nothing else to do. The "Add" functions return a unique id for use with their corresponding "Rm" removal function. An arbitrary pointer may be specified when a function is registered which will be stored and forwarded unchanged when the function is later invoked.
321
/* signature of a callback, timout caller and work procedure function */
324
\brief Signature of a callback. */
325
typedef void (IE_CBF) (int readfiledes, void *userpointer);
328
\brief Signature of a timeout caller. */
329
typedef void (IE_TCF) (void *userpointer);
332
\brief Signature of a work procedure function. */
333
typedef void (IE_WPF) (void *userpointer);
335
/* functions to add and remove callbacks, timers and work procedures */
337
/** \brief Register a new callback, \e fp, to be called with \e userpointer as argument when \e readfiledes is ready.
339
* \param readfiledes file descriptor.
340
* \param fp a pointer to the callback function.
341
* \param userpointer a pointer to be passed to the callback function when called.
342
* \return a unique callback id for use with IERmCallback().
344
extern int IEAddCallback (int readfiledes, IE_CBF *fp, void *userpointer);
346
/** \brief Remove a callback function.
348
* \param callbackid the callback ID returned from IEAddCallback()
350
extern void IERmCallback (int callbackid);
352
/** \brief Register a new timer function, \e fp, to be called with \e ud as argument after \e ms.
354
Add to list in order of decreasing time from epoch, ie, last entry runs soonest. The timer will only invoke the callback function \b once. You need to call addTimer again if you want to repeat the process.
356
* \param millisecs timer period in milliseconds.
357
* \param fp a pointer to the callback function.
358
* \param userpointer a pointer to be passed to the callback function when called.
359
* \return a unique id for use with IERmTimer().
361
extern int IEAddTimer (int millisecs, IE_TCF *fp, void *userpointer);
363
/** \brief Remove the timer with the given \e timerid, as returned from IEAddTimer.
365
* \param timerid the timer callback ID returned from IEAddTimer().
367
extern void IERmTimer (int timerid);
369
/** \brief Add a new work procedure, fp, to be called with ud when nothing else to do.
371
* \param fp a pointer to the work procedure callback function.
372
* \param userpointer a pointer to be passed to the callback function when called.
373
* \return a unique id for use with IERmWorkProc().
375
extern int IEAddWorkProc (IE_WPF *fp, void *userpointer);
377
/** \brief Remove a work procedure.
379
* \param workprocid The unique ID for the work procedure to be removed.
381
extern void IERmWorkProc (int workprocid);
383
/* wait in-line for a flag to set, presumably by another event function */
385
extern int IEDeferLoop (int maxms, int *flagp);
386
extern int IEDeferLoop0 (int maxms, int *flagp);
391
* \defgroup dutilFunctions IU Functions: Functions drivers call to perform handy utility routines.
393
<p>This section describes handy utility functions that are provided by the
394
framework for tasks commonly required in the processing of client
395
messages. It is not strictly necessary to use these functions, but it
396
both prudent and efficient to do so.</P>
398
<p>These do not communicate with the Client in any way.</p>
403
/** \brief Find an IText member in a vector text property.
405
* \param tp a pointer to a text vector property.
406
* \param name the name of the member to search for.
407
* \return a pointer to an IText member on match, or NULL if nothing is found.
409
extern IText *IUFindText (const ITextVectorProperty *tp, const char *name);
411
/** \brief Find an INumber member in a number text property.
413
* \param tp a pointer to a number vector property.
414
* \param name the name of the member to search for.
415
* \return a pointer to an INumber member on match, or NULL if nothing is found.
417
extern INumber *IUFindNumber(const INumberVectorProperty *tp, const char *name);
419
/** \brief Find an ISwitch member in a vector switch property.
421
* \param tp a pointer to a switch vector property.
422
* \param name the name of the member to search for.
423
* \return a pointer to an ISwitch member on match, or NULL if nothing is found.
425
extern ISwitch *IUFindSwitch(const ISwitchVectorProperty *tp, const char *name);
427
/** \brief Returns the first ON switch it finds in the vector switch property.
429
* \note This is only valid for ISR_1OFMANY mode. That is, when only one switch out of many is allowed to be ON. Do not use this function if you can have multiple ON switches in the same vector property.
431
* \param tp a pointer to a switch vector property.
432
* \return a pointer to the \e first ON ISwitch member if found. If all switches are off, NULL is returned.
434
extern ISwitch *IUFindOnSwitch (const ISwitchVectorProperty *tp);
436
/** \brief Reset all switches in a switch vector property to OFF.
438
* \param svp a pointer to a switch vector property.
440
extern void IUResetSwitch(ISwitchVectorProperty *svp);
442
/** \brief Update all switches in a switch vector property.
444
* \param svp a pointer to a switch vector property.
445
* \param states the states of the new ISwitch members.
446
* \param names the names of the ISwtich members to update.
447
* \param n the number of ISwitch members to update.
448
* \return 0 if update successful, -1 otherwise.
450
extern int IUUpdateSwitch(ISwitchVectorProperty *svp, ISState *states, char *names[], int n);
452
/** \brief Update all numbers in a number vector property.
454
* \param nvp a pointer to a number vector property.
455
* \param values the states of the new INumber members.
456
* \param names the names of the INumber members to update.
457
* \param n the number of INumber members to update.
458
* \return 0 if update successful, -1 otherwise. Update will fail if values are out of scope, or in case of property name mismatch.
460
extern int IUUpdateNumber(INumberVectorProperty *nvp, double values[], char *names[], int n);
462
/** \brief Update all text members in a text vector property.
464
* \param tvp a pointer to a text vector property.
465
* \param texts a pointer to the text members
466
* \param names the names of the IText members to update.
467
* \param n the number of IText members to update.
468
* \return 0 if update successful, -1 otherwise. Update will fail in case of property name mismatch.
470
extern int IUUpdateText(ITextVectorProperty *tvp, char * texts[], char *names[], int n);
472
/** \brief Function to update the min and max elements of a number in the client
473
\param nvp pointer to an INumberVectorProperty.
475
extern void IUUpdateMinMax(const INumberVectorProperty *nvp);
477
/** \brief Function to reliably save new text in a IText.
478
\param tp pointer to an IText member.
479
\param newtext the new text to be saved
481
extern void IUSaveText (IText *tp, const char *newtext);
483
/** \brief Assign attributes for a switch property. The switch's auxiliary elements will be set to NULL.
484
\param sp pointer a switch property to fill
485
\param name the switch name
486
\param label the switch label
487
\param s the switch state (ISS_ON or ISS_OFF)
489
extern void IUFillSwitch(ISwitch *sp, const char *name, const char * label, ISState s);
491
/** \brief Assign attributes for a light property. The light's auxiliary elements will be set to NULL.
492
\param lp pointer a light property to fill
493
\param name the light name
494
\param label the light label
495
\param s the light state (IDLE, WARNING, OK, ALERT)
497
extern void IUFillLight(ILight *lp, const char *name, const char * label, IPState s);
499
/** \brief Assign attributes for a number property. The number's auxiliary elements will be set to NULL.
500
\param np pointer a number property to fill
501
\param name the number name
502
\param label the number label
503
\param format the number format in printf style (e.g. "%02d")
504
\param min the minimum possible value
505
\param max the maximum possible value
506
\param step the step used to climb from minimum value to maximum value
507
\param value the number's current value
509
extern void IUFillNumber(INumber *np, const char *name, const char * label, const char *format, double min, double max, double step, double value);
511
/** \brief Assign attributes for a text property. The text's auxiliary elements will be set to NULL.
512
\param tp pointer a text property to fill
513
\param name the text name
514
\param label the text label
515
\param initialText the initial text
517
extern void IUFillText(IText *tp, const char *name, const char * label, const char *initialText);
520
/** \brief Assign attributes for a switch vector property. The vector's auxiliary elements will be set to NULL.
521
\param svp pointer a switch vector property to fill
522
\param sp pointer to an array of switches
523
\param nsp the dimension of sp
524
\param dev the device name this vector property belongs to
525
\param name the vector property name
526
\param label the vector property label
527
\param group the vector property group
528
\param p the vector property permission
529
\param r the switches behavior
530
\param timeout vector property timeout in seconds
531
\param s the vector property initial state.
533
extern void IUFillSwitchVector(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);
535
/** \brief Assign attributes for a light vector property. The vector's auxiliary elements will be set to NULL.
536
\param lvp pointer a light vector property to fill
537
\param lp pointer to an array of lights
538
\param nlp the dimension of lp
539
\param dev the device name this vector property belongs to
540
\param name the vector property name
541
\param label the vector property label
542
\param group the vector property group
543
\param s the vector property initial state.
545
extern void IUFillLightVector(ILightVectorProperty *lvp, ILight *lp, int nlp, const char * dev, const char *name, const char *label, const char *group, IPState s);
547
/** \brief Assign attributes for a number vector property. The vector's auxiliary elements will be set to NULL.
548
\param nvp pointer a number vector property to fill
549
\param np pointer to an array of numbers
550
\param nnp the dimension of np
551
\param dev the device name this vector property belongs to
552
\param name the vector property name
553
\param label the vector property label
554
\param group the vector property group
555
\param p the vector property permission
556
\param timeout vector property timeout in seconds
557
\param s the vector property initial state.
559
extern void IUFillNumberVector(INumberVectorProperty *nvp, INumber *np, int nnp, const char * dev, const char *name, const char *label, const char* group, IPerm p, double timeout, IPState s);
561
/** \brief Assign attributes for a text vector property. The vector's auxiliary elements will be set to NULL.
562
\param tvp pointer a text vector property to fill
563
\param tp pointer to an array of texts
564
\param ntp the dimension of tp
565
\param dev the device name this vector property belongs to
566
\param name the vector property name
567
\param label the vector property label
568
\param group the vector property group
569
\param p the vector property permission
570
\param timeout vector property timeout in seconds
571
\param s the vector property initial state.
573
extern void IUFillTextVector(ITextVectorProperty *tvp, IText *tp, int ntp, const char * dev, const char *name, const char *label, const char* group, IPerm p, double timeout, IPState s);
575
/** \brief Update a snooped number vector property from the given XML root element.
576
\param root XML root elememnt containing the snopped property content
577
\param nvp a pointer to the number vector property to be updated.
578
\return 0 if cracking the XML element and updating the property proceeded without errors, -1 if trouble.
580
extern int IUSnoopNumber (XMLEle *root, INumberVectorProperty *nvp);
582
/** \brief Update a snooped text vector property from the given XML root element.
583
\param root XML root elememnt containing the snopped property content
584
\param tvp a pointer to the text vector property to be updated.
585
\return 0 if cracking the XML element and updating the property proceeded without errors, -1 if trouble.
587
extern int IUSnoopText (XMLEle *root, ITextVectorProperty *tvp);
589
/** \brief Update a snooped light vector property from the given XML root element.
590
\param root XML root elememnt containing the snopped property content
591
\param lvp a pointer to the light vector property to be updated.
592
\return 0 if cracking the XML element and updating the property proceeded without errors, -1 if trouble.
594
extern int IUSnoopLight (XMLEle *root, ILightVectorProperty *lvp);
596
/** \brief Update a snooped switch vector property from the given XML root element.
597
\param root XML root elememnt containing the snopped property content
598
\param svp a pointer to the switch vector property to be updated.
599
\return 0 if cracking the XML element and updating the property proceeded without errors, -1 if trouble.
601
extern int IUSnoopSwitch (XMLEle *root, ISwitchVectorProperty *svp);
603
/** \brief Update a snooped BLOB vector property from the given XML root element.
604
\param root XML root elememnt containing the snopped property content
605
\param bvp a pointer to the BLOB vector property to be updated.
606
\return 0 if cracking the XML element and updating the property proceeded without errors, -1 if trouble.
608
extern int IUSnoopBLOB (XMLEle *root, IBLOBVectorProperty *bvp);
612
/*******************************************************************************
613
*******************************************************************************
615
* Functions the INDI Device Driver framework calls which the Driver must
618
*******************************************************************************
619
*******************************************************************************
625
* \defgroup dcuFunctions IS Functions: Functions all drivers must define.
627
This section defines functions that must be defined in each driver. These
628
functions are never called by the driver, but are called by the driver
629
framework. These must always be defined even if they do nothing.
633
/** \brief Get Device Properties
634
\param dev the name of the device.
636
This function is called by the framework whenever the driver has received a
637
getProperties message from an INDI client. The argument \param dev is either a
638
string containing the name of the device specified within the message, or NULL
639
if no device was specified. If the driver does not recognize the device, it
640
should ignore the message and do nothing. If dev matches the device the driver
641
is implementing, or dev is NULL, the driver must respond by sending one defXXX
642
message to describe each property defined by this device, including its
643
current (or initial) value. The recommended way to send these messages is to
644
call the appropriate IDDef functions.
646
extern void ISGetProperties (const char *dev);
649
/** \brief Update the value of an existing text vector property.
650
\param dev the name of the device.
651
\param name the name of the text vector property to update.
652
\param texts an array of text values.
653
\param names parallel names to the array of text values.
654
\param n the dimension of texts[].
655
\note You do not need to call this function, it is called by INDI when new text values arrive from the client.
657
extern void ISNewText (const char *dev, const char *name, char *texts[],
658
char *names[], int n);
660
/** \brief Update the value of an existing number vector property.
661
\param dev the name of the device.
662
\param name the name of the number vector property to update.
663
\param doubles an array of number values.
664
\param names parallel names to the array of number values.
665
\param n the dimension of doubles[].
666
\note You do not need to call this function, it is called by INDI when new number values arrive from the client.
668
extern void ISNewNumber (const char *dev, const char *name, double *doubles,
669
char *names[], int n);
671
/** \brief Update the value of an existing switch vector property.
672
\param dev the name of the device.
673
\param name the name of the switch vector property to update.
674
\param states an array of switch states.
675
\param names parallel names to the array of switch states.
676
\param n the dimension of states[].
677
\note You do not need to call this function, it is called by INDI when new switch values arrive from the client.
679
extern void ISNewSwitch (const char *dev, const char *name, ISState *states,
680
char *names[], int n);
682
/** \brief Update data of an existing blob vector property.
683
\param dev the name of the device.
684
\param name the name of the blob vector property to update.
685
\param sizes an array of base64 blob sizes in bytes \e before decoding.
686
\param blobsizes an array of the sizes of blobs \e after decoding from base64.
687
\param blobs an array of decoded data. Each blob size is found in \e blobsizes array.
688
\param formats Blob data format (e.g. fits.z).
689
\param names names of blob members to update.
690
\param n the number of blobs to update.
691
\note You do not need to call this function, it is called by INDI when new blob values arrive from the client.
692
e.g. BLOB element with name names[0] has data located in blobs[0] with size sizes[0] and format formats[0].
695
extern void ISNewBLOB (const char *dev, const char *name, int sizes[], int blobsizes[], char *blobs[], char *formats[], char *names[], int n);
697
/** \brief Function defined by Drivers that is called when another Driver it is snooping (by having previously called IDSnoopDevice()) sent any INDI message.
698
\param root The argument contains the full message exactly as it was sent by the driver.
699
\e Hint: use the IUSnoopXXX utility functions to help crack the message if it was one of setXXX or defXXX.
701
extern void ISSnoopDevice (XMLEle *root);
705
/* Handy readability macro to avoid unused variables warnings */
706
#define INDI_UNUSED(x) (void) x