Iam studying SMPP protocol and tried to implement a simple transmitter with a golang code and selenium smpp simulator. I found a package "CodeMonkeyKevin/smpp34" from github. But Iam unable to set the "user_message_reference" optional parameter.
I slightly modified the "SubmitSm" function inside the "transmitter.go" file by adding these lines (just before the write operation):
err = p.SetTLVField(tag, length, []byte(value))
if err != nil {
fmt.Println("Set TLV failed")
return 0, err
}
But this is not working.
I supplied values tag=0516(int equivalent of 0x0204 user_message_reference) length=02 and value="91".
In the response i could see "tag=516,len=2,value=0x3931" in the SMSC simulator , the value field doesn't seem appropriate to me; also the "message_id" in the response still continues its sequence by adding 1 with the last message_id
can some one help me in setting the "user_message_reference" optional parameter to the "submit_sm" request?
Thanks in advance.