Gammu internals  1.38.0
atgen.h
Go to the documentation of this file.
1 /* (c) 2002-2007 by Marcin Wiacek and Michal Cihar */
2 
23 #ifndef atgen_h
24 #define atgen_h
25 
26 #include <gammu-types.h>
27 #include <gammu-error.h>
28 #include <gammu-statemachine.h>
29 
30 #include "../../gsmreply.h" /* For GSM_Phone_RequestID */
31 #include "../../misc/misc.h" /* For GSM_CutLines */
32 
33 #include "motorola.h"
34 
35 #ifndef GSM_USED_AT
36 # define GSM_USED_AT
37 #endif
38 #ifndef GSM_USED_BLUEAT
39 # define GSM_USED_BLUEAT
40 #endif
41 #ifndef GSM_USED_IRDAAT
42 # define GSM_USED_IRDAAT
43 #endif
44 
45 #define MAX_VCALENDAR_LOCATION 50
46 
47 typedef enum {
51 
52 typedef enum {
61 
66 typedef enum {
67  AT_Nokia = 1,
86 
90 typedef enum {
152 
156 typedef enum {
185 
186 typedef enum {
190 
191 typedef enum {
196 
197 typedef enum {
204 
210 #define GSM_AT_MAXPDULEN 400
211 
215 typedef struct {
219  int Location;
223  int State;
227  char PDU[GSM_AT_MAXPDULEN];
229 
233 #define AT_PBK_MAX_MEMORIES 200
234 
235 typedef struct {
255  char *ErrorText;
256 
264  char PBKMemories[AT_PBK_MAX_MEMORIES + 1];
305  size_t NumberLength;
306  size_t TextLength;
310 
354 
358  int CNMIMode;
367 #ifdef GSM_ENABLE_CELLBROADCAST
368 
371  int CNMIBroadcastProcedure;
372 #endif
373 
386  int SMSCount;
398  int SQWEMode;
405 
413 
421 
423 
429 GSM_Error ATGEN_WaitFor(GSM_StateMachine *s, const char * cmd, size_t len,
430  int type, int time, GSM_Phone_RequestID request);
431 
437 #define ATGEN_WaitForAutoLen(s, cmd, type, time, request) \
438  ATGEN_WaitFor(s, cmd, strlen(cmd), type, time, request)
439 
483 GSM_Error ATGEN_ParseReply(GSM_StateMachine *s, const unsigned char *input, const char *format, ...);
484 
498  const unsigned char *input,
499  const size_t inlength,
500  unsigned char *output,
501  const size_t outlength,
502  size_t *resultlength
503  );
504 
519  const unsigned char *input,
520  const size_t length,
521  unsigned char *output,
522  const size_t outlength,
523  const gboolean guess,
524  const gboolean phone);
525 
535 
536 int ATGEN_ExtractOneParameter(unsigned char *input, unsigned char *output);
537 
545 GSM_Error ATGEN_DecodeDateTime(GSM_StateMachine *s, GSM_DateTime *dt, unsigned char *_input);
546 
547 #endif
548 
550 
551 /* How should editor hadle tabs in this file? Add editor commands here.
552  * vim: noexpandtab sw=8 ts=8 sts=8:
553  */
GSM_SMSMemoryStatus LastSMSStatus
Definition: atgen.h:311
GSM_AT_Feature PBKSBNR
Definition: atgen.h:301
GSM_Error ATGEN_SetCharset(GSM_StateMachine *s, GSM_AT_Charset_Preference Prefer)
Definition: atgen.h:83
GSM_AT_Reply_State
Definition: atgen.h:52
GSM_MemoryType SMSMemory
Definition: atgen.h:340
GSM_Error ATGEN_HandleCMEError(GSM_StateMachine *s)
Definition: atgen.h:76
GSM_AT_Feature PhoneSMSMemory
Definition: atgen.h:328
GSM_Error ATGEN_EncodeText(GSM_StateMachine *s, const unsigned char *input, const size_t inlength, unsigned char *output, const size_t outlength, size_t *resultlength)
GSM_SamsungCalendar
Definition: atgen.h:191
int ATGEN_ExtractOneParameter(unsigned char *input, unsigned char *output)
GSM_CutLines Lines
Definition: atgen.h:243
GSM_Error ATGEN_DecodeDateTime(GSM_StateMachine *s, GSM_DateTime *dt, unsigned char *_input)
GSM_Error ATGEN_HandleCMSError(GSM_StateMachine *s)
GSM_Error
Definition: gammu-error.h:23
GSM_AT_SMS_Modes
Definition: atgen.h:47
int FirstFreeCalendarPos
Definition: atgen.h:314
GSM_AT_Feature PBK_MPBR
Definition: atgen.h:303
GSM_Error ATGEN_DecodeText(GSM_StateMachine *s, const unsigned char *input, const size_t length, unsigned char *output, const size_t outlength, const gboolean guess, const gboolean phone)
GSM_AT_Charset GSMCharset
Definition: atgen.h:300
gboolean SMSTextDetails
Definition: atgen.h:353
GSM_AT_Feature PhoneSaveSMS
Definition: atgen.h:324
Definition: atgen.h:70
size_t TextLength
Definition: atgen.h:306
#define GSM_AT_MAXPDULEN
Definition: atgen.h:210
char * ErrorText
Definition: atgen.h:255
int gboolean
Definition: gammu-types.h:23
GSM_AT_Charset
Definition: atgen.h:90
GSM_MemoryType
Definition: gammu-memory.h:31
int MotorolaMemorySize
Definition: atgen.h:308
GSM_AT_Feature SIMSMSMemory
Definition: atgen.h:336
GSM_AT_SMS_Modes SMSMode
Definition: atgen.h:348
GSM_Error ATGEN_ParseReply(GSM_StateMachine *s, const unsigned char *input, const char *format,...)
GSM_File file
Definition: atgen.h:382
GSM_AT_Feature SIMSaveSMS
Definition: atgen.h:320
gboolean Mode
Definition: atgen.h:377
GSM_AT_Charset_Preference
Definition: atgen.h:156
GSM_AT_SMS_Cache * SMSCache
Definition: atgen.h:390
GSM_AT_Charset NormalCharset
Definition: atgen.h:292
GSM_AT_Feature
Definition: atgen.h:186
int CNMIDeliverProcedure
Definition: atgen.h:366
GSM_Error ATGEN_WaitFor(GSM_StateMachine *s, const char *cmd, size_t len, int type, int time, GSM_Phone_RequestID request)
int FirstCalendarPos
Definition: atgen.h:313
gboolean SMSMemoryWrite
Definition: atgen.h:344
int FirstMemoryEntry
Definition: atgen.h:272
size_t NumberLength
Definition: atgen.h:305
GSM_SamsungCalendar SamsungCalendar
Definition: atgen.h:304
Definition: atgen.h:73
GSM_AT_Charset UnicodeCharset
Definition: atgen.h:288
GSM_AT_Feature PBK_SPBR
Definition: atgen.h:302
GSM_CalendarStatus CalendarStatus
Definition: atgen.h:315
GSM_AT_Manufacturer
Definition: atgen.h:66
GSM_AT_Charset IRACharset
Definition: atgen.h:296
int MotorolaFirstMemoryEntry
Definition: atgen.h:276
GSM_Error ATGEN_DispatchMessage(GSM_StateMachine *s)
Definition: atgen.h:67
gboolean EncodedCommands
Definition: atgen.h:284
GSM_MemoryType PBKMemory
Definition: atgen.h:260
GSM_AT_NeededMemoryInfo
Definition: atgen.h:197
GSM_AT_Reply_State ReplyState
Definition: atgen.h:247
GSM_AT_Charset Charset
Definition: atgen.h:280
GSM_Phone_RequestID
Definition: gsmreply.h:25
GSM_AT_Manufacturer Manufacturer
Definition: atgen.h:239
#define AT_PBK_MAX_MEMORIES
Definition: atgen.h:233
gboolean MotorolaSMS
Definition: atgen.h:332