Using adl_smsSend to send PDU messages returns an error


#1

This works:
sRet = adl_smsSend(SMSHandle,dstphoneNum,DataBuffer,ADL_SMS_MODE_TEXT); //sRet == OK;

But this fails:
sRet = adl_smsSend(SMSHandle,dstphoneNum,DataBuffer,ADL_SMS_MODE_PDU); // sRet == ADL_RET_ERR_PARAM

Does anyone have a clue why?


#2

Never mind… I think it is because in adl_smsSubscribe, I used ADL_SMS_MODE_TEXT.


#3

Oh man… I thought in my last post that I found the reason for the problem. But the problem still persists:

This works:
SMSHandleTXT = adl_smsSubscribe ( SMSHandler , SMSControlHandler , ADL_SMS_MODE_TEXT );
sRet = adl_smsSend(SMSHandleTXT,dstphoneNum,DataBuffer,ADL_SMS_MODE_TEXT);

This does not work:
SMSHandlePDU = adl_smsSubscribe ( SMSHandler , SMSControlHandler , ADL_SMS_MODE_PDU );
sRet = adl_smsSend(SMSHandlePDU,dstphoneNum,DataBuffer,ADL_SMS_MODE_PDU);

Any ideas?


#4

I now suspect the error message is due to the contents of the DataBuffer, and not so much the ADL_SMS_MODE_PDU parameter itself. I think I will have another close inspection of how I set up the Databuffer for PDU message.


#5

Ok, I simply can not get adl_smsSend to send PDU messages. It always fail with ADL_RET_ERR_PARAM.

I have re-check the contents of my message buffer and belief it is correct. Here is a hex dump of its contents:
00 0F 00 0B 91 72 17 52 37 92 0F 00 02 AA 07 74 65 73 74 69 6E 67

I’m also a bit puzzled by the fact that threre is one generic call to smsSend to send messages in Text and PDU mode. The syntax of adl_smsSend is:
s8 adl_smsSend( u8 Handle, ascii * SmsTel, ascii * SmsText, u8 Mode );
But for PDU messages, the SmsTel number should not be required, as it is embedded in the buffer contents.

Wavecom documentation is very vague on the subject of using this function to send PDU messages and I’m starting to wonder if anyone has ever used this before? Do you know where I can get a simple example where PDU messages are sent using adl_smsSend?


#6

It helps to post here. I managed to solve the problem myself. It was a problem in the way I set up my PDU string as I originally suspected.


#7

:laughing: