author | zautrix <zautrix> | 2004-10-05 11:13:51 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-05 11:13:51 (UTC) |
commit | 50ab40e1e02ad7c65c17a78d08116a808b1257aa (patch) (unidiff) | |
tree | 0d1939e2297fa7bbd8e1f2030f154463854164c6 /gammu/emb/common/phone/nokia/dct3 | |
parent | cf8616f64f20e5448d4ff644f7cc15750cf3f85f (diff) | |
download | kdepimpi-50ab40e1e02ad7c65c17a78d08116a808b1257aa.zip kdepimpi-50ab40e1e02ad7c65c17a78d08116a808b1257aa.tar.gz kdepimpi-50ab40e1e02ad7c65c17a78d08116a808b1257aa.tar.bz2 |
updated to latest gammu version
Diffstat (limited to 'gammu/emb/common/phone/nokia/dct3') (more/less context) (ignore whitespace changes)
-rw-r--r-- | gammu/emb/common/phone/nokia/dct3/dct3func.c | 16 | ||||
-rw-r--r-- | gammu/emb/common/phone/nokia/dct3/dct3func.h | 2 | ||||
-rw-r--r-- | gammu/emb/common/phone/nokia/dct3/n6110.c | 17 | ||||
-rw-r--r-- | gammu/emb/common/phone/nokia/dct3/n7110.c | 9 | ||||
-rw-r--r-- | gammu/emb/common/phone/nokia/dct3/n9210.c | 3 |
5 files changed, 33 insertions, 14 deletions
diff --git a/gammu/emb/common/phone/nokia/dct3/dct3func.c b/gammu/emb/common/phone/nokia/dct3/dct3func.c index beef33c..17cd0a4 100644 --- a/gammu/emb/common/phone/nokia/dct3/dct3func.c +++ b/gammu/emb/common/phone/nokia/dct3/dct3func.c | |||
@@ -1,27 +1,30 @@ | |||
1 | /* (c) 2001-2004 by Marcin Wiacek */ | 1 | /* (c) 2001-2004 by Marcin Wiacek */ |
2 | /* based on some work from Markus Plail, Pavel Janik, others and Gnokii */ | ||
3 | /* resetting DCT4 phones settings (c) by Walek */ | 2 | /* resetting DCT4 phones settings (c) by Walek */ |
3 | /* based on some Markus Plail, Pavel Janik & others work from Gnokii (www.gnokii.org) | ||
4 | * (C) 1999-2000 Hugh Blemings & Pavel Janik ml. (C) 2001-2004 Pawel Kot | ||
5 | * GNU GPL version 2 or later | ||
6 | */ | ||
4 | 7 | ||
5 | #include <string.h> /* memcpy only */ | 8 | #include <string.h> /* memcpy only */ |
6 | #include <stdio.h> | 9 | #include <stdio.h> |
7 | #include <ctype.h> | 10 | #include <ctype.h> |
8 | 11 | ||
9 | #include "../../../gsmstate.h" | 12 | #include "../../../gsmstate.h" |
10 | #include "../../../misc/coding/coding.h" | 13 | #include "../../../misc/coding/coding.h" |
11 | #include "../../../service/sms/gsmsms.h" | 14 | #include "../../../service/sms/gsmsms.h" |
12 | #include "../../pfunc.h" | 15 | #include "../../pfunc.h" |
13 | #include "../nfunc.h" | 16 | #include "../nfunc.h" |
14 | #include "dct3func.h" | 17 | #include "dct3func.h" |
15 | 18 | ||
16 | #ifdef GSM_ENABLE_NOKIA_DCT3 | 19 | #ifdef GSM_ENABLE_NOKIA_DCT3 |
17 | 20 | ||
18 | GSM_Error DCT3_DeleteWAPBookmark(GSM_StateMachine *s, GSM_WAPBookmark *bookmark) | 21 | GSM_Error DCT3_DeleteWAPBookmark(GSM_StateMachine *s, GSM_WAPBookmark *bookmark) |
19 | { | 22 | { |
20 | GSM_Error error; | 23 | GSM_Error error; |
21 | 24 | ||
22 | /* We have to enable WAP frames in phone */ | 25 | /* We have to enable WAP frames in phone */ |
23 | error=DCT3DCT4_EnableWAPFunctions(s); | 26 | error=DCT3DCT4_EnableWAPFunctions(s); |
24 | if (error!=ERR_NONE) return error; | 27 | if (error!=ERR_NONE) return error; |
25 | 28 | ||
26 | return DCT3DCT4_DeleteWAPBookmarkPart(s,bookmark); | 29 | return DCT3DCT4_DeleteWAPBookmarkPart(s,bookmark); |
27 | } | 30 | } |
@@ -373,115 +376,116 @@ GSM_Error DCT3_SetAlarm(GSM_StateMachine *s, GSM_Alarm *alarm, unsigned char msg | |||
373 | req[8] = alarm->DateTime.Hour; | 376 | req[8] = alarm->DateTime.Hour; |
374 | req[9] = alarm->DateTime.Minute; | 377 | req[9] = alarm->DateTime.Minute; |
375 | 378 | ||
376 | smprintf(s, "Setting alarm\n"); | 379 | smprintf(s, "Setting alarm\n"); |
377 | return GSM_WaitFor (s, req, 11, msgtype, 4, ID_SetAlarm); | 380 | return GSM_WaitFor (s, req, 11, msgtype, 4, ID_SetAlarm); |
378 | } | 381 | } |
379 | 382 | ||
380 | GSM_Error DCT3_ReplyGetSMSC(GSM_Protocol_Message msg, GSM_StateMachine *s) | 383 | GSM_Error DCT3_ReplyGetSMSC(GSM_Protocol_Message msg, GSM_StateMachine *s) |
381 | { | 384 | { |
382 | int i; | 385 | int i; |
383 | GSM_Phone_Data*Data = &s->Phone.Data; | 386 | GSM_Phone_Data*Data = &s->Phone.Data; |
384 | 387 | ||
385 | switch (msg.Buffer[3]) { | 388 | switch (msg.Buffer[3]) { |
386 | case 0x34: | 389 | case 0x34: |
387 | smprintf(s, "SMSC received\n"); | 390 | smprintf(s, "SMSC received\n"); |
388 | Data->SMSC->Format = SMS_FORMAT_Text; | 391 | Data->SMSC->Format = SMS_FORMAT_Text; |
389 | switch (msg.Buffer[6]) { | 392 | switch (msg.Buffer[6]) { |
390 | case 0x00: Data->SMSC->Format = SMS_FORMAT_Text; break; | 393 | case 0x00: Data->SMSC->Format = SMS_FORMAT_Text; break; |
391 | case 0x22: Data->SMSC->Format = SMS_FORMAT_Fax; break; | 394 | case 0x22: Data->SMSC->Format = SMS_FORMAT_Fax; break; |
392 | case 0x26: Data->SMSC->Format = SMS_FORMAT_Pager;break; | 395 | case 0x26: Data->SMSC->Format = SMS_FORMAT_Pager;break; |
393 | case 0x32: Data->SMSC->Format = SMS_FORMAT_Email;break; | 396 | case 0x32: Data->SMSC->Format = SMS_FORMAT_Email;break; |
394 | } | 397 | } |
395 | Data->SMSC->Validity.Format = SMS_Validity_RelativeFormat; | 398 | Data->SMSC->Validity.Format = SMS_Validity_RelativeFormat; |
396 | Data->SMSC->Validity.Relative= msg.Buffer[8]; | 399 | Data->SMSC->Validity.Relative= msg.Buffer[8]; |
400 | if (msg.Buffer[8] == 0x00) Data->SMSC->Validity.Relative = SMS_VALID_Max_Time; | ||
397 | 401 | ||
398 | i=33; | 402 | i=33; |
399 | while (msg.Buffer[i]!=0) {i++;} | 403 | while (msg.Buffer[i]!=0) {i++;} |
400 | i=i-33; | 404 | i=i-33; |
401 | if (i>GSM_MAX_SMSC_NAME_LENGTH) { | 405 | if (i>GSM_MAX_SMSC_NAME_LENGTH) { |
402 | smprintf(s, "Too long name\n"); | 406 | smprintf(s, "Too long name\n"); |
403 | return ERR_UNKNOWNRESPONSE; | 407 | return ERR_UNKNOWNRESPONSE; |
404 | } | 408 | } |
405 | EncodeUnicode(Data->SMSC->Name,msg.Buffer+33,i); | 409 | EncodeUnicode(Data->SMSC->Name,msg.Buffer+33,i); |
406 | smprintf(s, "Name \"%s\"\n", DecodeUnicodeString(Data->SMSC->Name)); | 410 | smprintf(s, "Name \"%s\"\n", DecodeUnicodeString(Data->SMSC->Name)); |
407 | 411 | ||
408 | GSM_UnpackSemiOctetNumber(Data->SMSC->DefaultNumber,msg.Buffer+9,true); | 412 | GSM_UnpackSemiOctetNumber(Data->SMSC->DefaultNumber,msg.Buffer+9,true); |
409 | smprintf(s, "Default number \"%s\"\n", DecodeUnicodeString(Data->SMSC->DefaultNumber)); | 413 | smprintf(s, "Default number \"%s\"\n", DecodeUnicodeString(Data->SMSC->DefaultNumber)); |
410 | 414 | ||
411 | GSM_UnpackSemiOctetNumber(Data->SMSC->Number,msg.Buffer+21,false); | 415 | GSM_UnpackSemiOctetNumber(Data->SMSC->Number,msg.Buffer+21,false); |
412 | smprintf(s, "Number \"%s\"\n", DecodeUnicodeString(Data->SMSC->Number)); | 416 | smprintf(s, "Number \"%s\"\n", DecodeUnicodeString(Data->SMSC->Number)); |
413 | 417 | ||
414 | return ERR_NONE; | 418 | return ERR_NONE; |
415 | case 0x35: | 419 | case 0x35: |
416 | smprintf(s, "Getting SMSC failed\n"); | 420 | smprintf(s, "Getting SMSC failed\n"); |
417 | return ERR_INVALIDLOCATION; | 421 | return ERR_INVALIDLOCATION; |
418 | } | 422 | } |
419 | return ERR_UNKNOWNRESPONSE; | 423 | return ERR_UNKNOWNRESPONSE; |
420 | } | 424 | } |
421 | 425 | ||
422 | GSM_Error DCT3_GetSMSC(GSM_StateMachine *s, GSM_SMSC *smsc) | 426 | GSM_Error DCT3_GetSMSC(GSM_StateMachine *s, GSM_SMSC *smsc) |
423 | { | 427 | { |
424 | unsigned char req[] = {N6110_FRAME_HEADER, 0x33, 0x64, | 428 | unsigned char req[] = {N6110_FRAME_HEADER, 0x33, 0x64, |
425 | 0x00}; /* Location */ | 429 | 0x00}; /* Location */ |
426 | 430 | ||
427 | if (smsc->Location==0x00) return ERR_INVALIDLOCATION; | 431 | if (smsc->Location==0x00) return ERR_INVALIDLOCATION; |
428 | 432 | ||
429 | req[5]=smsc->Location; | 433 | req[5]=smsc->Location; |
430 | 434 | ||
431 | s->Phone.Data.SMSC=smsc; | 435 | s->Phone.Data.SMSC=smsc; |
432 | smprintf(s, "Getting SMSC\n"); | 436 | smprintf(s, "Getting SMSC\n"); |
433 | return GSM_WaitFor (s, req, 6, 0x02, 4, ID_GetSMSC); | 437 | return GSM_WaitFor (s, req, 6, 0x02, 4, ID_GetSMSC); |
434 | } | 438 | } |
435 | 439 | ||
436 | GSM_Error DCT3_ReplyGetNetworkInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) | 440 | GSM_Error DCT3_ReplyGetNetworkInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) |
437 | { | 441 | { |
438 | int count; | 442 | int count; |
439 | GSM_Phone_Data*Data = &s->Phone.Data; | 443 | GSM_Phone_Data*Data = &s->Phone.Data; |
440 | #ifdef DEBUG | 444 | #ifdef DEBUG |
441 | GSM_NetworkInfo NetInfo; | 445 | GSM_NetworkInfo NetInfo; |
442 | char name[100]; | 446 | char name[100]; |
443 | 447 | ||
444 | smprintf(s, "Network info received\n"); | 448 | smprintf(s, "Network info received\n"); |
445 | smprintf(s, " Status : "); | 449 | smprintf(s, "Status : "); |
446 | switch (msg.Buffer[8]) { | 450 | switch (msg.Buffer[8]) { |
447 | case 0x01: smprintf(s, "home network"); break; | 451 | case 0x01: smprintf(s, "home network"); break; |
448 | case 0x02: smprintf(s, "roaming network"); break; | 452 | case 0x02: smprintf(s, "roaming network"); break; |
449 | case 0x03: smprintf(s, "requesting network"); break; | 453 | case 0x03: smprintf(s, "requesting network"); break; |
450 | case 0x04: smprintf(s, "not registered in the network");break; | 454 | case 0x04: smprintf(s, "not registered in the network");break; |
451 | default : smprintf(s, "unknown"); | 455 | default : smprintf(s, "unknown"); |
452 | } | 456 | } |
453 | smprintf(s, "\n"); | 457 | smprintf(s, "\n"); |
454 | smprintf(s, "Network selection : %s\n", msg.Buffer[9]==1?"manual":"automatic"); | 458 | smprintf(s, "Network selection : %s\n", msg.Buffer[9]==1?"manual":"automatic"); |
455 | if (msg.Buffer[8]<0x03) { | 459 | if (msg.Buffer[8]<0x03) { |
456 | sprintf(NetInfo.CID, "%02x%02x", msg.Buffer[10], msg.Buffer[11]); | 460 | sprintf(NetInfo.CID, "%02x%02x", msg.Buffer[10], msg.Buffer[11]); |
457 | smprintf(s, "CID : %s\n", NetInfo.CID); | 461 | smprintf(s, "CID : %s\n", NetInfo.CID); |
458 | 462 | ||
459 | sprintf(NetInfo.LAC, "%02x%02x", msg.Buffer[12], msg.Buffer[13]); | 463 | sprintf(NetInfo.LAC, "%02x%02x", msg.Buffer[12], msg.Buffer[13]); |
460 | smprintf(s, "LAC : %s\n", NetInfo.LAC); | 464 | smprintf(s, "LAC : %s\n", NetInfo.LAC); |
461 | 465 | ||
462 | smprintf(s, "Network code : %s\n", NetInfo.NetworkCode); | ||
463 | NOKIA_DecodeNetworkCode(msg.Buffer+14,NetInfo.NetworkCode); | 466 | NOKIA_DecodeNetworkCode(msg.Buffer+14,NetInfo.NetworkCode); |
467 | smprintf(s, "Network code : %s\n", NetInfo.NetworkCode); | ||
464 | smprintf(s, "Network name for Gammu : %s ", | 468 | smprintf(s, "Network name for Gammu : %s ", |
465 | DecodeUnicodeString(GSM_GetNetworkName(NetInfo.NetworkCode))); | 469 | DecodeUnicodeString(GSM_GetNetworkName(NetInfo.NetworkCode))); |
466 | smprintf(s, "(%s)\n",DecodeUnicodeString(GSM_GetCountryName(NetInfo.NetworkCode))); | 470 | smprintf(s, "(%s)\n",DecodeUnicodeString(GSM_GetCountryName(NetInfo.NetworkCode))); |
467 | 471 | ||
468 | if (msg.Length>18) { | 472 | if (msg.Length>18) { |
469 | if (msg.Buffer[18]==0x00) { | 473 | if (msg.Buffer[18]==0x00) { |
470 | /* In 6210 name is in "normal" Unicode */ | 474 | /* In 6210 name is in "normal" Unicode */ |
471 | memcpy(name,msg.Buffer+18,msg.Buffer[17]*2); | 475 | memcpy(name,msg.Buffer+18,msg.Buffer[17]*2); |
472 | name[msg.Buffer[17]*2]=0x00; | 476 | name[msg.Buffer[17]*2]=0x00; |
473 | name[msg.Buffer[17]*2+1]=0x00; | 477 | name[msg.Buffer[17]*2+1]=0x00; |
474 | smprintf(s, "Network name for phone : %s\n",DecodeUnicodeString(name)); | 478 | smprintf(s, "Network name for phone : %s\n",DecodeUnicodeString(name)); |
475 | } else { | 479 | } else { |
476 | /* In 9210 first 0x00 is cut from Unicode string */ | 480 | /* In 9210 first 0x00 is cut from Unicode string */ |
477 | name[0] = 0; | 481 | name[0] = 0; |
478 | memcpy(name+1,msg.Buffer+18,msg.Buffer[17]*2); | 482 | memcpy(name+1,msg.Buffer+18,msg.Buffer[17]*2); |
479 | name[msg.Buffer[17]*2+1]=0x00; | 483 | name[msg.Buffer[17]*2+1]=0x00; |
480 | name[msg.Buffer[17]*2+2]=0x00; | 484 | name[msg.Buffer[17]*2+2]=0x00; |
481 | smprintf(s, "Network name for phone : %s\n",DecodeUnicodeString(name)); | 485 | smprintf(s, "Network name for phone : %s\n",DecodeUnicodeString(name)); |
482 | } | 486 | } |
483 | } | 487 | } |
484 | } | 488 | } |
485 | #endif | 489 | #endif |
486 | if (Data->RequestID==ID_GetNetworkInfo) { | 490 | if (Data->RequestID==ID_GetNetworkInfo) { |
487 | Data->NetworkInfo->NetworkName[0] = 0x00; | 491 | Data->NetworkInfo->NetworkName[0] = 0x00; |
@@ -1187,53 +1191,53 @@ GSM_Error DCT3_SetWAPSettings(GSM_StateMachine *s, GSM_MultiWAPSettings *setting | |||
1187 | pos++; | 1191 | pos++; |
1188 | if (loc3 != -1) { | 1192 | if (loc3 != -1) { |
1189 | /* Service number or IP address */ | 1193 | /* Service number or IP address */ |
1190 | pos += NOKIA_SetUnicodeString(s, SetReq2 + pos, settings->Settings[loc3].Service, false); | 1194 | pos += NOKIA_SetUnicodeString(s, SetReq2 + pos, settings->Settings[loc3].Service, false); |
1191 | /* Code number */ | 1195 | /* Code number */ |
1192 | pos += NOKIA_SetUnicodeString(s, SetReq2 + pos, settings->Settings[loc3].Code, false); | 1196 | pos += NOKIA_SetUnicodeString(s, SetReq2 + pos, settings->Settings[loc3].Code, false); |
1193 | } else pos+=2; | 1197 | } else pos+=2; |
1194 | memcpy(SetReq2 + pos, "\x80\x00\x00\x00\x00\x00\x00\x00", 8); | 1198 | memcpy(SetReq2 + pos, "\x80\x00\x00\x00\x00\x00\x00\x00", 8); |
1195 | pos += 8; | 1199 | pos += 8; |
1196 | smprintf(s, "Writing WAP settings part 2 (USSD bearer)\n"); | 1200 | smprintf(s, "Writing WAP settings part 2 (USSD bearer)\n"); |
1197 | error=GSM_WaitFor (s, SetReq2, pos, 0x3f, 4, ID_SetConnectSet); | 1201 | error=GSM_WaitFor (s, SetReq2, pos, 0x3f, 4, ID_SetConnectSet); |
1198 | if (error != ERR_NONE) return error; | 1202 | if (error != ERR_NONE) return error; |
1199 | } | 1203 | } |
1200 | error = DCT3DCT4_SetActiveConnectSet(s, settings); | 1204 | error = DCT3DCT4_SetActiveConnectSet(s, settings); |
1201 | if (error != ERR_NONE) return error; | 1205 | if (error != ERR_NONE) return error; |
1202 | 1206 | ||
1203 | return DCT3DCT4_DisableConnectionFunctions(s); | 1207 | return DCT3DCT4_DisableConnectionFunctions(s); |
1204 | } | 1208 | } |
1205 | 1209 | ||
1206 | GSM_Error DCT3_ReplySendSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s) | 1210 | GSM_Error DCT3_ReplySendSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s) |
1207 | { | 1211 | { |
1208 | switch (msg.Buffer[3]) { | 1212 | switch (msg.Buffer[3]) { |
1209 | case 0x02: | 1213 | case 0x02: |
1210 | smprintf(s, "SMS sent OK\n"); | 1214 | smprintf(s, "SMS sent OK\n"); |
1211 | if (s->User.SendSMSStatus!=NULL) s->User.SendSMSStatus(s->CurrentConfig->Device,0,0); | 1215 | if (s->User.SendSMSStatus!=NULL) s->User.SendSMSStatus(s->CurrentConfig->Device,0,msg.Buffer[5]); |
1212 | return ERR_NONE; | 1216 | return ERR_NONE; |
1213 | case 0x03: | 1217 | case 0x03: |
1214 | smprintf(s, "Error %i\n",msg.Buffer[6]); | 1218 | smprintf(s, "Error %i\n",msg.Buffer[6]); |
1215 | if (s->User.SendSMSStatus!=NULL) s->User.SendSMSStatus(s->CurrentConfig->Device,msg.Buffer[6],0); | 1219 | if (s->User.SendSMSStatus!=NULL) s->User.SendSMSStatus(s->CurrentConfig->Device,msg.Buffer[6],-1); |
1216 | return ERR_NONE; | 1220 | return ERR_NONE; |
1217 | } | 1221 | } |
1218 | return ERR_UNKNOWNRESPONSE; | 1222 | return ERR_UNKNOWNRESPONSE; |
1219 | } | 1223 | } |
1220 | 1224 | ||
1221 | GSM_Error DCT3_SendSMSMessage(GSM_StateMachine *s, GSM_SMSMessage *sms) | 1225 | GSM_Error DCT3_SendSMSMessage(GSM_StateMachine *s, GSM_SMSMessage *sms) |
1222 | { | 1226 | { |
1223 | int length; | 1227 | int length; |
1224 | GSM_Error error; | 1228 | GSM_Error error; |
1225 | unsigned char req[256] = {N6110_FRAME_HEADER, 0x01, 0x02, 0x00}; | 1229 | unsigned char req[256] = {N6110_FRAME_HEADER, 0x01, 0x02, 0x00}; |
1226 | 1230 | ||
1227 | error=PHONE_EncodeSMSFrame(s,sms,req+6,PHONE_SMSSubmit,&length, true); | 1231 | error=PHONE_EncodeSMSFrame(s,sms,req+6,PHONE_SMSSubmit,&length, true); |
1228 | if (error != ERR_NONE) return error; | 1232 | if (error != ERR_NONE) return error; |
1229 | 1233 | ||
1230 | smprintf(s, "Sending sms\n"); | 1234 | smprintf(s, "Sending sms\n"); |
1231 | return s->Protocol.Functions->WriteMessage(s, req, 6+length, 0x02); | 1235 | return s->Protocol.Functions->WriteMessage(s, req, 6+length, 0x02); |
1232 | } | 1236 | } |
1233 | 1237 | ||
1234 | GSM_Error DCT3_ReplyNetmonitor(GSM_Protocol_Message msg, GSM_StateMachine *s) | 1238 | GSM_Error DCT3_ReplyNetmonitor(GSM_Protocol_Message msg, GSM_StateMachine *s) |
1235 | { | 1239 | { |
1236 | switch (msg.Buffer[3]) { | 1240 | switch (msg.Buffer[3]) { |
1237 | case 0x00: | 1241 | case 0x00: |
1238 | smprintf(s, "Netmonitor correctly set\n"); | 1242 | smprintf(s, "Netmonitor correctly set\n"); |
1239 | break; | 1243 | break; |
diff --git a/gammu/emb/common/phone/nokia/dct3/dct3func.h b/gammu/emb/common/phone/nokia/dct3/dct3func.h index 66b67ec..18b2026 100644 --- a/gammu/emb/common/phone/nokia/dct3/dct3func.h +++ b/gammu/emb/common/phone/nokia/dct3/dct3func.h | |||
@@ -1,29 +1,31 @@ | |||
1 | /* (c) 2002-2003 by Marcin Wiacek */ | 1 | /* (c) 2002-2003 by Marcin Wiacek */ |
2 | 2 | ||
3 | #ifndef phone_nokia_dct3_h | 3 | #ifndef phone_nokia_dct3_h |
4 | #define phone_nokia_dct3_h | 4 | #define phone_nokia_dct3_h |
5 | 5 | ||
6 | #include "../ncommon.h" | ||
7 | |||
6 | GSM_Error DCT3_ReplyPressKey (GSM_Protocol_Message msg, GSM_StateMachine *s); | 8 | GSM_Error DCT3_ReplyPressKey (GSM_Protocol_Message msg, GSM_StateMachine *s); |
7 | GSM_Error DCT3_ReplyPlayTone (GSM_Protocol_Message msg, GSM_StateMachine *s); | 9 | GSM_Error DCT3_ReplyPlayTone (GSM_Protocol_Message msg, GSM_StateMachine *s); |
8 | GSM_Error DCT3_ReplyEnableSecurity(GSM_Protocol_Message msg, GSM_StateMachine *s); | 10 | GSM_Error DCT3_ReplyEnableSecurity(GSM_Protocol_Message msg, GSM_StateMachine *s); |
9 | GSM_Error DCT3_ReplyGetIMEI (GSM_Protocol_Message msg, GSM_StateMachine *s); | 11 | GSM_Error DCT3_ReplyGetIMEI (GSM_Protocol_Message msg, GSM_StateMachine *s); |
10 | GSM_Error DCT3_ReplyGetSMSC (GSM_Protocol_Message msg, GSM_StateMachine *s); | 12 | GSM_Error DCT3_ReplyGetSMSC (GSM_Protocol_Message msg, GSM_StateMachine *s); |
11 | GSM_Error DCT3_ReplySIMLogin (GSM_Protocol_Message msg, GSM_StateMachine *s); | 13 | GSM_Error DCT3_ReplySIMLogin (GSM_Protocol_Message msg, GSM_StateMachine *s); |
12 | GSM_Error DCT3_ReplySIMLogout (GSM_Protocol_Message msg, GSM_StateMachine *s); | 14 | GSM_Error DCT3_ReplySIMLogout (GSM_Protocol_Message msg, GSM_StateMachine *s); |
13 | GSM_Error DCT3_ReplyGetDateTime (GSM_Protocol_Message msg, GSM_StateMachine *s); | 15 | GSM_Error DCT3_ReplyGetDateTime (GSM_Protocol_Message msg, GSM_StateMachine *s); |
14 | GSM_Error DCT3_ReplyGetAlarm (GSM_Protocol_Message msg, GSM_StateMachine *s); | 16 | GSM_Error DCT3_ReplyGetAlarm (GSM_Protocol_Message msg, GSM_StateMachine *s); |
15 | GSM_Error DCT3_ReplySetDateTime (GSM_Protocol_Message msg, GSM_StateMachine *s); | 17 | GSM_Error DCT3_ReplySetDateTime (GSM_Protocol_Message msg, GSM_StateMachine *s); |
16 | GSM_Error DCT3_ReplySetAlarm (GSM_Protocol_Message msg, GSM_StateMachine *s); | 18 | GSM_Error DCT3_ReplySetAlarm (GSM_Protocol_Message msg, GSM_StateMachine *s); |
17 | GSM_Error DCT3_ReplyDialCommand (GSM_Protocol_Message msg, GSM_StateMachine *s); | 19 | GSM_Error DCT3_ReplyDialCommand (GSM_Protocol_Message msg, GSM_StateMachine *s); |
18 | GSM_Error DCT3_ReplyGetWAPBookmark(GSM_Protocol_Message msg, GSM_StateMachine *s); | 20 | GSM_Error DCT3_ReplyGetWAPBookmark(GSM_Protocol_Message msg, GSM_StateMachine *s); |
19 | GSM_Error DCT3_ReplyGetNetworkInfo(GSM_Protocol_Message msg, GSM_StateMachine *s); | 21 | GSM_Error DCT3_ReplyGetNetworkInfo(GSM_Protocol_Message msg, GSM_StateMachine *s); |
20 | GSM_Error DCT3_ReplySendSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s); | 22 | GSM_Error DCT3_ReplySendSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s); |
21 | GSM_Error DCT3_ReplySetSMSC (GSM_Protocol_Message msg, GSM_StateMachine *s); | 23 | GSM_Error DCT3_ReplySetSMSC (GSM_Protocol_Message msg, GSM_StateMachine *s); |
22 | GSM_Error DCT3_ReplyGetWAPSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); | 24 | GSM_Error DCT3_ReplyGetWAPSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); |
23 | GSM_Error DCT3_ReplySetWAPSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); | 25 | GSM_Error DCT3_ReplySetWAPSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); |
24 | GSM_Error DCT3_ReplyNetmonitor (GSM_Protocol_Message msg, GSM_StateMachine *s); | 26 | GSM_Error DCT3_ReplyNetmonitor (GSM_Protocol_Message msg, GSM_StateMachine *s); |
25 | GSM_Error DCT3_ReplyDeleteSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s); | 27 | GSM_Error DCT3_ReplyDeleteSMSMessage(GSM_Protocol_Message msg, GSM_StateMachine *s); |
26 | GSM_Error N71_92_ReplyGetSignalQuality(GSM_Protocol_Message msg, GSM_StateMachine *s); | 28 | GSM_Error N71_92_ReplyGetSignalQuality(GSM_Protocol_Message msg, GSM_StateMachine *s); |
27 | GSM_Error N71_92_ReplyGetBatteryCharge(GSM_Protocol_Message msg, GSM_StateMachine *s); | 29 | GSM_Error N71_92_ReplyGetBatteryCharge(GSM_Protocol_Message msg, GSM_StateMachine *s); |
28 | GSM_Error N71_92_ReplyPhoneSetting(GSM_Protocol_Message msg, GSM_StateMachine *s); | 30 | GSM_Error N71_92_ReplyPhoneSetting(GSM_Protocol_Message msg, GSM_StateMachine *s); |
29 | GSM_Error N61_71_ReplyResetPhoneSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); | 31 | GSM_Error N61_71_ReplyResetPhoneSettings(GSM_Protocol_Message msg, GSM_StateMachine *s); |
diff --git a/gammu/emb/common/phone/nokia/dct3/n6110.c b/gammu/emb/common/phone/nokia/dct3/n6110.c index 263d12b..dac6c12 100644 --- a/gammu/emb/common/phone/nokia/dct3/n6110.c +++ b/gammu/emb/common/phone/nokia/dct3/n6110.c | |||
@@ -1,28 +1,30 @@ | |||
1 | /* (c) 2001-2004 by Marcin Wiacek */ | 1 | /* (c) 2001-2004 by Marcin Wiacek */ |
2 | /* based on some work from Markus Plail and Gnokii */ | ||
3 | /* Authentication function (c) 1999 or earlier by Pavel Janik */ | ||
4 | /* 5210 calendar IDs by Frederick Ros */ | 2 | /* 5210 calendar IDs by Frederick Ros */ |
3 | /* based on some Markus Plail, Pavel Janik & others work from Gnokii (www.gnokii.org) | ||
4 | * (C) 1999-2000 Hugh Blemings & Pavel Janik ml. (C) 2001-2004 Pawel Kot | ||
5 | * GNU GPL version 2 or later | ||
6 | */ | ||
5 | 7 | ||
6 | #include "../../../gsmstate.h" | 8 | #include "../../../gsmstate.h" |
7 | 9 | ||
8 | #ifdef GSM_ENABLE_NOKIA6110 | 10 | #ifdef GSM_ENABLE_NOKIA6110 |
9 | 11 | ||
10 | #include <string.h> | 12 | #include <string.h> |
11 | 13 | ||
12 | #include "../../../../cfg/config.h" | 14 | #include "../../../../cfg/config.h" |
13 | #include "../../../misc/coding/coding.h" | 15 | #include "../../../misc/coding/coding.h" |
14 | #include "../../../service/sms/gsmsms.h" | 16 | #include "../../../service/sms/gsmsms.h" |
15 | #include "../../../gsmcomon.h" | 17 | #include "../../../gsmcomon.h" |
16 | #include "../../pfunc.h" | 18 | #include "../../pfunc.h" |
17 | #include "../nfunc.h" | 19 | #include "../nfunc.h" |
18 | #include "n6110.h" | 20 | #include "n6110.h" |
19 | #include "dct3func.h" | 21 | #include "dct3func.h" |
20 | 22 | ||
21 | static unsigned char N6110_MEMORY_TYPES[] = { | 23 | static unsigned char N6110_MEMORY_TYPES[] = { |
22 | MEM_ME, 0x02, | 24 | MEM_ME, 0x02, |
23 | MEM_SM, 0x03, | 25 | MEM_SM, 0x03, |
24 | MEM_ON, 0x05, | 26 | MEM_ON, 0x05, |
25 | MEM_DC, 0x07, | 27 | MEM_DC, 0x07, |
26 | MEM_RC, 0x08, | 28 | MEM_RC, 0x08, |
27 | MEM_MC, 0x09, | 29 | MEM_MC, 0x09, |
28 | MEM_VM, 0x0b, | 30 | MEM_VM, 0x0b, |
@@ -106,48 +108,49 @@ static void N6110_EncodeUnicode(GSM_StateMachine *s, unsigned char *dest, const | |||
106 | if (N6110_Lang_Table[i].Lang == 0) break; | 108 | if (N6110_Lang_Table[i].Lang == 0) break; |
107 | if (N6110_Lang_Table[i].Lang == Priv->PhoneLanguage && | 109 | if (N6110_Lang_Table[i].Lang == Priv->PhoneLanguage && |
108 | N6110_Lang_Table[i].Phone == src[i_len]) { | 110 | N6110_Lang_Table[i].Phone == src[i_len]) { |
109 | dest[o_len*2] = N6110_Lang_Table[i].Unicode1; | 111 | dest[o_len*2] = N6110_Lang_Table[i].Unicode1; |
110 | dest[(o_len*2)+1] = N6110_Lang_Table[i].Unicode2; | 112 | dest[(o_len*2)+1] = N6110_Lang_Table[i].Unicode2; |
111 | i_len++; | 113 | i_len++; |
112 | found = true; | 114 | found = true; |
113 | break; | 115 | break; |
114 | } | 116 | } |
115 | i++; | 117 | i++; |
116 | } | 118 | } |
117 | } | 119 | } |
118 | if (!found) { | 120 | if (!found) { |
119 | i_len += EncodeWithUnicodeAlphabet(&src[i_len], &wc); | 121 | i_len += EncodeWithUnicodeAlphabet(&src[i_len], &wc); |
120 | dest[o_len*2] = (wc >> 8) & 0xff; | 122 | dest[o_len*2] = (wc >> 8) & 0xff; |
121 | dest[(o_len*2)+1] = wc & 0xff; | 123 | dest[(o_len*2)+1] = wc & 0xff; |
122 | } | 124 | } |
123 | } | 125 | } |
124 | dest[o_len*2] = 0; | 126 | dest[o_len*2] = 0; |
125 | dest[(o_len*2)+1] = 0; | 127 | dest[(o_len*2)+1] = 0; |
126 | } | 128 | } |
127 | 129 | ||
128 | #ifndef ENABLE_LGPL | 130 | #ifndef ENABLE_LGPL |
129 | 131 | ||
132 | /* Pavel Janik */ | ||
130 | /* This function provides Nokia authentication protocol. | 133 | /* This function provides Nokia authentication protocol. |
131 | * Nokia authentication protocol is used in the communication between Nokia | 134 | * Nokia authentication protocol is used in the communication between Nokia |
132 | * mobile phones (e.g. Nokia 6110) and Nokia Cellular Data Suite software, | 135 | * mobile phones (e.g. Nokia 6110) and Nokia Cellular Data Suite software, |
133 | * commercially sold by Nokia Corp. | 136 | * commercially sold by Nokia Corp. |
134 | * The authentication scheme is based on the token send by the phone to the | 137 | * The authentication scheme is based on the token send by the phone to the |
135 | * software. The software does it's magic (see the function | 138 | * software. The software does it's magic (see the function |
136 | * N6110_GetNokiaAuthentication) and returns the result back to the phone. | 139 | * N6110_GetNokiaAuthentication) and returns the result back to the phone. |
137 | * If the result is correct the phone responds with the message "Accessory | 140 | * If the result is correct the phone responds with the message "Accessory |
138 | * connected!" displayed on the LCD. Otherwise it will display "Accessory not | 141 | * connected!" displayed on the LCD. Otherwise it will display "Accessory not |
139 | * supported" and some functions will not be available for use (?). | 142 | * supported" and some functions will not be available for use (?). |
140 | * The specification of the protocol is not publicly available, no comment. | 143 | * The specification of the protocol is not publicly available, no comment. |
141 | */ | 144 | */ |
142 | static void N6110_GetNokiaAuthentication(unsigned char *Imei, unsigned char *MagicBytes, unsigned char *MagicResponse) | 145 | static void N6110_GetNokiaAuthentication(unsigned char *Imei, unsigned char *MagicBytes, unsigned char *MagicResponse) |
143 | { | 146 | { |
144 | int i, j, CRC=0; | 147 | int i, j, CRC=0; |
145 | unsigned char Temp[16]; /* This is our temporary working area. */ | 148 | unsigned char Temp[16]; /* This is our temporary working area. */ |
146 | 149 | ||
147 | /* Here we put FAC (Final Assembly Code) and serial number into our area. */ | 150 | /* Here we put FAC (Final Assembly Code) and serial number into our area. */ |
148 | Temp[0] = Imei[6]; Temp[1] = Imei[7]; | 151 | Temp[0] = Imei[6]; Temp[1] = Imei[7]; |
149 | Temp[2] = Imei[8]; Temp[3] = Imei[9]; | 152 | Temp[2] = Imei[8]; Temp[3] = Imei[9]; |
150 | Temp[4] = Imei[10]; Temp[5] = Imei[11]; | 153 | Temp[4] = Imei[10]; Temp[5] = Imei[11]; |
151 | Temp[6] = Imei[12]; Temp[7] = Imei[13]; | 154 | Temp[6] = Imei[12]; Temp[7] = Imei[13]; |
152 | 155 | ||
153 | /* And now the TAC (Type Approval Code). */ | 156 | /* And now the TAC (Type Approval Code). */ |
@@ -803,48 +806,49 @@ static GSM_Error N6110_SetRingtone(GSM_StateMachine *s, GSM_Ringtone *Ringtone, | |||
803 | return DCT3_GetNetworkInfo(s,&NetInfo); | 806 | return DCT3_GetNetworkInfo(s,&NetInfo); |
804 | } else { | 807 | } else { |
805 | return ERR_NOTSUPPORTED; | 808 | return ERR_NOTSUPPORTED; |
806 | } | 809 | } |
807 | } | 810 | } |
808 | *maxlength=GSM_EncodeNokiaRTTLRingtone(*Ringtone, req+7, &size); | 811 | *maxlength=GSM_EncodeNokiaRTTLRingtone(*Ringtone, req+7, &size); |
809 | req[4] = Ringtone->Location - 1; | 812 | req[4] = Ringtone->Location - 1; |
810 | smprintf(s, "Setting ringtone\n"); | 813 | smprintf(s, "Setting ringtone\n"); |
811 | return GSM_WaitFor (s, req, 7 + size, 0x05, 4, ID_SetRingtone); | 814 | return GSM_WaitFor (s, req, 7 + size, 0x05, 4, ID_SetRingtone); |
812 | case RING_NOKIABINARY: | 815 | case RING_NOKIABINARY: |
813 | error=DCT3_EnableSecurity (s, 0x01); | 816 | error=DCT3_EnableSecurity (s, 0x01); |
814 | if (error!=ERR_NONE) return error; | 817 | if (error!=ERR_NONE) return error; |
815 | memcpy(reqBin+current,DecodeUnicodeString(Ringtone->Name),UnicodeLength(Ringtone->Name)); | 818 | memcpy(reqBin+current,DecodeUnicodeString(Ringtone->Name),UnicodeLength(Ringtone->Name)); |
816 | current += UnicodeLength(Ringtone->Name); | 819 | current += UnicodeLength(Ringtone->Name); |
817 | reqBin[current++] = 0x00; | 820 | reqBin[current++] = 0x00; |
818 | reqBin[current++] = 0x00; | 821 | reqBin[current++] = 0x00; |
819 | reqBin[current++] = 0x00;/*xxx*/ | 822 | reqBin[current++] = 0x00;/*xxx*/ |
820 | memcpy(reqBin+current,Ringtone->NokiaBinary.Frame,Ringtone->NokiaBinary.Length); | 823 | memcpy(reqBin+current,Ringtone->NokiaBinary.Frame,Ringtone->NokiaBinary.Length); |
821 | current=current+Ringtone->NokiaBinary.Length; | 824 | current=current+Ringtone->NokiaBinary.Length; |
822 | reqBin[3]=Ringtone->Location-1; | 825 | reqBin[3]=Ringtone->Location-1; |
823 | if (!strcmp(s->Phone.Data.ModelInfo->model,"3210")) reqBin[5]=0x10; | 826 | if (!strcmp(s->Phone.Data.ModelInfo->model,"3210")) reqBin[5]=0x10; |
824 | smprintf(s, "Setting binary ringtone\n"); | 827 | smprintf(s, "Setting binary ringtone\n"); |
825 | return GSM_WaitFor (s, reqBin, current, 0x40, 4, ID_SetRingtone); | 828 | return GSM_WaitFor (s, reqBin, current, 0x40, 4, ID_SetRingtone); |
826 | case RING_MIDI: | 829 | case RING_MIDI: |
830 | case RING_MMF: | ||
827 | return ERR_NOTSUPPORTED; | 831 | return ERR_NOTSUPPORTED; |
828 | } | 832 | } |
829 | return ERR_NOTSUPPORTED; | 833 | return ERR_NOTSUPPORTED; |
830 | } | 834 | } |
831 | 835 | ||
832 | static GSM_Error N6110_ReplyGetOpLogo(GSM_Protocol_Message msg, GSM_StateMachine *s) | 836 | static GSM_Error N6110_ReplyGetOpLogo(GSM_Protocol_Message msg, GSM_StateMachine *s) |
833 | { | 837 | { |
834 | int count=5; | 838 | int count=5; |
835 | GSM_Phone_Data *Data = &s->Phone.Data; | 839 | GSM_Phone_Data *Data = &s->Phone.Data; |
836 | 840 | ||
837 | smprintf(s, "Operator logo received\n"); | 841 | smprintf(s, "Operator logo received\n"); |
838 | NOKIA_DecodeNetworkCode(msg.Buffer+count,Data->Bitmap->NetworkCode); | 842 | NOKIA_DecodeNetworkCode(msg.Buffer+count,Data->Bitmap->NetworkCode); |
839 | count = count + 3; | 843 | count = count + 3; |
840 | smprintf(s, "Network code : %s\n", Data->Bitmap->NetworkCode); | 844 | smprintf(s, "Network code : %s\n", Data->Bitmap->NetworkCode); |
841 | smprintf(s, "Network name for Gammu : %s ", | 845 | smprintf(s, "Network name for Gammu : %s ", |
842 | DecodeUnicodeString(GSM_GetNetworkName(Data->Bitmap->NetworkCode))); | 846 | DecodeUnicodeString(GSM_GetNetworkName(Data->Bitmap->NetworkCode))); |
843 | smprintf(s, "(%s)\n",DecodeUnicodeString(GSM_GetCountryName(Data->Bitmap->NetworkCode))); | 847 | smprintf(s, "(%s)\n",DecodeUnicodeString(GSM_GetCountryName(Data->Bitmap->NetworkCode))); |
844 | 848 | ||
845 | count = count + 3; /* We ignore size */ | 849 | count = count + 3; /* We ignore size */ |
846 | Data->Bitmap->BitmapWidth = msg.Buffer[count++]; | 850 | Data->Bitmap->BitmapWidth = msg.Buffer[count++]; |
847 | Data->Bitmap->BitmapHeight = msg.Buffer[count++]; | 851 | Data->Bitmap->BitmapHeight = msg.Buffer[count++]; |
848 | count++; | 852 | count++; |
849 | PHONE_DecodeBitmap(GSM_NokiaOperatorLogo,msg.Buffer+count,Data->Bitmap); | 853 | PHONE_DecodeBitmap(GSM_NokiaOperatorLogo,msg.Buffer+count,Data->Bitmap); |
850 | return ERR_NONE; | 854 | return ERR_NONE; |
@@ -1503,85 +1507,87 @@ static GSM_Error N6110_ReplyGetRingtone(GSM_Protocol_Message msg, GSM_StateMachi | |||
1503 | while (true) { | 1507 | while (true) { |
1504 | if (start!=0) { | 1508 | if (start!=0) { |
1505 | if (msg.Buffer[i]==0x07 && msg.Buffer[i+1]==0x0b) { | 1509 | if (msg.Buffer[i]==0x07 && msg.Buffer[i+1]==0x0b) { |
1506 | end=i+2; break; | 1510 | end=i+2; break; |
1507 | } | 1511 | } |
1508 | if (msg.Buffer[i]==0x0e && msg.Buffer[i+1]==0x0b) { | 1512 | if (msg.Buffer[i]==0x0e && msg.Buffer[i+1]==0x0b) { |
1509 | end=i+2; break; | 1513 | end=i+2; break; |
1510 | } | 1514 | } |
1511 | } else { | 1515 | } else { |
1512 | if (msg.Buffer[i]==0x02 && msg.Buffer[i+1]==0xfc && msg.Buffer[i+2]==0x09) { | 1516 | if (msg.Buffer[i]==0x02 && msg.Buffer[i+1]==0xfc && msg.Buffer[i+2]==0x09) { |
1513 | start = i; | 1517 | start = i; |
1514 | } | 1518 | } |
1515 | } | 1519 | } |
1516 | i++; | 1520 | i++; |
1517 | if (i==msg.Length-3) return ERR_EMPTY; | 1521 | if (i==msg.Length-3) return ERR_EMPTY; |
1518 | } | 1522 | } |
1519 | /* Copying frame */ | 1523 | /* Copying frame */ |
1520 | memcpy(Data->Ringtone->NokiaBinary.Frame,msg.Buffer+start,end-start); | 1524 | memcpy(Data->Ringtone->NokiaBinary.Frame,msg.Buffer+start,end-start); |
1521 | Data->Ringtone->NokiaBinary.Length=end-start; | 1525 | Data->Ringtone->NokiaBinary.Length=end-start; |
1522 | #ifdef DEBUG | 1526 | #ifdef DEBUG |
1523 | if (di.dl == DL_TEXTALL || di.dl == DL_TEXTALLDATE) DumpMessage(di.df, di.dl, Data->Ringtone->NokiaBinary.Frame, Data->Ringtone->NokiaBinary.Length); | 1527 | if (di.dl == DL_TEXTALL || di.dl == DL_TEXTALLDATE) DumpMessage(di.df, di.dl, Data->Ringtone->NokiaBinary.Frame, Data->Ringtone->NokiaBinary.Length); |
1524 | #endif | 1528 | #endif |
1525 | return ERR_NONE; | 1529 | return ERR_NONE; |
1526 | case RING_MIDI: | 1530 | case RING_MIDI: |
1531 | case RING_MMF: | ||
1527 | return ERR_NOTSUPPORTED; | 1532 | return ERR_NOTSUPPORTED; |
1528 | } | 1533 | } |
1529 | smprintf(s, "Ringtone format is %i\n",Data->Ringtone->Format); | 1534 | smprintf(s, "Ringtone format is %i\n",Data->Ringtone->Format); |
1530 | break; | 1535 | break; |
1531 | default: | 1536 | default: |
1532 | smprintf(s, "Invalid location. Too high ?\n"); | 1537 | smprintf(s, "Invalid location. Too high ?\n"); |
1533 | return ERR_INVALIDLOCATION; | 1538 | return ERR_INVALIDLOCATION; |
1534 | } | 1539 | } |
1535 | return ERR_UNKNOWNRESPONSE; | 1540 | return ERR_UNKNOWNRESPONSE; |
1536 | } | 1541 | } |
1537 | 1542 | ||
1538 | static GSM_Error N6110_GetRingtone(GSM_StateMachine *s, GSM_Ringtone *Ringtone, bool PhoneRingtone) | 1543 | static GSM_Error N6110_GetRingtone(GSM_StateMachine *s, GSM_Ringtone *Ringtone, bool PhoneRingtone) |
1539 | { | 1544 | { |
1540 | GSM_Error error; | 1545 | GSM_Error error; |
1541 | unsigned char req[] = {0x00, 0x01, 0x9e, | 1546 | unsigned char req[] = {0x00, 0x01, 0x9e, |
1542 | 0x00}; /* location */ | 1547 | 0x00}; /* location */ |
1543 | 1548 | ||
1544 | if (PhoneRingtone) return ERR_NOTSUPPORTED; | 1549 | if (PhoneRingtone) return ERR_NOTSUPPORTED; |
1545 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_NORING)) return ERR_NOTSUPPORTED; | 1550 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_NORING)) return ERR_NOTSUPPORTED; |
1546 | if (Ringtone->Location == 0) return ERR_INVALIDLOCATION; | 1551 | if (Ringtone->Location == 0) return ERR_INVALIDLOCATION; |
1547 | 1552 | ||
1548 | if (Ringtone->Format == 0x00) { | 1553 | if (Ringtone->Format == 0x00) { |
1549 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) { | 1554 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) { |
1550 | Ringtone->Format = RING_NOTETONE; | 1555 | Ringtone->Format = RING_NOTETONE; |
1551 | } else { | 1556 | } else { |
1552 | Ringtone->Format = RING_NOKIABINARY; | 1557 | Ringtone->Format = RING_NOKIABINARY; |
1553 | } | 1558 | } |
1554 | } | 1559 | } |
1555 | 1560 | ||
1556 | switch (Ringtone->Format) { | 1561 | switch (Ringtone->Format) { |
1557 | case RING_NOTETONE: | 1562 | case RING_NOTETONE: |
1558 | if (!IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) return ERR_NOTSUPPORTED; | 1563 | if (!IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) return ERR_NOTSUPPORTED; |
1559 | break; | 1564 | break; |
1560 | case RING_NOKIABINARY: | 1565 | case RING_NOKIABINARY: |
1561 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) return ERR_NOTSUPPORTED; | 1566 | if (IsPhoneFeatureAvailable(s->Phone.Data.ModelInfo,F_RING_SM)) return ERR_NOTSUPPORTED; |
1562 | break; | 1567 | break; |
1563 | case RING_MIDI: | 1568 | case RING_MIDI: |
1569 | case RING_MMF: | ||
1564 | return ERR_NOTSUPPORTED; | 1570 | return ERR_NOTSUPPORTED; |
1565 | } | 1571 | } |
1566 | 1572 | ||
1567 | error=DCT3_EnableSecurity (s, 0x01); | 1573 | error=DCT3_EnableSecurity (s, 0x01); |
1568 | if (error!=ERR_NONE) return error; | 1574 | if (error!=ERR_NONE) return error; |
1569 | 1575 | ||
1570 | req[3]=Ringtone->Location-1; | 1576 | req[3]=Ringtone->Location-1; |
1571 | s->Phone.Data.Ringtone=Ringtone; | 1577 | s->Phone.Data.Ringtone=Ringtone; |
1572 | smprintf(s, "Getting (binary) ringtone\n"); | 1578 | smprintf(s, "Getting (binary) ringtone\n"); |
1573 | return GSM_WaitFor (s, req, 4, 0x40, 4, ID_GetRingtone); | 1579 | return GSM_WaitFor (s, req, 4, 0x40, 4, ID_GetRingtone); |
1574 | } | 1580 | } |
1575 | 1581 | ||
1576 | static GSM_Error N6110_ReplyGetSecurityStatus(GSM_Protocol_Message msg, GSM_StateMachine *s) | 1582 | static GSM_Error N6110_ReplyGetSecurityStatus(GSM_Protocol_Message msg, GSM_StateMachine *s) |
1577 | { | 1583 | { |
1578 | *s->Phone.Data.SecurityStatus = msg.Buffer[4]; | 1584 | *s->Phone.Data.SecurityStatus = msg.Buffer[4]; |
1579 | 1585 | ||
1580 | #ifdef DEBUG | 1586 | #ifdef DEBUG |
1581 | smprintf(s, "Security code status\n"); | 1587 | smprintf(s, "Security code status\n"); |
1582 | switch(msg.Buffer[4]) { | 1588 | switch(msg.Buffer[4]) { |
1583 | case SEC_SecurityCode: smprintf(s, "waiting for Security Code.\n"); break; | 1589 | case SEC_SecurityCode: smprintf(s, "waiting for Security Code.\n"); break; |
1584 | case SEC_Pin : smprintf(s, "waiting for PIN.\n"); break; | 1590 | case SEC_Pin : smprintf(s, "waiting for PIN.\n"); break; |
1585 | case SEC_Pin2 : smprintf(s, "waiting for PIN2.\n"); break; | 1591 | case SEC_Pin2 : smprintf(s, "waiting for PIN2.\n"); break; |
1586 | case SEC_Puk : smprintf(s, "waiting for PUK.\n"); break; | 1592 | case SEC_Puk : smprintf(s, "waiting for PUK.\n"); break; |
1587 | case SEC_Puk2 : smprintf(s, "waiting for PUK2.\n"); break; | 1593 | case SEC_Puk2 : smprintf(s, "waiting for PUK2.\n"); break; |
@@ -2422,50 +2428,50 @@ static GSM_Error N6110_GetNextCalendarNote(GSM_StateMachine *s, GSM_CalendarEntr | |||
2422 | Priv->LastCalendarPos++; | 2428 | Priv->LastCalendarPos++; |
2423 | } | 2429 | } |
2424 | 2430 | ||
2425 | Note->Location = Priv->LastCalendarPos; | 2431 | Note->Location = Priv->LastCalendarPos; |
2426 | req[4] = Priv->LastCalendarPos; | 2432 | req[4] = Priv->LastCalendarPos; |
2427 | 2433 | ||
2428 | s->Phone.Data.Cal=Note; | 2434 | s->Phone.Data.Cal=Note; |
2429 | smprintf(s, "Getting calendar note\n"); | 2435 | smprintf(s, "Getting calendar note\n"); |
2430 | error=GSM_WaitFor (s, req, 5, 0x13, 4, ID_GetCalendarNote); | 2436 | error=GSM_WaitFor (s, req, 5, 0x13, 4, ID_GetCalendarNote); |
2431 | 2437 | ||
2432 | GSM_CalendarFindDefaultTextTimeAlarmPhoneRecurrance(Note, &Text, &Time, &Alarm, &Phone, &Recurrance, &EndTime, &Location); | 2438 | GSM_CalendarFindDefaultTextTimeAlarmPhoneRecurrance(Note, &Text, &Time, &Alarm, &Phone, &Recurrance, &EndTime, &Location); |
2433 | /* 2090 year is set for example in 3310 */ | 2439 | /* 2090 year is set for example in 3310 */ |
2434 | if (error == ERR_NONE && Note->Entries[Time].Date.Year == 2090) { | 2440 | if (error == ERR_NONE && Note->Entries[Time].Date.Year == 2090) { |
2435 | error=N6110_GetDateTime(s, &date_time); | 2441 | error=N6110_GetDateTime(s, &date_time); |
2436 | if (error == ERR_NONE) Note->Entries[Time].Date.Year = date_time.Year; | 2442 | if (error == ERR_NONE) Note->Entries[Time].Date.Year = date_time.Year; |
2437 | } | 2443 | } |
2438 | return error; | 2444 | return error; |
2439 | } | 2445 | } |
2440 | 2446 | ||
2441 | GSM_Error N6110_ReplyUSSDInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) | 2447 | GSM_Error N6110_ReplyUSSDInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) |
2442 | { | 2448 | { |
2443 | unsigned char buffer[2000],buffer2[4000]; | 2449 | unsigned char buffer[2000],buffer2[4000]; |
2444 | int tmp; | 2450 | int tmp; |
2445 | 2451 | ||
2446 | tmp=GSM_UnpackEightBitsToSeven(0, 82, 82, msg.Buffer+8, buffer); | 2452 | tmp=GSM_UnpackEightBitsToSeven(0, msg.Buffer[7], 82, msg.Buffer+8, buffer); |
2447 | msg.Buffer[tmp] = 0; | 2453 | buffer[tmp] = 0; |
2448 | 2454 | ||
2449 | smprintf(s, "USSD reply: \"%s\"\n",buffer); | 2455 | smprintf(s, "USSD reply: \"%s\"\n",buffer); |
2450 | 2456 | ||
2451 | if (s->Phone.Data.EnableIncomingUSSD && s->User.IncomingUSSD!=NULL) { | 2457 | if (s->Phone.Data.EnableIncomingUSSD && s->User.IncomingUSSD!=NULL) { |
2452 | EncodeUnicode(buffer2,buffer,strlen(buffer)); | 2458 | EncodeUnicode(buffer2,buffer,strlen(buffer)); |
2453 | s->User.IncomingUSSD(s->CurrentConfig->Device, buffer2); | 2459 | s->User.IncomingUSSD(s->CurrentConfig->Device, buffer2); |
2454 | } | 2460 | } |
2455 | 2461 | ||
2456 | return ERR_NONE; | 2462 | return ERR_NONE; |
2457 | } | 2463 | } |
2458 | 2464 | ||
2459 | GSM_Error N6110_AnswerCall(GSM_StateMachine *s, int ID, bool all) | 2465 | GSM_Error N6110_AnswerCall(GSM_StateMachine *s, int ID, bool all) |
2460 | { | 2466 | { |
2461 | GSM_Error error; | 2467 | GSM_Error error; |
2462 | unsigned char req1[] = {N6110_FRAME_HEADER, 0x42, 0x05, 0x01, | 2468 | unsigned char req1[] = {N6110_FRAME_HEADER, 0x42, 0x05, 0x01, |
2463 | 0x07, 0xa2, 0x88, 0x81, 0x21, 0x15, 0x63, 0xa8, | 2469 | 0x07, 0xa2, 0x88, 0x81, 0x21, 0x15, 0x63, 0xa8, |
2464 | 0x00, 0x00, 0x07, 0xa3, 0xb8, 0x81, 0x20, 0x15, | 2470 | 0x00, 0x00, 0x07, 0xa3, 0xb8, 0x81, 0x20, 0x15, |
2465 | 0x63, 0x80}; | 2471 | 0x63, 0x80}; |
2466 | 2472 | ||
2467 | if (!all) { | 2473 | if (!all) { |
2468 | smprintf(s, "Answering call part 1\n"); | 2474 | smprintf(s, "Answering call part 1\n"); |
2469 | error = GSM_WaitFor (s, req1, 24, 0x01, 5, ID_AnswerCall); | 2475 | error = GSM_WaitFor (s, req1, 24, 0x01, 5, ID_AnswerCall); |
2470 | if (error != ERR_NONE) return error; | 2476 | if (error != ERR_NONE) return error; |
2471 | return DCT3DCT4_AnswerCall(s,ID); | 2477 | return DCT3DCT4_AnswerCall(s,ID); |
@@ -2786,48 +2792,49 @@ GSM_Phone_Functions N6110Phone = { | |||
2786 | N6110_GetSignalQuality, | 2792 | N6110_GetSignalQuality, |
2787 | DCT3_GetNetworkInfo, | 2793 | DCT3_GetNetworkInfo, |
2788 | NOTSUPPORTED, /* GetCategory */ | 2794 | NOTSUPPORTED, /* GetCategory */ |
2789 | NOTSUPPORTED, /* AddCategory */ | 2795 | NOTSUPPORTED, /* AddCategory */ |
2790 | NOTSUPPORTED, /* GetCategoryStatus */ | 2796 | NOTSUPPORTED, /* GetCategoryStatus */ |
2791 | N6110_GetMemoryStatus, | 2797 | N6110_GetMemoryStatus, |
2792 | N6110_GetMemory, | 2798 | N6110_GetMemory, |
2793 | NOTIMPLEMENTED, /* GetNextMemory */ | 2799 | NOTIMPLEMENTED, /* GetNextMemory */ |
2794 | N6110_SetMemory, | 2800 | N6110_SetMemory, |
2795 | NOTIMPLEMENTED, /* AddMemory */ | 2801 | NOTIMPLEMENTED, /* AddMemory */ |
2796 | N6110_DeleteMemory, | 2802 | N6110_DeleteMemory, |
2797 | NOTIMPLEMENTED, /* DeleteAllMemory */ | 2803 | NOTIMPLEMENTED, /* DeleteAllMemory */ |
2798 | N6110_GetSpeedDial, | 2804 | N6110_GetSpeedDial, |
2799 | NOTIMPLEMENTED, /* SetSpeedDial */ | 2805 | NOTIMPLEMENTED, /* SetSpeedDial */ |
2800 | DCT3_GetSMSC, | 2806 | DCT3_GetSMSC, |
2801 | DCT3_SetSMSC, | 2807 | DCT3_SetSMSC, |
2802 | DCT3_GetSMSStatus, | 2808 | DCT3_GetSMSStatus, |
2803 | N6110_GetSMSMessage, | 2809 | N6110_GetSMSMessage, |
2804 | N6110_GetNextSMSMessage, | 2810 | N6110_GetNextSMSMessage, |
2805 | N6110_SetSMS, | 2811 | N6110_SetSMS, |
2806 | N6110_AddSMS, | 2812 | N6110_AddSMS, |
2807 | N6110_DeleteSMSMessage, | 2813 | N6110_DeleteSMSMessage, |
2808 | DCT3_SendSMSMessage, | 2814 | DCT3_SendSMSMessage, |
2809 | NOTSUPPORTED, /* SendSavedSMS */ | 2815 | NOTSUPPORTED, /* SendSavedSMS */ |
2816 | NOTSUPPORTED, /* SetFastSMSSending*/ | ||
2810 | NOKIA_SetIncomingSMS, | 2817 | NOKIA_SetIncomingSMS, |
2811 | DCT3_SetIncomingCB, | 2818 | DCT3_SetIncomingCB, |
2812 | PHONE_GetSMSFolders, | 2819 | PHONE_GetSMSFolders, |
2813 | NOTSUPPORTED, /* AddSMSFolder */ | 2820 | NOTSUPPORTED, /* AddSMSFolder */ |
2814 | NOTSUPPORTED, /* DeleteSMSFolder */ | 2821 | NOTSUPPORTED, /* DeleteSMSFolder */ |
2815 | N6110_DialVoice, | 2822 | N6110_DialVoice, |
2816 | N6110_AnswerCall, | 2823 | N6110_AnswerCall, |
2817 | DCT3_CancelCall, | 2824 | DCT3_CancelCall, |
2818 | N6110_HoldCall, | 2825 | N6110_HoldCall, |
2819 | N6110_UnholdCall, | 2826 | N6110_UnholdCall, |
2820 | N6110_ConferenceCall, | 2827 | N6110_ConferenceCall, |
2821 | N6110_SplitCall, | 2828 | N6110_SplitCall, |
2822 | N6110_TransferCall, | 2829 | N6110_TransferCall, |
2823 | N6110_SwitchCall, | 2830 | N6110_SwitchCall, |
2824 | DCT3DCT4_GetCallDivert, | 2831 | DCT3DCT4_GetCallDivert, |
2825 | DCT3DCT4_SetCallDivert, | 2832 | DCT3DCT4_SetCallDivert, |
2826 | DCT3DCT4_CancelAllDiverts, | 2833 | DCT3DCT4_CancelAllDiverts, |
2827 | NOKIA_SetIncomingCall, | 2834 | NOKIA_SetIncomingCall, |
2828 | NOKIA_SetIncomingUSSD, | 2835 | NOKIA_SetIncomingUSSD, |
2829 | DCT3DCT4_SendDTMF, | 2836 | DCT3DCT4_SendDTMF, |
2830 | N6110_GetRingtone, | 2837 | N6110_GetRingtone, |
2831 | N6110_SetRingtone, | 2838 | N6110_SetRingtone, |
2832 | NOTSUPPORTED, /* GetRingtonesInfo */ | 2839 | NOTSUPPORTED, /* GetRingtonesInfo */ |
2833 | NOTSUPPORTED, /* DeleteUserRingtones */ | 2840 | NOTSUPPORTED, /* DeleteUserRingtones */ |
@@ -2840,45 +2847,45 @@ GSM_Phone_Functions N6110Phone = { | |||
2840 | NOTSUPPORTED, /* GetMMSSettings */ | 2847 | NOTSUPPORTED, /* GetMMSSettings */ |
2841 | NOTSUPPORTED, /* SetMMSSettings */ | 2848 | NOTSUPPORTED, /* SetMMSSettings */ |
2842 | NOTSUPPORTED, /* GetSyncMLSettings*/ | 2849 | NOTSUPPORTED, /* GetSyncMLSettings*/ |
2843 | NOTSUPPORTED, /* SetSyncMLSettings*/ | 2850 | NOTSUPPORTED, /* SetSyncMLSettings*/ |
2844 | NOTSUPPORTED, /* GetChatSettings */ | 2851 | NOTSUPPORTED, /* GetChatSettings */ |
2845 | NOTSUPPORTED, /* SetChatSettings */ | 2852 | NOTSUPPORTED, /* SetChatSettings */ |
2846 | N6110_GetBitmap, | 2853 | N6110_GetBitmap, |
2847 | N6110_SetBitmap, | 2854 | N6110_SetBitmap, |
2848 | NOTSUPPORTED, /* GetToDoStatus */ | 2855 | NOTSUPPORTED, /* GetToDoStatus */ |
2849 | NOTSUPPORTED, /* GetToDo */ | 2856 | NOTSUPPORTED, /* GetToDo */ |
2850 | NOTSUPPORTED, /* GetNextToDo */ | 2857 | NOTSUPPORTED, /* GetNextToDo */ |
2851 | NOTSUPPORTED, /* SetToDo */ | 2858 | NOTSUPPORTED, /* SetToDo */ |
2852 | NOTSUPPORTED, /* AddToDo */ | 2859 | NOTSUPPORTED, /* AddToDo */ |
2853 | NOTSUPPORTED, /* DeleteToDo */ | 2860 | NOTSUPPORTED, /* DeleteToDo */ |
2854 | NOTSUPPORTED, /* DeleteAllToDo */ | 2861 | NOTSUPPORTED, /* DeleteAllToDo */ |
2855 | NOTIMPLEMENTED, /* GetCalendarStatus */ | 2862 | NOTIMPLEMENTED, /* GetCalendarStatus */ |
2856 | NOTIMPLEMENTED, /* GetCalendar */ | 2863 | NOTIMPLEMENTED, /* GetCalendar */ |
2857 | N6110_GetNextCalendarNote, | 2864 | N6110_GetNextCalendarNote, |
2858 | NOTIMPLEMENTED, /* SetCalendar */ | 2865 | NOTIMPLEMENTED, /* SetCalendar */ |
2859 | N6110_AddCalendarNote, | 2866 | N6110_AddCalendarNote, |
2860 | N6110_DeleteCalendarNote, | 2867 | N6110_DeleteCalendarNote, |
2861 | NOTIMPLEMENTED, /* DeleteAllCalendar */ | 2868 | NOTIMPLEMENTED, /* DeleteAllCalendar */ |
2862 | NOTSUPPORTED, /* GetCalendarSettings */ | 2869 | NOTSUPPORTED, /* GetCalendarSettings */ |
2863 | NOTSUPPORTED, /* SetCalendarSettings */ | 2870 | NOTSUPPORTED, /* SetCalendarSettings */ |
2864 | NOTSUPPORTED, /* GetNote */ | 2871 | NOTSUPPORTED, /* GetNextNote */ |
2865 | N6110_GetProfile, | 2872 | N6110_GetProfile, |
2866 | N6110_SetProfile, | 2873 | N6110_SetProfile, |
2867 | NOTSUPPORTED, /* GetFMStation */ | 2874 | NOTSUPPORTED, /* GetFMStation */ |
2868 | NOTSUPPORTED, /* SetFMStation */ | 2875 | NOTSUPPORTED, /* SetFMStation */ |
2869 | NOTSUPPORTED, /* ClearFMStations */ | 2876 | NOTSUPPORTED, /* ClearFMStations */ |
2870 | NOTSUPPORTED, /* GetNextFileFolder */ | 2877 | NOTSUPPORTED, /* GetNextFileFolder */ |
2871 | NOTSUPPORTED, /* GetFilePart */ | 2878 | NOTSUPPORTED, /* GetFilePart */ |
2872 | NOTSUPPORTED, /* AddFile */ | 2879 | NOTSUPPORTED, /* AddFile */ |
2873 | NOTSUPPORTED, /* GetFileSystemStatus */ | 2880 | NOTSUPPORTED, /* GetFileSystemStatus */ |
2874 | NOTSUPPORTED, /* DeleteFile */ | 2881 | NOTSUPPORTED, /* DeleteFile */ |
2875 | NOTSUPPORTED, /* AddFolder */ | 2882 | NOTSUPPORTED, /* AddFolder */ |
2876 | NOTSUPPORTED, /* GetGPRSAccessPoint */ | 2883 | NOTSUPPORTED, /* GetGPRSAccessPoint */ |
2877 | NOTSUPPORTED /* SetGPRSAccessPoint */ | 2884 | NOTSUPPORTED /* SetGPRSAccessPoint */ |
2878 | }; | 2885 | }; |
2879 | 2886 | ||
2880 | #endif | 2887 | #endif |
2881 | 2888 | ||
2882 | /* How should editor hadle tabs in this file? Add editor commands here. | 2889 | /* How should editor hadle tabs in this file? Add editor commands here. |
2883 | * vim: noexpandtab sw=8 ts=8 sts=8: | 2890 | * vim: noexpandtab sw=8 ts=8 sts=8: |
2884 | */ | 2891 | */ |
diff --git a/gammu/emb/common/phone/nokia/dct3/n7110.c b/gammu/emb/common/phone/nokia/dct3/n7110.c index 5a02c9c..b597f9b 100644 --- a/gammu/emb/common/phone/nokia/dct3/n7110.c +++ b/gammu/emb/common/phone/nokia/dct3/n7110.c | |||
@@ -1,26 +1,29 @@ | |||
1 | /* (c) 2001-2004 by Marcin Wiacek */ | 1 | /* (c) 2001-2004 by Marcin Wiacek */ |
2 | /* based on some work from Markus Plail and Gnokii */ | 2 | /* based on some Markus Plail work from Gnokii (www.gnokii.org) |
3 | * (C) 1999-2000 Hugh Blemings & Pavel Janik ml. (C) 2001-2004 Pawel Kot | ||
4 | * GNU GPL version 2 or later | ||
5 | */ | ||
3 | 6 | ||
4 | #include "../../../gsmstate.h" | 7 | #include "../../../gsmstate.h" |
5 | 8 | ||
6 | #ifdef GSM_ENABLE_NOKIA7110 | 9 | #ifdef GSM_ENABLE_NOKIA7110 |
7 | 10 | ||
8 | #include <string.h> | 11 | #include <string.h> |
9 | #include <time.h> | 12 | #include <time.h> |
10 | 13 | ||
11 | #include "../../../misc/coding/coding.h" | 14 | #include "../../../misc/coding/coding.h" |
12 | #include "../../../gsmcomon.h" | 15 | #include "../../../gsmcomon.h" |
13 | #include "../../../service/gsmlogo.h" | 16 | #include "../../../service/gsmlogo.h" |
14 | #include "../../pfunc.h" | 17 | #include "../../pfunc.h" |
15 | #include "../nfunc.h" | 18 | #include "../nfunc.h" |
16 | #include "../nfuncold.h" | 19 | #include "../nfuncold.h" |
17 | #include "n7110.h" | 20 | #include "n7110.h" |
18 | #include "dct3func.h" | 21 | #include "dct3func.h" |
19 | 22 | ||
20 | static GSM_Error N7110_GetAlarm(GSM_StateMachine *s, GSM_Alarm *alarm) | 23 | static GSM_Error N7110_GetAlarm(GSM_StateMachine *s, GSM_Alarm *alarm) |
21 | { | 24 | { |
22 | return DCT3_GetAlarm(s, alarm, 0x19); | 25 | return DCT3_GetAlarm(s, alarm, 0x19); |
23 | } | 26 | } |
24 | 27 | ||
25 | static GSM_Error N7110_SetAlarm(GSM_StateMachine *s, GSM_Alarm *alarm) | 28 | static GSM_Error N7110_SetAlarm(GSM_StateMachine *s, GSM_Alarm *alarm) |
26 | { | 29 | { |
@@ -505,48 +508,49 @@ static GSM_Error N7110_ReplyGetRingtone(GSM_Protocol_Message msg, GSM_StateMachi | |||
505 | case 0x24: | 508 | case 0x24: |
506 | smprintf(s, "Invalid location. Too high ?\n"); | 509 | smprintf(s, "Invalid location. Too high ?\n"); |
507 | return ERR_INVALIDLOCATION; | 510 | return ERR_INVALIDLOCATION; |
508 | } | 511 | } |
509 | return ERR_UNKNOWNRESPONSE; | 512 | return ERR_UNKNOWNRESPONSE; |
510 | } | 513 | } |
511 | 514 | ||
512 | static GSM_Error N7110_GetRingtone(GSM_StateMachine *s, GSM_Ringtone *Ringtone, bool PhoneRingtone) | 515 | static GSM_Error N7110_GetRingtone(GSM_StateMachine *s, GSM_Ringtone *Ringtone, bool PhoneRingtone) |
513 | { | 516 | { |
514 | unsigned char req[] = {N7110_FRAME_HEADER, 0x22, 0x00, 0x00}; | 517 | unsigned char req[] = {N7110_FRAME_HEADER, 0x22, 0x00, 0x00}; |
515 | 518 | ||
516 | if (PhoneRingtone) return ERR_NOTSUPPORTED; | 519 | if (PhoneRingtone) return ERR_NOTSUPPORTED; |
517 | if (Ringtone->Format == 0x00) Ringtone->Format = RING_NOKIABINARY; | 520 | if (Ringtone->Format == 0x00) Ringtone->Format = RING_NOKIABINARY; |
518 | 521 | ||
519 | switch (Ringtone->Format) { | 522 | switch (Ringtone->Format) { |
520 | case RING_NOTETONE: | 523 | case RING_NOTETONE: |
521 | /* In the future get binary and convert */ | 524 | /* In the future get binary and convert */ |
522 | return ERR_NOTSUPPORTED; | 525 | return ERR_NOTSUPPORTED; |
523 | case RING_NOKIABINARY: | 526 | case RING_NOKIABINARY: |
524 | req[5]=N7110_ReturnBinaryRingtoneLocation(s->Phone.Data.Model)+Ringtone->Location; | 527 | req[5]=N7110_ReturnBinaryRingtoneLocation(s->Phone.Data.Model)+Ringtone->Location; |
525 | s->Phone.Data.Ringtone=Ringtone; | 528 | s->Phone.Data.Ringtone=Ringtone; |
526 | smprintf(s, "Getting binary ringtone\n"); | 529 | smprintf(s, "Getting binary ringtone\n"); |
527 | return GSM_WaitFor (s, req, 6, 0x1f, 4, ID_GetRingtone); | 530 | return GSM_WaitFor (s, req, 6, 0x1f, 4, ID_GetRingtone); |
528 | case RING_MIDI: | 531 | case RING_MIDI: |
532 | case RING_MMF: | ||
529 | return ERR_NOTSUPPORTED; | 533 | return ERR_NOTSUPPORTED; |
530 | } | 534 | } |
531 | return ERR_NOTSUPPORTED; | 535 | return ERR_NOTSUPPORTED; |
532 | } | 536 | } |
533 | 537 | ||
534 | static GSM_Error N7110_ReplyGetPictureImageInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) | 538 | static GSM_Error N7110_ReplyGetPictureImageInfo(GSM_Protocol_Message msg, GSM_StateMachine *s) |
535 | { | 539 | { |
536 | int i; | 540 | int i; |
537 | GSM_Phone_N7110Data*Priv = &s->Phone.Data.Priv.N7110; | 541 | GSM_Phone_N7110Data*Priv = &s->Phone.Data.Priv.N7110; |
538 | 542 | ||
539 | smprintf(s, "Received info for Picture Images\n"); | 543 | smprintf(s, "Received info for Picture Images\n"); |
540 | smprintf(s, "Number : %i\n",msg.Buffer[4]*256+msg.Buffer[5]); | 544 | smprintf(s, "Number : %i\n",msg.Buffer[4]*256+msg.Buffer[5]); |
541 | smprintf(s, "Locations :"); | 545 | smprintf(s, "Locations :"); |
542 | Priv->LastPictureImageFolder.Number=msg.Buffer[4]*256+msg.Buffer[5]; | 546 | Priv->LastPictureImageFolder.Number=msg.Buffer[4]*256+msg.Buffer[5]; |
543 | for (i=0;i<Priv->LastPictureImageFolder.Number;i++) { | 547 | for (i=0;i<Priv->LastPictureImageFolder.Number;i++) { |
544 | Priv->LastPictureImageFolder.Location[i]=msg.Buffer[6+i*2]*256+msg.Buffer[7+i*2]; | 548 | Priv->LastPictureImageFolder.Location[i]=msg.Buffer[6+i*2]*256+msg.Buffer[7+i*2]; |
545 | smprintf(s, " %i",Priv->LastPictureImageFolder.Location[i]); | 549 | smprintf(s, " %i",Priv->LastPictureImageFolder.Location[i]); |
546 | } | 550 | } |
547 | smprintf(s, "\n"); | 551 | smprintf(s, "\n"); |
548 | return ERR_NONE; | 552 | return ERR_NONE; |
549 | } | 553 | } |
550 | 554 | ||
551 | static GSM_Error N7110_GetPictureImageLocation(GSM_StateMachine *s, GSM_Bitmap *Bitmap, unsigned char *folder, int *location) | 555 | static GSM_Error N7110_GetPictureImageLocation(GSM_StateMachine *s, GSM_Bitmap *Bitmap, unsigned char *folder, int *location) |
552 | { | 556 | { |
@@ -1626,48 +1630,49 @@ GSM_Phone_Functions N7110Phone = { | |||
1626 | N71_92_GetSignalQuality, | 1630 | N71_92_GetSignalQuality, |
1627 | DCT3_GetNetworkInfo, | 1631 | DCT3_GetNetworkInfo, |
1628 | NOTSUPPORTED, /* GetCategory */ | 1632 | NOTSUPPORTED, /* GetCategory */ |
1629 | NOTSUPPORTED, /* AddCategory */ | 1633 | NOTSUPPORTED, /* AddCategory */ |
1630 | NOTSUPPORTED, /* GetCategoryStatus */ | 1634 | NOTSUPPORTED, /* GetCategoryStatus */ |
1631 | N7110_GetMemoryStatus, | 1635 | N7110_GetMemoryStatus, |
1632 | N7110_GetMemory, | 1636 | N7110_GetMemory, |
1633 | NOTIMPLEMENTED, /* GetNextMemory */ | 1637 | NOTIMPLEMENTED, /* GetNextMemory */ |
1634 | N7110_SetMemory, | 1638 | N7110_SetMemory, |
1635 | NOTIMPLEMENTED, /* AddMemory */ | 1639 | NOTIMPLEMENTED, /* AddMemory */ |
1636 | N7110_DeleteMemory, | 1640 | N7110_DeleteMemory, |
1637 | NOTIMPLEMENTED, /* DeleteAllMemory */ | 1641 | NOTIMPLEMENTED, /* DeleteAllMemory */ |
1638 | N7110_GetSpeedDial, | 1642 | N7110_GetSpeedDial, |
1639 | NOTIMPLEMENTED, /* SetSpeedDial */ | 1643 | NOTIMPLEMENTED, /* SetSpeedDial */ |
1640 | DCT3_GetSMSC, | 1644 | DCT3_GetSMSC, |
1641 | DCT3_SetSMSC, | 1645 | DCT3_SetSMSC, |
1642 | N7110_GetSMSStatus, | 1646 | N7110_GetSMSStatus, |
1643 | N7110_GetSMSMessage, | 1647 | N7110_GetSMSMessage, |
1644 | N7110_GetNextSMSMessage, | 1648 | N7110_GetNextSMSMessage, |
1645 | N7110_SetSMS, | 1649 | N7110_SetSMS, |
1646 | N7110_AddSMS, | 1650 | N7110_AddSMS, |
1647 | N7110_DeleteSMS, | 1651 | N7110_DeleteSMS, |
1648 | DCT3_SendSMSMessage, | 1652 | DCT3_SendSMSMessage, |
1649 | NOTSUPPORTED, /* SendSavedSMS */ | 1653 | NOTSUPPORTED, /* SendSavedSMS */ |
1654 | NOTSUPPORTED, /* SetFastSMSSending*/ | ||
1650 | N7110_SetIncomingSMS, | 1655 | N7110_SetIncomingSMS, |
1651 | DCT3_SetIncomingCB, | 1656 | DCT3_SetIncomingCB, |
1652 | N7110_GetSMSFolders, | 1657 | N7110_GetSMSFolders, |
1653 | NOTIMPLEMENTED, /* AddSMSFolder */ | 1658 | NOTIMPLEMENTED, /* AddSMSFolder */ |
1654 | NOTIMPLEMENTED, /* DeleteSMSFolder */ | 1659 | NOTIMPLEMENTED, /* DeleteSMSFolder */ |
1655 | DCT3_DialVoice, | 1660 | DCT3_DialVoice, |
1656 | N7110_AnswerCall, | 1661 | N7110_AnswerCall, |
1657 | DCT3_CancelCall, | 1662 | DCT3_CancelCall, |
1658 | NOTIMPLEMENTED, /* HoldCall */ | 1663 | NOTIMPLEMENTED, /* HoldCall */ |
1659 | NOTIMPLEMENTED, /* UnholdCall */ | 1664 | NOTIMPLEMENTED, /* UnholdCall */ |
1660 | NOTIMPLEMENTED, /* ConferenceCall */ | 1665 | NOTIMPLEMENTED, /* ConferenceCall */ |
1661 | NOTIMPLEMENTED, /* SplitCall */ | 1666 | NOTIMPLEMENTED, /* SplitCall */ |
1662 | NOTIMPLEMENTED, /* TransferCall */ | 1667 | NOTIMPLEMENTED, /* TransferCall */ |
1663 | NOTIMPLEMENTED, /* SwitchCall */ | 1668 | NOTIMPLEMENTED, /* SwitchCall */ |
1664 | NOTSUPPORTED, /* GetCallDivert */ | 1669 | NOTSUPPORTED, /* GetCallDivert */ |
1665 | N7110_SetCallDivert, | 1670 | N7110_SetCallDivert, |
1666 | N7110_CancelAllDiverts, | 1671 | N7110_CancelAllDiverts, |
1667 | N7110_SetIncomingCall, | 1672 | N7110_SetIncomingCall, |
1668 | N7110_SetIncomingUSSD, | 1673 | N7110_SetIncomingUSSD, |
1669 | DCT3DCT4_SendDTMF, | 1674 | DCT3DCT4_SendDTMF, |
1670 | N7110_GetRingtone, | 1675 | N7110_GetRingtone, |
1671 | N7110_SetRingtone, | 1676 | N7110_SetRingtone, |
1672 | NOTSUPPORTED, /* GetRingtonesInfo*/ | 1677 | NOTSUPPORTED, /* GetRingtonesInfo*/ |
1673 | NOTSUPPORTED, /* DeleteUserRingtones*/ | 1678 | NOTSUPPORTED, /* DeleteUserRingtones*/ |
@@ -1680,45 +1685,45 @@ GSM_Phone_Functions N7110Phone = { | |||
1680 | NOTSUPPORTED, /* GetMMSSettings */ | 1685 | NOTSUPPORTED, /* GetMMSSettings */ |
1681 | NOTSUPPORTED, /* SetMMSSettings */ | 1686 | NOTSUPPORTED, /* SetMMSSettings */ |
1682 | NOTSUPPORTED, /* GetSyncMLSettings*/ | 1687 | NOTSUPPORTED, /* GetSyncMLSettings*/ |
1683 | NOTSUPPORTED, /* SetSyncMLSettings*/ | 1688 | NOTSUPPORTED, /* SetSyncMLSettings*/ |
1684 | NOTSUPPORTED, /* GetChatSettings */ | 1689 | NOTSUPPORTED, /* GetChatSettings */ |
1685 | NOTSUPPORTED, /* SetChatSettings */ | 1690 | NOTSUPPORTED, /* SetChatSettings */ |
1686 | N7110_GetBitmap, | 1691 | N7110_GetBitmap, |
1687 | N7110_SetBitmap, | 1692 | N7110_SetBitmap, |
1688 | NOTSUPPORTED, /* GetToDoStatus */ | 1693 | NOTSUPPORTED, /* GetToDoStatus */ |
1689 | NOTSUPPORTED, /* GetToDo */ | 1694 | NOTSUPPORTED, /* GetToDo */ |
1690 | NOTSUPPORTED, /* GetNextToDo */ | 1695 | NOTSUPPORTED, /* GetNextToDo */ |
1691 | NOTSUPPORTED, /* SetToDo */ | 1696 | NOTSUPPORTED, /* SetToDo */ |
1692 | NOTSUPPORTED, /* AddToDo */ | 1697 | NOTSUPPORTED, /* AddToDo */ |
1693 | NOTSUPPORTED, /* DeleteToDo */ | 1698 | NOTSUPPORTED, /* DeleteToDo */ |
1694 | NOTSUPPORTED, /* DeleteAllToDo */ | 1699 | NOTSUPPORTED, /* DeleteAllToDo */ |
1695 | N7110_GetCalendarStatus, | 1700 | N7110_GetCalendarStatus, |
1696 | NOTIMPLEMENTED, /* GetCalendar */ | 1701 | NOTIMPLEMENTED, /* GetCalendar */ |
1697 | N7110_GetNextCalendar, | 1702 | N7110_GetNextCalendar, |
1698 | NOTIMPLEMENTED, /* SetCalendar */ | 1703 | NOTIMPLEMENTED, /* SetCalendar */ |
1699 | N7110_AddCalendar, | 1704 | N7110_AddCalendar, |
1700 | N71_65_DelCalendar, | 1705 | N71_65_DelCalendar, |
1701 | NOTIMPLEMENTED, /* DeleteAllCalendar*/ | 1706 | NOTIMPLEMENTED, /* DeleteAllCalendar*/ |
1702 | NOTSUPPORTED, /* GetCalendarSettings*/ | 1707 | NOTSUPPORTED, /* GetCalendarSettings*/ |
1703 | NOTSUPPORTED, /* SetCalendarSettings*/ | 1708 | NOTSUPPORTED, /* SetCalendarSettings*/ |
1704 | NOTSUPPORTED, /* GetNote */ | 1709 | NOTSUPPORTED, /* GetNextNote */ |
1705 | N7110_GetProfile, | 1710 | N7110_GetProfile, |
1706 | N7110_SetProfile, | 1711 | N7110_SetProfile, |
1707 | NOTSUPPORTED, /* GetFMStation */ | 1712 | NOTSUPPORTED, /* GetFMStation */ |
1708 | NOTSUPPORTED, /* SetFMStation */ | 1713 | NOTSUPPORTED, /* SetFMStation */ |
1709 | NOTSUPPORTED, /* ClearFMStations */ | 1714 | NOTSUPPORTED, /* ClearFMStations */ |
1710 | NOTSUPPORTED, /* GetNextFileFolder*/ | 1715 | NOTSUPPORTED, /* GetNextFileFolder*/ |
1711 | NOTSUPPORTED, /* GetFilePart */ | 1716 | NOTSUPPORTED, /* GetFilePart */ |
1712 | NOTSUPPORTED, /* AddFile */ | 1717 | NOTSUPPORTED, /* AddFile */ |
1713 | NOTSUPPORTED, /* GetFileSystemStatus*/ | 1718 | NOTSUPPORTED, /* GetFileSystemStatus*/ |
1714 | NOTSUPPORTED, /* DeleteFile */ | 1719 | NOTSUPPORTED, /* DeleteFile */ |
1715 | NOTSUPPORTED, /* AddFolder */ | 1720 | NOTSUPPORTED, /* AddFolder */ |
1716 | NOTSUPPORTED, /* GetGPRSAccessPoint*/ | 1721 | NOTSUPPORTED, /* GetGPRSAccessPoint*/ |
1717 | NOTSUPPORTED /* SetGPRSAccessPoint*/ | 1722 | NOTSUPPORTED /* SetGPRSAccessPoint*/ |
1718 | }; | 1723 | }; |
1719 | 1724 | ||
1720 | #endif | 1725 | #endif |
1721 | 1726 | ||
1722 | /* How should editor hadle tabs in this file? Add editor commands here. | 1727 | /* How should editor hadle tabs in this file? Add editor commands here. |
1723 | * vim: noexpandtab sw=8 ts=8 sts=8: | 1728 | * vim: noexpandtab sw=8 ts=8 sts=8: |
1724 | */ | 1729 | */ |
diff --git a/gammu/emb/common/phone/nokia/dct3/n9210.c b/gammu/emb/common/phone/nokia/dct3/n9210.c index e82d530..ff71ad3 100644 --- a/gammu/emb/common/phone/nokia/dct3/n9210.c +++ b/gammu/emb/common/phone/nokia/dct3/n9210.c | |||
@@ -298,48 +298,49 @@ GSM_Phone_Functions N9210Phone = { | |||
298 | N71_92_GetSignalQuality, | 298 | N71_92_GetSignalQuality, |
299 | DCT3_GetNetworkInfo, | 299 | DCT3_GetNetworkInfo, |
300 | NOTSUPPORTED, /* GetCategory */ | 300 | NOTSUPPORTED, /* GetCategory */ |
301 | NOTSUPPORTED, /* AddCategory */ | 301 | NOTSUPPORTED, /* AddCategory */ |
302 | NOTSUPPORTED, /* GetCategoryStatus */ | 302 | NOTSUPPORTED, /* GetCategoryStatus */ |
303 | NOTIMPLEMENTED, /* GetMemoryStatus */ | 303 | NOTIMPLEMENTED, /* GetMemoryStatus */ |
304 | NOTIMPLEMENTED, /* GetMemory */ | 304 | NOTIMPLEMENTED, /* GetMemory */ |
305 | NOTIMPLEMENTED, /* GetNextMemory */ | 305 | NOTIMPLEMENTED, /* GetNextMemory */ |
306 | NOTIMPLEMENTED, /* SetMemory */ | 306 | NOTIMPLEMENTED, /* SetMemory */ |
307 | NOTIMPLEMENTED, /* AddMemory */ | 307 | NOTIMPLEMENTED, /* AddMemory */ |
308 | NOTIMPLEMENTED, /* DeleteMemory */ | 308 | NOTIMPLEMENTED, /* DeleteMemory */ |
309 | NOTIMPLEMENTED, /* DeleteAllMemory */ | 309 | NOTIMPLEMENTED, /* DeleteAllMemory */ |
310 | NOTIMPLEMENTED, /* GetSpeedDial */ | 310 | NOTIMPLEMENTED, /* GetSpeedDial */ |
311 | NOTIMPLEMENTED, /* SetSpeedDial */ | 311 | NOTIMPLEMENTED, /* SetSpeedDial */ |
312 | DCT3_GetSMSC, | 312 | DCT3_GetSMSC, |
313 | DCT3_SetSMSC, /* FIXME: test it */ | 313 | DCT3_SetSMSC, /* FIXME: test it */ |
314 | NOTIMPLEMENTED, /* GetSMSStatus */ | 314 | NOTIMPLEMENTED, /* GetSMSStatus */ |
315 | NOTIMPLEMENTED, /* GetSMS */ | 315 | NOTIMPLEMENTED, /* GetSMS */ |
316 | NOTIMPLEMENTED, /* GetNextSMS */ | 316 | NOTIMPLEMENTED, /* GetNextSMS */ |
317 | NOTIMPLEMENTED, /* SetSMS */ | 317 | NOTIMPLEMENTED, /* SetSMS */ |
318 | NOTIMPLEMENTED, /* AddSMS */ | 318 | NOTIMPLEMENTED, /* AddSMS */ |
319 | NOTIMPLEMENTED, /* DeleteSMS */ | 319 | NOTIMPLEMENTED, /* DeleteSMS */ |
320 | DCT3_SendSMSMessage, | 320 | DCT3_SendSMSMessage, |
321 | NOTSUPPORTED, /* SendSavedSMS */ | 321 | NOTSUPPORTED, /* SendSavedSMS */ |
322 | NOTSUPPORTED, /* SetFastSMSSending*/ | ||
322 | N9210_SetIncomingSMS, | 323 | N9210_SetIncomingSMS, |
323 | DCT3_SetIncomingCB, | 324 | DCT3_SetIncomingCB, |
324 | NOTIMPLEMENTED, /* GetSMSFolders */ | 325 | NOTIMPLEMENTED, /* GetSMSFolders */ |
325 | NOTSUPPORTED, /* AddSMSFolder */ | 326 | NOTSUPPORTED, /* AddSMSFolder */ |
326 | NOTSUPPORTED, /* DeleteSMSFolder */ | 327 | NOTSUPPORTED, /* DeleteSMSFolder */ |
327 | DCT3_DialVoice, | 328 | DCT3_DialVoice, |
328 | N9210_AnswerCall, | 329 | N9210_AnswerCall, |
329 | DCT3_CancelCall, | 330 | DCT3_CancelCall, |
330 | NOTSUPPORTED, /* HoldCall */ | 331 | NOTSUPPORTED, /* HoldCall */ |
331 | NOTSUPPORTED, /* UnholdCall */ | 332 | NOTSUPPORTED, /* UnholdCall */ |
332 | NOTSUPPORTED, /* ConferenceCall */ | 333 | NOTSUPPORTED, /* ConferenceCall */ |
333 | NOTSUPPORTED, /* SplitCall */ | 334 | NOTSUPPORTED, /* SplitCall */ |
334 | NOTSUPPORTED, /* TransferCall */ | 335 | NOTSUPPORTED, /* TransferCall */ |
335 | NOTSUPPORTED, /* SwitchCall */ | 336 | NOTSUPPORTED, /* SwitchCall */ |
336 | NOTSUPPORTED, /* GetCallDivert */ | 337 | NOTSUPPORTED, /* GetCallDivert */ |
337 | NOTSUPPORTED, /* SetCallDivert */ | 338 | NOTSUPPORTED, /* SetCallDivert */ |
338 | NOTSUPPORTED, /* CancelAllDiverts*/ | 339 | NOTSUPPORTED, /* CancelAllDiverts*/ |
339 | NOTSUPPORTED, /* SetIncomingCall */ | 340 | NOTSUPPORTED, /* SetIncomingCall */ |
340 | NOTIMPLEMENTED, /* SetIncomingUSSD */ | 341 | NOTIMPLEMENTED, /* SetIncomingUSSD */ |
341 | NOTSUPPORTED, /* SendDTMF */ | 342 | NOTSUPPORTED, /* SendDTMF */ |
342 | NOTIMPLEMENTED, /* GetRingtone */ | 343 | NOTIMPLEMENTED, /* GetRingtone */ |
343 | NOTIMPLEMENTED, /* SetRingtone */ | 344 | NOTIMPLEMENTED, /* SetRingtone */ |
344 | NOTSUPPORTED, /* GetRingtonesInfo*/ | 345 | NOTSUPPORTED, /* GetRingtonesInfo*/ |
345 | NOTSUPPORTED, /* DeleteUserRingtones*/ | 346 | NOTSUPPORTED, /* DeleteUserRingtones*/ |
@@ -352,45 +353,45 @@ GSM_Phone_Functions N9210Phone = { | |||
352 | NOTSUPPORTED, /* GetMMSSettings */ | 353 | NOTSUPPORTED, /* GetMMSSettings */ |
353 | NOTSUPPORTED, /* SetMMSSettings */ | 354 | NOTSUPPORTED, /* SetMMSSettings */ |
354 | NOTSUPPORTED, /* GetSyncMLSettings*/ | 355 | NOTSUPPORTED, /* GetSyncMLSettings*/ |
355 | NOTSUPPORTED, /* SetSyncMLSettings*/ | 356 | NOTSUPPORTED, /* SetSyncMLSettings*/ |
356 | NOTSUPPORTED, /* GetChatSettings */ | 357 | NOTSUPPORTED, /* GetChatSettings */ |
357 | NOTSUPPORTED, /* SetChatSettings */ | 358 | NOTSUPPORTED, /* SetChatSettings */ |
358 | N9210_GetBitmap, | 359 | N9210_GetBitmap, |
359 | N9210_SetBitmap, | 360 | N9210_SetBitmap, |
360 | NOTSUPPORTED, /* GetToDoStatus */ | 361 | NOTSUPPORTED, /* GetToDoStatus */ |
361 | NOTSUPPORTED, /* GetToDo */ | 362 | NOTSUPPORTED, /* GetToDo */ |
362 | NOTSUPPORTED, /* GetNextToDo */ | 363 | NOTSUPPORTED, /* GetNextToDo */ |
363 | NOTSUPPORTED, /* SetToDo */ | 364 | NOTSUPPORTED, /* SetToDo */ |
364 | NOTSUPPORTED, /* AddToDo */ | 365 | NOTSUPPORTED, /* AddToDo */ |
365 | NOTSUPPORTED, /* DeleteToDo */ | 366 | NOTSUPPORTED, /* DeleteToDo */ |
366 | NOTSUPPORTED, /* DeleteAllToDo */ | 367 | NOTSUPPORTED, /* DeleteAllToDo */ |
367 | NOTSUPPORTED, /* GetCalendarStatus*/ | 368 | NOTSUPPORTED, /* GetCalendarStatus*/ |
368 | NOTSUPPORTED, /* GetCalendar */ | 369 | NOTSUPPORTED, /* GetCalendar */ |
369 | NOTSUPPORTED, /* GetNextCalendar */ | 370 | NOTSUPPORTED, /* GetNextCalendar */ |
370 | NOTSUPPORTED, /* SetCalendar */ | 371 | NOTSUPPORTED, /* SetCalendar */ |
371 | NOTSUPPORTED, /* AddCalendar */ | 372 | NOTSUPPORTED, /* AddCalendar */ |
372 | NOTSUPPORTED, /* DeleteCalendar */ | 373 | NOTSUPPORTED, /* DeleteCalendar */ |
373 | NOTSUPPORTED, /* DeleteAllCalendar*/ | 374 | NOTSUPPORTED, /* DeleteAllCalendar*/ |
374 | NOTSUPPORTED, /* GetCalendarSettings*/ | 375 | NOTSUPPORTED, /* GetCalendarSettings*/ |
375 | NOTSUPPORTED, /* SetCalendarSettings*/ | 376 | NOTSUPPORTED, /* SetCalendarSettings*/ |
376 | NOTSUPPORTED, /* GetNote */ | 377 | NOTSUPPORTED, /* GetNextNote */ |
377 | NOTIMPLEMENTED, /* GetProfile */ | 378 | NOTIMPLEMENTED, /* GetProfile */ |
378 | NOTSUPPORTED, /* SetProfile */ | 379 | NOTSUPPORTED, /* SetProfile */ |
379 | NOTSUPPORTED, /* GetFMStation */ | 380 | NOTSUPPORTED, /* GetFMStation */ |
380 | NOTSUPPORTED, /* SetFMStation */ | 381 | NOTSUPPORTED, /* SetFMStation */ |
381 | NOTSUPPORTED, /* ClearFMStations */ | 382 | NOTSUPPORTED, /* ClearFMStations */ |
382 | NOTSUPPORTED, /* GetNextFileFolder*/ | 383 | NOTSUPPORTED, /* GetNextFileFolder*/ |
383 | NOTSUPPORTED, /* GetFilePart */ | 384 | NOTSUPPORTED, /* GetFilePart */ |
384 | NOTSUPPORTED, /* AddFile */ | 385 | NOTSUPPORTED, /* AddFile */ |
385 | NOTSUPPORTED, /* GetFileSystemStatus*/ | 386 | NOTSUPPORTED, /* GetFileSystemStatus*/ |
386 | NOTSUPPORTED, /* DeleteFile */ | 387 | NOTSUPPORTED, /* DeleteFile */ |
387 | NOTSUPPORTED, /* AddFolder */ | 388 | NOTSUPPORTED, /* AddFolder */ |
388 | NOTSUPPORTED, /* GetGPRSAccessPoint*/ | 389 | NOTSUPPORTED, /* GetGPRSAccessPoint*/ |
389 | NOTSUPPORTED /* SetGPRSAccessPoint*/ | 390 | NOTSUPPORTED /* SetGPRSAccessPoint*/ |
390 | }; | 391 | }; |
391 | 392 | ||
392 | #endif | 393 | #endif |
393 | 394 | ||
394 | /* How should editor hadle tabs in this file? Add editor commands here. | 395 | /* How should editor hadle tabs in this file? Add editor commands here. |
395 | * vim: noexpandtab sw=8 ts=8 sts=8: | 396 | * vim: noexpandtab sw=8 ts=8 sts=8: |
396 | */ | 397 | */ |