SMPP Option type length

SMPP Option type length SearchSearch

SMS & MMS Technical Forum » NowSMS Support - SMS Issues (Product Support Only) » Archive through August 22, 2012 » SMPP Option type length « Previous || Next »
Author Message
Jimmy Cherian
Posted on Tuesday, December 20, 2011 - 05:51 am:   

Dear Sir,
Our operator is requesting for SMPP option with type as integer and len as 4, but when we put the len as 4 we are getting malformed error. But len=2 is working fine, is this a limitation on NOWSMS?
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 3682
Registered: 08-2008
Posted on Tuesday, December 20, 2011 - 01:29 pm:   

Hi Jimmy,

That does seem to be a bug. We did not consider the possibility for a 4 byte integer in a TLV parameter. (All of the TLV examples in the spec are 1 or 2 bytes, but a 4 byte integer is also allowed by the spec.)

We will correct this in a future update, but you should be able to work-around this temporarily by using the HexString data type.

For example:


[SMPP - server:port]



When using the HexString type, NowSMS interprets this parameter as a string of binary data to be included in the TLV parameter.

For a 4 byte integer, this would be an 8 digit hex number.

For example: 000000FF = 255 decimal
10000000 = 268435456 decimal

NowSMS bases the parameter length on the length of the hex string, so be sure to pad with zeroes to keep the length as 4 (4 bytes = 8 digits).

If this work-around will not be sufficient for you, please let me know. We will be working on an update to properly support this value type as an integer, but I do not know if this work can be scheduled until after the holidays.

NowSMS Support

Login Login / Register Logout Logout Search Last 30 Days Topics Topics