le_atServer_interface.h

Go to the documentation of this file.
1 
2 
3 /*
4  * ====================== WARNING ======================
5  *
6  * THE CONTENTS OF THIS FILE HAVE BEEN AUTO-GENERATED.
7  * DO NOT MODIFY IN ANY WAY.
8  *
9  * ====================== WARNING ======================
10  */
11 
12 /**
13  * @page c_atServer AT Commands Server
14  *
15  * @ref le_atServer_interface.h "API Reference"
16  *
17  * The AT commands Server handles AT commands' subscriptions on a requested serial device. The
18  * server is compliant with 3GPP 27.007, paragraphs 4.0, 4.1 and 4.2, and V25 ter, paragraphs 5.3,
19  * 5.4.
20  *
21  * @section le_atServer_binding IPC interfaces binding
22  *
23  * All the functions of this API are provided by the @b atService.
24  *
25  * Here's a code sample binding to the AT commands server:
26  * @verbatim
27  bindings:
28  {
29  atServerTest.atServerTestComp.le_atServer -> atService.le_atServer
30  }
31  @endverbatim
32  *
33  * @section atServer_syntax AT command syntax
34  *
35  * @subsection atServer_Syntax Syntax rules
36  *
37  * To be interpreted, the command line sent to the AT commands server must start by the pattern
38  * "AT" (mean ATtention command).<br>
39  * Lowercase characters are changed to their uppercase equivalents. Only characters between quotes
40  * are not replaced.
41  *
42  * The supported command formats are:
43  * - Basic syntax command:
44  * - using the format AT<command>[<number>]<br>
45  * The command name is composed of one or several of those characters: A to Z, & and \\.
46  * - the syntax of S command is also supported, like:
47  * - ATS<parameter_number>?
48  * - ATS<parameter_number>=<value>
49  * - D command is supported. The characters which don't belong to the following list are
50  * ignore:
51  * - V.250 dialing digits: 0 1 2 3 4 5 6 7 8 9 * # + A B C D
52  * - V.250 modifier characters: , T P ! W @
53  * - V.250 semicolon character: ;
54  * - GSM/UMTS modifier characters:
55  * - I or i for CLIR supplementary service subscription
56  * (I=invocation, i=suppression)
57  * - G or g for CUG supplementary service subscription (G=invocation,
58  * g=suppression)
59  * - Direct dialing from phonebook: > (if follow by a string, it has to be put
60  * between quote)
61  * .
62  * @if 0 doxygen comment: The dot above ends the sub item, and must be kept @endif
63  * All characters after the "D" are considered part of The D command parameter up to a semicolon or
64  * the end of command line.
65  * <br>
66  * - Extended command format, with the following format:
67  * - action command with no parameters: AT+<name>
68  * - parameter command: AT+<name>=<value1>[,<value2>[,<value3>[...]]]<br>
69  * Values must be separated by a coma. Some values may be optional: in that case, optional
70  * value can be omitted in the AT command (e.g. AT+ABCD=,1).<br>
71  * A value is a string composed of one or several of the following characters: 0 to 9,
72  * A to F, H, z*, #, +, -. To set a value with other characters, the value has to be set
73  * between quote.
74  * - test command (determine the supported values): AT+<name>=?
75  * - read command (determine the current values, or stored values): AT+<name>?
76  *
77  * @note '+' AT command starting character shall be replaced by other symbol, not included into
78  * a to z, A to Z, & and \\.
79  *
80  * @subsection atServer_concate Concatenating commands
81  *
82  * Basic syntax command can be concatenated without a separator:<br>
83  * ATE1V1S95=47S0=0
84  *
85  * Additional commands (extended syntax command or basic syntax command) can be added after an
86  * extended syntax command with the insertion of a semicolon at the end of the command:<br>
87  * AT+CMDA=<param1>,<param2>;+CMDB?;+CMDC=?<br>
88  * AT+CMDA=<param1>,<param2>;E1V1
89  *
90  * Extended syntax command can be concatenated after basic syntax commands without a separator:<br>
91  * ATE1V1+CMD=<param1>
92  *
93  * @section atServer_binding Device Binding
94  *
95  * le_atServer_Start() must be called to bind the file descriptor of the device with the AT commands
96  * server. Note that a socket can also be bound.
97  * Multiple devices can be bound.
98  * A file descriptor can be unbound using le_atServer_Stop().
99  *
100  * The server can be suspended using le_atServer_Suspend() in order to use the
101  * opened fd for other purposes like starting a PPP service on the opened fd.
102  * For that a fd dup needs to be done before opening a server session.
103  * When needed, the server can be resumed using le_atServer_Resume(). Make sure
104  * to close the fd when the application exists or you may get too many open files error.
105  *
106  * used before opening a server session
107  * @section atServer_subscription Subscription
108  *
109  * A new AT command can be added into the parser using le_atServer_Create(), and it can be deleted
110  * using le_atServer_Delete().
111  * le_atServer_EnableEcho() allows the user to enable echo on a selected device.
112  * le_atServer_DisableEcho() allows the user to disable echo on a selected device.
113  *
114  * @section atServer_handler Handler
115  *
116  * To handle the AT command, the application has to subscribe a handler using
117  * le_atServer_AddCommandHandler(). It can be removed with le_atServer_RemoveCommandHandler().<br>
118  * The called handler (le_atServer_CommandHandlerRef_t prototype) can use
119  * le_atServer_GetCommandName() to retrieve the received AT command string.<br>
120  * The device used to execute the AT command can be retrieve thanks to le_atServer_GetDevice().<br>
121  * It can also call le_atServer_GetParameter() to retrieve parameters of the AT command. This
122  * function gets the string sending through the AT command. If the parameter was sent between
123  * quotes, the quotes are removed. This API can be used for both formats:
124  * - In case of a basic format command, if exists, the parameter can be retrieved at the index 0.<br>
125  * For S command specific format (ATS<parameter_number>=<value>), the <parameter_number> is
126  * retrieved at the index 0, the <value> parameter at the index 1.
127  *
128  * - In case of an extended format command, parameters are retrieved thanks to their indexes,
129  * starting from 0. If the parameter is missed (e.g. "AT+CMD=,1"), the getting value is an empty
130  * string (i.e. '\0' with null length).
131  *
132  * The handler receives in argument the type of the AT command (of le_atServer_Type_t type).
133  * Even if these types are specific to the extended format commands according to the standards, they
134  * are also applicable here to basic format commands to detect commands with parameters, or read
135  * values (e.g. ATS<parameter_number>?).
136  *
137  * @section atServer_responses Responses
138  *
139  * @subsection intermediateRsp Intermediate response
140  *
141  * The application has can send intermediate responses through
142  * le_atServer_SendIntermediateResponse().
143  *
144  * @subsection finalRsp Final response
145  *
146  * In all cases, the application must send a final response using
147  * le_atServer_SendFinalResponse(). The corresponding device will be locked until the final response
148  * is sent.
149  *
150  * If no answer is sent, the device will not accept any new AT commands (an error will be
151  * returned).
152  *
153  * le_atServer_SendFinalResponse() has to inform of the result thanks to the argument of
154  * le_atServer_FinalRsp_t type. This argument permits to the AT command Server to:
155  * - create the result string if no custom string is provided
156  * - continue or stop the parsing of concatenated commands: if one command is failed, next commands
157  * are not executed, the final result of the concatenated AT command is the last error.
158  *
159  * @subsection unsolicitedRsp Unsolicited response
160  *
161  * The application can also send unsolicited responses to warn a host
162  * application using le_atServer_SendUnsolicitedResponse().
163  *
164  * This response is sent when no AT command is being processing on the device (i.e. unsolicited
165  * response is sent between the latest final response and the next reception of an AT command).<br>
166  * If an unsolicited response is sent when an AT command is in progress, the unsolicited response
167  * is buffered and sent as soon as the device becomes available (i.e., the processing AT command
168  * sends its final response).
169  *
170  * @section atServer_bridge Bridge
171  *
172  * A second file descriptor can be used thanks to le_atServer_OpenBridge() to send
173  * all unknown AT commands to an altervative device (such as the modem). For all devices linked to
174  * that bridge using le_atServer_AddDeviceToBridge(), unknown commands will be sent through that file
175  * descriptor.
176  *
177  * @image html atCommandsParserBridge.png
178  *
179  * @note AT commands server is opened on the file descriptor fd1 using le_atServer_Open() API.
180  * AT commands server is bridged on the file descriptor fd2 using le_atServer_OpenBridge() API.
181  *
182  * A device can be remove from a bridge thanks to le_atServer_RemoveDeviceFromBridge() API.
183  * A bridge can be closed using le_atServer_CloseBridge() API.
184  *
185  * @warning Some modem AT commands may conflict with Legato APIs; using both may cause problems that
186  * can be difficult to diagnose. The modem AT commands should be avoided whenever possible, and
187  * should only be used with great care.
188  *
189  * The application can send an unsolicited on all opened device, or only one on a dedicated deivce.
190  *
191  * <HR>
192  *
193  * Copyright (C) Sierra Wireless Inc.
194  */
195 /**
196  * @file le_atServer_interface.h
197  *
198  * Legato @ref c_atServer include file.
199  *
200  * Copyright (C) Sierra Wireless Inc.
201  */
202 
203 #ifndef LE_ATSERVER_INTERFACE_H_INCLUDE_GUARD
204 #define LE_ATSERVER_INTERFACE_H_INCLUDE_GUARD
205 
206 
207 #include "legato.h"
208 
209 // Interface specific includes
210 #include "le_atDefs_interface.h"
211 
212 
213 //--------------------------------------------------------------------------------------------------
214 /**
215  * Type for handler called when a server disconnects.
216  */
217 //--------------------------------------------------------------------------------------------------
218 typedef void (*le_atServer_DisconnectHandler_t)(void *);
219 
220 //--------------------------------------------------------------------------------------------------
221 /**
222  *
223  * Connect the current client thread to the service providing this API. Block until the service is
224  * available.
225  *
226  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
227  * called before any other functions in this API. Normally, ConnectService is automatically called
228  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
229  *
230  * This function is created automatically.
231  */
232 //--------------------------------------------------------------------------------------------------
234 (
235  void
236 );
237 
238 //--------------------------------------------------------------------------------------------------
239 /**
240  *
241  * Try to connect the current client thread to the service providing this API. Return with an error
242  * if the service is not available.
243  *
244  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
245  * called before any other functions in this API. Normally, ConnectService is automatically called
246  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
247  *
248  * This function is created automatically.
249  *
250  * @return
251  * - LE_OK if the client connected successfully to the service.
252  * - LE_UNAVAILABLE if the server is not currently offering the service to which the client is
253  * bound.
254  * - LE_NOT_PERMITTED if the client interface is not bound to any service (doesn't have a binding).
255  * - LE_COMM_ERROR if the Service Directory cannot be reached.
256  */
257 //--------------------------------------------------------------------------------------------------
259 (
260  void
261 );
262 
263 //--------------------------------------------------------------------------------------------------
264 /**
265  * Set handler called when server disconnection is detected.
266  *
267  * When a server connection is lost, call this handler then exit with LE_FATAL. If a program wants
268  * to continue without exiting, it should call longjmp() from inside the handler.
269  */
270 //--------------------------------------------------------------------------------------------------
272 (
273  le_atServer_DisconnectHandler_t disconnectHandler,
274  void *contextPtr
275 );
276 
277 //--------------------------------------------------------------------------------------------------
278 /**
279  *
280  * Disconnect the current client thread from the service providing this API.
281  *
282  * Normally, this function doesn't need to be called. After this function is called, there's no
283  * longer a connection to the service, and the functions in this API can't be used. For details, see
284  * @ref apiFilesC_client.
285  *
286  * This function is created automatically.
287  */
288 //--------------------------------------------------------------------------------------------------
290 (
291  void
292 );
293 
294 
295 //--------------------------------------------------------------------------------------------------
296 /**
297  * Reference type for an AT command.
298  */
299 //--------------------------------------------------------------------------------------------------
300 typedef struct le_atServer_Cmd* le_atServer_CmdRef_t;
301 
302 
303 //--------------------------------------------------------------------------------------------------
304 /**
305  * Reference type for a AT command device.
306  */
307 //--------------------------------------------------------------------------------------------------
308 typedef struct le_atServer_Device* le_atServer_DeviceRef_t;
309 
310 
311 //--------------------------------------------------------------------------------------------------
312 /**
313  * Reference type for a AT commands server / AT commands client bridge.
314  */
315 //--------------------------------------------------------------------------------------------------
316 typedef struct le_atServer_Bridge* le_atServer_BridgeRef_t;
317 
318 
319 //--------------------------------------------------------------------------------------------------
320 /**
321  * Received AT command type.
322  *
323  */
324 //--------------------------------------------------------------------------------------------------
325 typedef enum
326 {
328  ///< Action AT command (e.g. 'AT+CMD')
330  ///< AT command received with parameters (e.g. 'AT+CMD=x,y')
332  ///< Test AT command (e.g. 'AT+CMD=?')
334  ///< Read AT command (e.g. 'AT+CMD?')
335 }
337 
338 
339 //--------------------------------------------------------------------------------------------------
340 /**
341  * Final response.
342  */
343 //--------------------------------------------------------------------------------------------------
344 typedef enum
345 {
347  ///< AT command successfully treated, "\r\nOK\r\n" is sent if no custom
348  ///< response is set
350  ///< error in AT command treatement, "\r\nERROR\r\n" is sent if no custom
351  ///< response is set
352 }
354 
355 
356 //--------------------------------------------------------------------------------------------------
357 /**
358  * Device availability.
359  */
360 //--------------------------------------------------------------------------------------------------
361 typedef enum
362 {
364  ///< action will be done on all bound devices
366  ///< action will be done on a specified device
367 }
369 
370 
371 //--------------------------------------------------------------------------------------------------
372 /**
373  * Reference type used by Add/Remove functions for EVENT 'le_atServer_Command'
374  */
375 //--------------------------------------------------------------------------------------------------
376 typedef struct le_atServer_CommandHandler* le_atServer_CommandHandlerRef_t;
377 
378 
379 //--------------------------------------------------------------------------------------------------
380 /**
381  * Handler for the AT command processing.
382  *
383  * @note The argument "parametersNumber" is set only when "type" parameter value is
384  * LE_AT_SERVER_TYPE_PARA
385  */
386 //--------------------------------------------------------------------------------------------------
387 typedef void (*le_atServer_CommandHandlerFunc_t)
388 (
389  le_atServer_CmdRef_t commandRef,
390  ///< Received AT command reference
391  le_atServer_Type_t type,
392  ///< Received AT command type
393  uint32_t parametersNumber,
394  ///< Parameters number
395  void* contextPtr
396  ///<
397 );
398 
399 //--------------------------------------------------------------------------------------------------
400 /**
401  * Suspend server / enter data mode
402  *
403  * When this function is called the server stops monitoring the fd for events
404  * hence no more I/O operations are done on the fd by the server.
405  *
406  * @return
407  * - LE_OK Success.
408  * - LE_BAD_PARAMETER Invalid device reference.
409  * - LE_FAULT Device not monitored
410  *
411  */
412 //--------------------------------------------------------------------------------------------------
414 (
416  ///< [IN] device to be suspended
417 );
418 
419 //--------------------------------------------------------------------------------------------------
420 /**
421  * Resume server / enter command mode
422  *
423  * When this function is called the server resumes monitoring the fd for events
424  * and is able to interpret AT commands again.
425  *
426  * @return
427  * - LE_OK Success.
428  * - LE_BAD_PARAMETER Invalid device reference.
429  * - LE_FAULT Device not monitored
430  *
431  */
432 //--------------------------------------------------------------------------------------------------
434 (
436  ///< [IN] device to be resumed
437 );
438 
439 //--------------------------------------------------------------------------------------------------
440 /**
441  * This function opens an AT server session on the requested device.
442  *
443  * @return
444  * - Reference to the requested device.
445  * - NULL if the device is not available or fd is a BAD FILE DESCRIPTOR.
446  *
447  * @note Make sure to duplicate (man dup) your file descriptor before opening
448  * a server session to be able to use the suspend/resume feature
449  *
450  */
451 //--------------------------------------------------------------------------------------------------
453 (
454  int fd
455  ///< [IN] File descriptor.
456 );
457 
458 //--------------------------------------------------------------------------------------------------
459 /**
460  * This function closes the AT server session on the requested device.
461  *
462  * @return
463  * - LE_OK The function succeeded.
464  * - LE_BAD_PARAMETER Invalid device reference.
465  * - LE_BUSY The requested device is busy.
466  * - LE_FAULT Failed to stop the server, check logs
467  * for more information.
468  */
469 //--------------------------------------------------------------------------------------------------
471 (
473  ///< [IN] device to be unbound
474 );
475 
476 //--------------------------------------------------------------------------------------------------
477 /**
478  * This function created an AT command and register it into the AT parser.
479  *
480  * @return
481  * - Reference to the AT command.
482  * - NULL if an error occurs.
483  */
484 //--------------------------------------------------------------------------------------------------
486 (
487  const char* name
488  ///< [IN] AT command name string
489 )
490 __attribute__(( nonnull(1) ));
491 
492 //--------------------------------------------------------------------------------------------------
493 /**
494  * This function deletes an AT command (i.e. unregister from the AT parser).
495  *
496  * @return
497  * - LE_OK The function succeeded.
498  * - LE_FAULT The function failed to delete the command.
499  * - LE_BUSY Command is in progress.
500  *
501  */
502 //--------------------------------------------------------------------------------------------------
504 (
505  le_atServer_CmdRef_t commandRef
506  ///< [IN] AT command reference
507 );
508 
509 //--------------------------------------------------------------------------------------------------
510 /**
511  * Add handler function for EVENT 'le_atServer_Command'
512  *
513  * This event provides information when the AT command is detected.
514  *
515  */
516 //--------------------------------------------------------------------------------------------------
518 (
519  le_atServer_CmdRef_t commandRef,
520  ///< [IN] AT command reference
522  ///< [IN] Handler to called when the AT command is detected
523  void* contextPtr
524  ///< [IN]
525 );
526 
527 //--------------------------------------------------------------------------------------------------
528 /**
529  * Remove handler function for EVENT 'le_atServer_Command'
530  */
531 //--------------------------------------------------------------------------------------------------
533 (
535  ///< [IN]
536 );
537 
538 //--------------------------------------------------------------------------------------------------
539 /**
540  * This function can be used to get the parameters of a received AT command.
541  *
542  * @return
543  * - LE_OK The function succeeded.
544  * - LE_FAULT The function failed to get the requested parameter.
545  *
546  */
547 //--------------------------------------------------------------------------------------------------
549 (
550  le_atServer_CmdRef_t commandRef,
551  ///< [IN] AT command reference
552  uint32_t index,
553  ///< [IN] agument index
554  char* parameter,
555  ///< [OUT] parameter value
556  size_t parameterSize
557  ///< [IN]
558 );
559 
560 //--------------------------------------------------------------------------------------------------
561 /**
562  * This function can be used to get the AT command string.
563  *
564  * @return
565  * - LE_OK The function succeeded.
566  * - LE_FAULT The function failed to get the AT command string.
567  *
568  */
569 //--------------------------------------------------------------------------------------------------
571 (
572  le_atServer_CmdRef_t commandRef,
573  ///< [IN] AT command reference
574  char* name,
575  ///< [OUT] AT command string
576  size_t nameSize
577  ///< [IN]
578 );
579 
580 //--------------------------------------------------------------------------------------------------
581 /**
582  * This function can be used to get the device reference in use for an AT command specified with
583  * its reference.
584  *
585  * @return
586  * - LE_OK The function succeeded.
587  * - LE_FAULT The function failed to get the AT command string.
588  *
589  */
590 //--------------------------------------------------------------------------------------------------
592 (
593  le_atServer_CmdRef_t commandRef,
594  ///< [IN] AT command reference
595  le_atServer_DeviceRef_t* deviceRefPtr
596  ///< [OUT] Device reference
597 );
598 
599 //--------------------------------------------------------------------------------------------------
600 /**
601  * This function can be used to send an intermediate response.
602  *
603  * @return
604  * - LE_OK The function succeeded.
605  * - LE_FAULT The function failed to send the intermediate response.
606  *
607  */
608 //--------------------------------------------------------------------------------------------------
610 (
611  le_atServer_CmdRef_t commandRef,
612  ///< [IN] AT command reference
613  const char* intermediateRsp
614  ///< [IN] Intermediate response to be
615  ///< sent
616 )
617 __attribute__(( nonnull(2) ));
618 
619 //--------------------------------------------------------------------------------------------------
620 /**
621  * This function can be used to send the final response.
622  *
623  * @return
624  * - LE_OK The function succeeded.
625  * - LE_FAULT The function failed to send the final response.
626  *
627  */
628 //--------------------------------------------------------------------------------------------------
630 (
631  le_atServer_CmdRef_t commandRef,
632  ///< [IN] AT command reference
633  le_atServer_FinalRsp_t finalResponse,
634  ///< [IN] Final response to be sent
635  bool customStringAvailable,
636  ///< [IN] Custom final response has to be sent
637  ///< instead of the default one.
638  const char* finalRsp
639  ///< [IN] custom final response string
640 )
641 __attribute__(( nonnull(4) ));
642 
643 //--------------------------------------------------------------------------------------------------
644 /**
645  * This function can be used to send the unsolicited response.
646  *
647  * @return
648  * - LE_OK The function succeeded.
649  * - LE_FAULT The function failed to send the unsolicited response.
650  *
651  */
652 //--------------------------------------------------------------------------------------------------
654 (
655  const char* unsolRsp,
656  ///< [IN] Unsolicited response to be
657  ///< sent
658  le_atServer_AvailableDevice_t availableDevice,
659  ///< [IN] device to send the
660  ///< unsolicited response
662  ///< [IN] device reference where the
663  ///< unsolicited response has to
664  ///< be sent
665 )
666 __attribute__(( nonnull(1) ));
667 
668 //--------------------------------------------------------------------------------------------------
669 /**
670  * This function enables echo on the selected device.
671  *
672  * @return
673  * - LE_OK The function succeeded.
674  * - LE_BAD_PARAMETER Invalid device reference.
675  */
676 //--------------------------------------------------------------------------------------------------
678 (
680  ///< [IN] device reference
681 );
682 
683 //--------------------------------------------------------------------------------------------------
684 /**
685  * This function disables echo on the selected device.
686  *
687  * @return
688  * - LE_OK The function succeeded.
689  * - LE_BAD_PARAMETER Invalid device reference.
690  */
691 //--------------------------------------------------------------------------------------------------
693 (
695  ///< [IN] device reference
696 );
697 
698 //--------------------------------------------------------------------------------------------------
699 /**
700  * This function opens a AT commands server bridge.
701  * All unknown AT commands will be sent on this alternative file descriptor thanks to the AT client
702  * Service.
703  *
704  * @return
705  * - Reference to the requested bridge.
706  * - NULL if the device can't be bridged
707  */
708 //--------------------------------------------------------------------------------------------------
710 (
711  int fd
712  ///< [IN] File descriptor.
713 );
714 
715 //--------------------------------------------------------------------------------------------------
716 /**
717  * This function closes an opened bridge.
718  *
719  * @return
720  * - LE_OK The function succeeded.
721  * - LE_FAULT The function failed to close the bridge.
722  * - LE_BUSY The bridge is in use (devices references have to be removed first).
723  */
724 //--------------------------------------------------------------------------------------------------
726 (
727  le_atServer_BridgeRef_t bridgeRef
728  ///< [IN] Bridge reference
729 );
730 
731 //--------------------------------------------------------------------------------------------------
732 /**
733  * This function adds a device to an opened bridge.
734  *
735  * @return
736  * - LE_OK The function succeeded.
737  * - LE_BUSY The device is already used by the bridge.
738  * - LE_FAULT The function failed to add the device to the bridge.
739  */
740 //--------------------------------------------------------------------------------------------------
742 (
743  le_atServer_DeviceRef_t deviceRef,
744  ///< [IN] Device reference to add to the bridge
745  le_atServer_BridgeRef_t bridgeRef
746  ///< [IN] Bridge refence
747 );
748 
749 //--------------------------------------------------------------------------------------------------
750 /**
751  * This function removes a device from a bridge
752  *
753  * @return
754  * - LE_OK The function succeeded.
755  * - LE_NOT_FOUND The device is not isued by the specified bridge
756  * - LE_BUSY The device is currently in use
757  * - LE_FAULT The function failed to add the device to the bridge.
758  */
759 //--------------------------------------------------------------------------------------------------
761 (
762  le_atServer_DeviceRef_t deviceRef,
763  ///< [IN] Device reference to add to the bridge
764  le_atServer_BridgeRef_t bridgeRef
765  ///< [IN] Bridge refence
766 );
767 
768 #endif // LE_ATSERVER_INTERFACE_H_INCLUDE_GUARD
void le_atServer_SetServerDisconnectHandler(le_atServer_DisconnectHandler_t disconnectHandler, void *contextPtr)
le_result_t le_atServer_AddDeviceToBridge(le_atServer_DeviceRef_t deviceRef, le_atServer_BridgeRef_t bridgeRef)
Definition: le_atServer_interface.h:346
le_result_t
Definition: le_basics.h:35
le_result_t le_atServer_SendIntermediateResponse(le_atServer_CmdRef_t commandRef, const char *intermediateRsp)
action will be done on all bound devices
Definition: le_atServer_interface.h:363
Action AT command (e.g. &#39;AT+CMD&#39;)
Definition: le_atServer_interface.h:327
le_atServer_BridgeRef_t le_atServer_OpenBridge(int fd)
le_result_t le_atServer_CloseBridge(le_atServer_BridgeRef_t bridgeRef)
struct le_atServer_Device * le_atServer_DeviceRef_t
Definition: le_atServer_interface.h:308
action will be done on a specified device
Definition: le_atServer_interface.h:365
le_atServer_DeviceRef_t le_atServer_Open(int fd)
le_result_t le_atServer_GetCommandName(le_atServer_CmdRef_t commandRef, char *name, size_t nameSize)
void(* le_atServer_DisconnectHandler_t)(void *)
Definition: le_atServer_interface.h:218
le_result_t le_atServer_Close(le_atServer_DeviceRef_t device)
le_result_t le_atServer_Delete(le_atServer_CmdRef_t commandRef)
le_atServer_FinalRsp_t
Definition: le_atServer_interface.h:344
void(* le_atServer_CommandHandlerFunc_t)(le_atServer_CmdRef_t commandRef, le_atServer_Type_t type, uint32_t parametersNumber, void *contextPtr)
Definition: le_atServer_interface.h:388
le_atServer_Type_t
Definition: le_atServer_interface.h:325
le_atServer_CommandHandlerRef_t le_atServer_AddCommandHandler(le_atServer_CmdRef_t commandRef, le_atServer_CommandHandlerFunc_t handlerPtr, void *contextPtr)
void le_atServer_DisconnectService(void)
le_result_t le_atServer_RemoveDeviceFromBridge(le_atServer_DeviceRef_t deviceRef, le_atServer_BridgeRef_t bridgeRef)
le_result_t le_atServer_DisableEcho(le_atServer_DeviceRef_t device)
AT command received with parameters (e.g. &#39;AT+CMD=x,y&#39;)
Definition: le_atServer_interface.h:329
le_result_t le_atServer_EnableEcho(le_atServer_DeviceRef_t device)
le_result_t le_atServer_SendUnsolicitedResponse(const char *unsolRsp, le_atServer_AvailableDevice_t availableDevice, le_atServer_DeviceRef_t device)
void le_atServer_ConnectService(void)
Test AT command (e.g. &#39;AT+CMD=?&#39;)
Definition: le_atServer_interface.h:331
le_atServer_AvailableDevice_t
Definition: le_atServer_interface.h:361
le_result_t le_atServer_GetParameter(le_atServer_CmdRef_t commandRef, uint32_t index, char *parameter, size_t parameterSize)
struct le_atServer_CommandHandler * le_atServer_CommandHandlerRef_t
Definition: le_atServer_interface.h:376
Definition: le_atServer_interface.h:349
le_atServer_CmdRef_t le_atServer_Create(const char *name)
le_result_t le_atServer_TryConnectService(void)
void le_atServer_RemoveCommandHandler(le_atServer_CommandHandlerRef_t handlerRef)
le_result_t le_atServer_GetDevice(le_atServer_CmdRef_t commandRef, le_atServer_DeviceRef_t *deviceRefPtr)
le_result_t le_atServer_Suspend(le_atServer_DeviceRef_t device)
struct le_atServer_Cmd * le_atServer_CmdRef_t
Definition: le_atServer_interface.h:300
le_result_t le_atServer_SendFinalResponse(le_atServer_CmdRef_t commandRef, le_atServer_FinalRsp_t finalResponse, bool customStringAvailable, const char *finalRsp)
le_result_t le_atServer_Resume(le_atServer_DeviceRef_t device)
struct le_atServer_Bridge * le_atServer_BridgeRef_t
Definition: le_atServer_interface.h:316
Read AT command (e.g. &#39;AT+CMD?&#39;)
Definition: le_atServer_interface.h:333