Skip to content

How to query_sm #2

Open
chakhedik opened this Issue Apr 5, 2011 · 10 comments

2 participants

@chakhedik

Hi,

I tried your echo_esme and it's awesome, it really easy to understand for a beginner to smpp like me.

Can you help me with how to do query_sm?

I tried this,

Body = #query_sm{message_id=Id, source_addr=Src},
gen_esme34:transmit_pdu(?MODULE, Body, id()).

But always received this,

{pdu,16,2147483648,3,87,{generic_nack}}

The command status = 3 which means Invalid Command ID...

Chak

@essiene
Owner
@chakhedik

Yes, my server is 3.4

@essiene
Owner
@essiene
Owner
essiene commented Apr 5, 2011

{pdu,21,2147483651,103,6,{query_sm_resp,[],[],0,0}}

RespComandId = 2147483651
StatusCode = 103dec (67hex) -> query failed. (but at least, the query_sm command was accepted and acted on)

See code snippet I'm using https://gist.github.com/904073

Let me know if you still have any issues and then send me a code snippet ;)

@chakhedik

Hi,

{pdu,16,2147483648,3,9,{generic_nack}}

I still receive the same response. I test it against live SMSC also, received sms on my phone but still failed to query_sm. I'll contact my SMSC regarding this matter and will let u know what's the problem.

@essiene
Owner
essiene commented Apr 6, 2011

great. I'll still leave this issue open till I hear back from you.

@chakhedik

Hi,

I've contacted them they ask me to send using version 3.3 parameters with the only difference is message_id vs original_message_id. I simply change the pdu record for query_sm. However, I still got the same reply. Maybe the command id is different for version 3.3.

This is from v3.3 doc :

generic_nack - Generic response to a command for which the message header is invalid.

@essiene
Owner
@essiene
Owner
@chakhedik

That would be great. Thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.