SMPP Configuration
The class accepts one or more of the following configuration settings. Configuration settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these internal properties is provided through the Config method.SMPP Configuration Settings
AddressRange: Specifies the addr_range parameter when binding.The addr_range parameter is used when binding as a receiver or transceiver to specify a set of SME addresses serviced by the ESME client. A single SME address may also be specified in the address_range parameter. UNIX Regular Expression notation should be used to specify a range of addresses. Messages addressed to any destination in this range shall be routed to the ESME.
Note 1: For IP addresses, it is only possible to specify a single IP address. A range of IP addresses are not allowed. IP version 6.0 is not currently supported in this version of the protocol. Note 2: It is likely that the addr_range field is not supported or deliberately ignored on most Message Centres. The reason for this is that most carriers will not allow an ESME control the message routing as this can carry the risk of mis-routing messages. In such circumstances, the ESME will be requested to set the field to NULL. | |||||||||||||||||||||||||||||||
BindAsReceiver: Causes the component to bind as a receiver. Setting this will instruct the component to bind to the SMPP service as a receiver instead of a transceiver. | |||||||||||||||||||||||||||||||
BindAsTransmitter: Causes the component to bind as a transmitter. Setting this will instruct the component to bind to the SMPP service as a transmitter instead of a transceiver. | |||||||||||||||||||||||||||||||
DataCoding: The data encoding mechanism to be used for the current message.
This value informs the message recipient about how the data was encoded.
The possible values are as follows:
| |||||||||||||||||||||||||||||||
DecodeHexStrings: Will decode an ascii hex-representation of binary data prior to transmission.When this setting is True, data sent in the SendCommand method's Payload parameter, SendData method's Data parameter, or SendMessage method's Message parameter will be treated as an ASCII hex-representation of binary data, and will be decoded into raw binary before transmission. For instance, the string "48656C6C6F20576F726C64" will be decoded to "Hello World" when this configuration setting is True. If the string passed to the method parameter is not correctly hex-encoded the class will transmit unexpected results. This setting is False by default. | |||||||||||||||||||||||||||||||
DestinationNPI: The Number Planning Indicator for the destination ESME. When sending messages, this value is used to indicate the numbering plan the destination ESME. For a list of possible values, please see SourceNPI. | |||||||||||||||||||||||||||||||
DestinationTON: The Type of Number for the destination ESME. When sending messages, this value is used to indicate the Type of Number for the destination ESME. For a list of possible values, please see SourceTON. | |||||||||||||||||||||||||||||||
DoSplitLargeMessages: Splits long messages and returns the UDH and Message Parts.
This configuration setting accepts a string which will be the long message to be
split into parts. The UDH and Message Parts will be returned in hex, in the format
below:
[UDH1],[MessagePart1];[UDH2],[MessagePart2];[UDH3],[MessagePart3] | |||||||||||||||||||||||||||||||
HexString: A hex-encoded binary string to be sent to the current recipient.
When set, this configuration setting will cause the component to internally call
SendMessage with the binary contents of the hex-encoded string. The
return value when setting this property is the server-assigned id of the
message. Querying this property will result in an empty string.
Note that when using HexString, DataCoding must be set to 8, and the value provided to this configuration setting should be the UTF-16 hex encoded message. | |||||||||||||||||||||||||||||||
IncomingDestinationAddress: Returns the dest_addr field inside the received message.This configuration setting is read-only, and is only valid inside the MessageIn event. | |||||||||||||||||||||||||||||||
IntermediateNotification: Causes the component to request intermediate notification. Setting this will request intermediate notification. By default, intermediate notification is not requested. | |||||||||||||||||||||||||||||||
MaxCIMDSMSLength: Indicates the maximum SMS message length for the CIMD protocol. This setting is only applicable when SplitLargeMessages is true and Protocol is set to CIMD2. The setting controls the maximum size of SMS messages before they are split and has a default value of 160. | |||||||||||||||||||||||||||||||
MaxSMSLength: Indicates the maximum SMS message length. This setting is only applicable when SplitLargeMessages is true. The setting controls the maximum size of SMS messages before they are split and has a default value of 140. | |||||||||||||||||||||||||||||||
MCReceipt: The Type of MC Delivery Receipt requested.
When sending a message, this value is used to determine whether or not an MC delivery receipt is requested. This value is 0 by default, and no
receipt is requested. The possible values are:
| |||||||||||||||||||||||||||||||
MessageInReceiptedMessageId: The receipted_message_id field of an incoming deliver_sm PDU. This value indicates the ID of the message being receipted in a MC Delivery Receipt. Note that this is only applicable within the MessageIn event. | |||||||||||||||||||||||||||||||
MessageMode: The Type of Messaging Mode requested.
When sending a message, this value is used to specify the Messaging Mode in the outgoing request. For incoming messages this value can be queried from within the MessageIn event.
The possible values are:
| |||||||||||||||||||||||||||||||
MessageType: The Type of Message.
When sending a message, this value is used to specify the Message Type in the outgoing request. For incoming messages this value can be queried from within the MessageIn event.
The possible values are:
| |||||||||||||||||||||||||||||||
ProtocolId: The protocol identifier. This config property allows control of the protocol identifier field value used in the outgoing messages. | |||||||||||||||||||||||||||||||
SMEAcknowledgement: The Type of SME originated acknowledgement requested.
When sending a message, this value is used to determine whether or not an SME acknowledgement is requested. This value is 0 by default, and no
acknowledgement is requested. The possible values are:
| |||||||||||||||||||||||||||||||
SplitLargeMessages: Determines whether large messages are split into multiple parts.The default value is false. If set to true and the message is larger than MaxSMSLength
(or MaxCIMDSMSLength) the message will automatically be split into parts when SendMessage
is called. Note that this is only valid for GSM networks.
When receiving a message that has been split, the MessageIn event provides parameters to re-assemble the message. | |||||||||||||||||||||||||||||||
SplitMessageMethod: Determines how large messages are split into multiple parts.The component can split large messages using either the UDH or SAR method. The mode used is
determined by this configuration option. The possible values are:
| |||||||||||||||||||||||||||||||
SourceNPI: The Number Planning Indicator for the ESME.
When binding, this value is used to specify the numbering plan of the ESME.
Mobiles tend to set this value to 1. Since most ESMEs are mobiles, the default
value for SourceNPI is 1. The possible value are:
| |||||||||||||||||||||||||||||||
SourceTON: The Type of Number for the ESME.
When binding, this value is used to indicate the Type of Number for the ESME
address. The possible values are:
| |||||||||||||||||||||||||||||||
SynchronousSendCommand: Controls whether SendCommand behaves synchronously or asynchronously. The default value is true which means SendCommand will not return until a response has been received. If set to false the class returns and does not wait for a response from the server. | |||||||||||||||||||||||||||||||
SynchronousSendMessage: Controls whether SendMessage behaves synchronously or asynchronously. The default value is true which means SendMessage will not return until a response has been received. If set to false the class returns the sequence number used and does not wait for a response from the server. You may then monitor the PITrail event to match the response from the server to the sent message. | |||||||||||||||||||||||||||||||
CustomTLV: Optional TLV parameters added after the mandatory parameters and before the payload.The format of a TLV parameter is:
For instance, to add a gn_lookup_userdata parameter, the type/tag is decimal 5633 (that's 0x1601 in hex), and the data in this example is "Hello World", which is 11 characters in length. So the TLV is: 5633 + 11 + "Hello World", or 0x16 0x01 0x00 0x0b and then the ASCII text "Hello World". When hex-encoded, this yields the string "1601000b48656c6c6f20576f726c64". This is the value you would then use to set the CustomTLV configuration setting. You are not restricted to only one optional parameter. Multiple TLV parameters may be concatenated together. Note that this is advanced functionality, and the class does not verify the data in this configuration setting prior to transmission. After the class internally decodes the string back into binary, it is passed on inside the PDU as-is without validation or modification. This setting is only applicable when using the SendMessage or SendData methods. | |||||||||||||||||||||||||||||||
SubAddr: Defines a unique index for application instance.This is useful for correct delivery of status reports when multiple instances of the
same application are connected.
This setting is only applicable when Protocol is set to smppCIMD2. | |||||||||||||||||||||||||||||||
StatusReportRequest: Defines in what cases a status report is created by the server.This is only applicable when Protocol is set to smppCIMD2. This may be set
to request that the server create a status report for the given conditions. The assigned value should be
the sum of all desired conditions. For instance a value of 62 means that a report should be created
for all events except for a temporary error. Possible flags are:
| |||||||||||||||||||||||||||||||
WaitForBanner: Specifies the CIMD2 banner the class will wait for when connecting.This is only applicable when Protocol is set to smppCIMD2. If set, the class will wait for a banner containing this string to be returned by the server before proceeding with the connection. |
IPPort Configuration Settings
ConnectionTimeout: Sets a separate timeout value for establishing a connection.When set, this configuration setting allows you to specify a different timeout value for establishing a connection. Otherwise, the class will use Timeout for establishing a connection and transmitting/receiving data. | |||||||||
FirewallAutoDetect: Tells the class whether or not to automatically detect and use firewall system settings, if available.This is the same as FirewallAutoDetect. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
FirewallHost: Name or IP address of firewall (optional).If a FirewallHost is given, requested connections will be authenticated through the specified firewall
when connecting.
If the FirewallHost setting is set to a Domain Name, a DNS request is initiated. Upon successful termination of the request, the FirewallHost setting is set to the corresponding address. If the search is not successful, an error is returned. NOTE: This is the same as FirewallHost. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
FirewallPassword: Password to be used if authentication is to be used when connecting through the firewall.If FirewallHost is specified, the FirewallUser and FirewallPassword settings
are used to connect and authenticate to the given firewall. If the authentication fails, the class fails with an error.
NOTE: This is the same as FirewallPassword. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
FirewallPort: The TCP port for the FirewallHost;.Note that the FirewallPort is set automatically when FirewallType is set to a valid value.
NOTE: This is the same as FirewallPort. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
FirewallType: Determines the type of firewall to connect through.The appropriate values are as follows:
NOTE: This is the same as FirewallType. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
FirewallUser: A user name if authentication is to be used connecting through a firewall.If the FirewallHost is specified, the FirewallUser and FirewallPassword
settings are used to connect and authenticate to the Firewall. If the authentication fails, the class fails with an error.
NOTE: This is the same as FirewallUser. This setting is provided for use by classs that do not directly expose Firewall properties. | |||||||||
KeepAliveTime: The inactivity time in milliseconds before a TCP keep-alive packet is sent.When set, TCPKeepAlive will automatically be set to true.
By default the operating system will determine the
time a connection is idle before a TCP keep-alive packet is sent. This system default if this value is not specified here is 2 hours. In many
cases a shorter interval is more useful. Set this value to the desired interval in milliseconds.
Note: This value is not applicable in Java. | |||||||||
KeepAliveInterval: The retry interval, in milliseconds, to be used when a TCP keep-alive packet is sent and no response is received.When set, TCPKeepAlive will automatically be set to true.
A TCP keep-alive packet will be sent after a period of inactivity as
defined by KeepAliveTime. If no acknowledgement is received from the remote host the keep-alive packet
will be re-sent. This setting specifies the interval at which the successive keep-alive packets are sent in milliseconds.
This system default if this value is not specified here is 1 second.
Note: This value is not applicable in Java or MAC. | |||||||||
KeepAliveRetryCount: The number of keep-alive packets to be sent before the remotehost is considered disconnected.When set, TCPKeepAlive will automatically be set to true.
A TCP keep-alive packet will be sent after a period of inactivity as
defined by KeepAliveTime. If no acknowledgement is received from the remote host the keep-alive packet
will be re-sent. This setting specifies the number of times that the keep-alive packets will be re-sent before the remote host
is considered disconnected.
The system default if this value is not specified here is 9.
Note: This configuration setting is only available in the Unix platform, and isn't supported in Mac OS or FreeBSD. | |||||||||
Linger: When set to True, connections are terminated gracefully.This property controls how a connection is closed. The default is True.
In the case that Linger is True (default), there are two scenarios for determining how long the connection will linger. The first, if LingerTime is 0 (default), the system will attempt to send pending data for a connection until the default IP protocol timeout expires. In the second scenario, LingerTime is a positive value, the system will attempt to send pending data until the specified LingerTime is reached. If this attempt fails, then the system will reset the connection. The default behavior (which is also the default mode for stream sockets) might result in a long delay in closing the connection. Although the class returns control immediately, the system could hold system resources until all pending data is sent (even after your application closes). Setting this property to False forces an immediate disconnection. If you know that the other side has received all the data you sent (by a client acknowledgment, for example), setting this property to False might be the appropriate course of action. | |||||||||
LingerTime: Time in seconds to have the connection linger. LingerTime is the time, in seconds, to leave the socket connection linger. This value is 0 by default, which means it will use the default IP protocol timeout. | |||||||||
LocalHost: The name of the local host through which connections are initiated or accepted.
The LocalHost setting contains the name of the local host
as obtained by the gethostname() system call, or if the
user has assigned an IP address, the value of that address.
In multi-homed hosts (machines with more than one IP interface) setting LocalHost to the value of an interface will make the class initiate connections (or accept in the case of server classs) only through that interface. If the class is connected, the LocalHost setting shows the IP address of the interface through which the connection is made in internet dotted format (aaa.bbb.ccc.ddd). In most cases, this is the address of the local host, except for multi-homed hosts (machines with more than one IP interface). | |||||||||
LocalPort: The TCP port in the local host where the class binds.
This must be set before a connection is
attempted. It instructs the class to bind to a specific
port (or communication endpoint) in the local machine.
Setting this to 0 (default) enables the system to choose a port at random. The chosen port will be shown by LocalPort after the connection is established. LocalPort cannot be changed once a connection is made. Any attempt to set this when a connection is active will generate an error. This; setting is useful when trying to connect to services that require a trusted port in the client side. An example is the remote shell (rsh) service in UNIX systems. | |||||||||
MaxLineLength: The maximum amount of data to accumulate when no EOL is found.MaxLineLength is the size of an internal buffer, which holds received data while waiting for an EOL
string.
If an EOL string is found in the input stream before MaxLineLength bytes are received, the DataIn event is fired with the EOL parameter set to True, and the buffer is reset. If no EOL is found, and MaxLineLength bytes are accumulated in the buffer, the DataIn event is fired with the EOL parameter set to False, and the buffer is reset. The minimum value for MaxLineLength is 256 bytes. The default value is 2048 bytes. The maximum value is 65536 bytes. | |||||||||
MaxTransferRate: The transfer rate limit in bytes per second.This setting can be used to throttle outbound TCP traffic. Set this to the number of bytes to be sent per second. By default this is not set and there is no limit. | |||||||||
RecordLength: The length of received data records.If set to a positive value, this setting defines the length of data records to be received. The class will accumulate data
until RecordLength is reached and only then fire the DataIn event with data of length RecordLength.
This allows data to be received as records of known length. This value can be changed at any time, including within the DataIn event.
The default value is 0, meaning this setting is not used. | |||||||||
TCPKeepAlive: Determines whether or not the keep alive socket option is enabled.If set to true, the socket's keep-alive option is enabled and keep-alive packets will be sent periodically
to maintain the connection. Set KeepAliveTime and KeepAliveInterval to
configure the timing of the keep-alive packets.
Note: This value is not applicable in Java. | |||||||||
UseIPv6: Whether to use IPv6.When set to 0 (default), the class will use IPv4 exclusively.
When set to 1, the class will use IPv6 exclusively. To instruct the class to prefer IPv6 addresses, but use IPv4 if IPv6 is not supported on the system, this setting should be set to 2. The default value is 0.
Possible values are:
| |||||||||
TcpNoDelay: Whether or not to delay when sending packets.
When true, the socket will send all data that is ready to send at once. When
false, the socket will send smaller buffered packets of data at small intervals.
This is known as the Nagle algorithm.
By default, this config is set to false. |
Socket Configuration Settings
AbsoluteTimeout: Determines whether timeouts are inactivity timeouts or absolute timeouts.If AbsoluteTimeout is set to True, any method which does not complete within Timeout seconds
will be aborted. By default, AbsoluteTimeout is False, and the timeout is an inactivity timeout.
Note: This option is not valid for UDP ports. | |
FirewallData: Used to send extra data to the firewall.When the firewall is a tunneling proxy, use this property to send custom (additional) headers to the firewall (e.g. headers for custom authentication schemes). | |
InBufferSize: The size in bytes of the incoming queue of the socket.
This is the size of an internal queue in the TCP/IP stack.
You can increase or decrease its size depending on the amount
of data that you will be receiving. Increasing the value of the
InBufferSize setting can provide significant improvements in
performance in some cases.
Some TCP/IP implementations do not support variable buffer sizes. If that is the case, when the class is activated the InBufferSize reverts to its defined size. The same happens if you attempt to make it too large or too small. | |
OutBufferSize: The size in bytes of the outgoing queue of the socket.This is the size of an internal queue in the TCP/IP stack.
You can increase or decrease its size depending on the amount
of data that you will be sending. Increasing the value of the
OutBufferSize setting can provide significant improvements in
performance in some cases.
Some TCP/IP implementations do not support variable buffer sizes. If that is the case, when the class is activated the OutBufferSize reverts to its defined size. The same happens if you attempt to make it too large or too small. |
Base Configuration Settings
SelectWaitMillis: The length of time in milliseconds the class will wait when DoEvents is called if there are no events to process. If there are no events to process when DoEvents is called, the class will wait for the amount of time specified here before returning. The default value is 20. |
Base Configuration Settings
CodePage: The system code page used for Unicode to Multibyte translations.
The default code page is the Active Code Page (0).
The following is a list of valid code page identifiers:
|