# HG changeset patch # User Mychaela Falconia # Date 1520541183 0 # Node ID d1fa771abeb85fcfd9f3b87a0051fcd46312355e # Parent 1fa4dcbb1c870d7f16050c9a19dcd0930724fb60 uptools: make_sms_submit_pdu() in libcoding now takes PID and DCS arguments diff -r 1fa4dcbb1c87 -r d1fa771abeb8 uptools/atcmd/smsend_pduout.c --- a/uptools/atcmd/smsend_pduout.c Thu Mar 08 19:47:40 2018 +0000 +++ b/uptools/atcmd/smsend_pduout.c Thu Mar 08 20:33:03 2018 +0000 @@ -26,7 +26,8 @@ char send_cmd[32]; pdu[0] = 0; - pdulen = make_sms_submit_pdu(da, textsrc, textlen, udh, udhl, pdu + 1); + pdulen = make_sms_submit_pdu(da, 0, 0, textsrc, textlen, udh, udhl, + pdu + 1); make_hex_string(pdu, pdulen + 1, pduhex); if (sms_write_mode) { cmdname = "CMGW"; diff -r 1fa4dcbb1c87 -r d1fa771abeb8 uptools/libcoding/sms_submit.c --- a/uptools/libcoding/sms_submit.c Thu Mar 08 19:47:40 2018 +0000 +++ b/uptools/libcoding/sms_submit.c Thu Mar 08 20:33:03 2018 +0000 @@ -6,7 +6,7 @@ #include #include -make_sms_submit_pdu(da, textsrc, textlen, udh, udhl, outbuf) +make_sms_submit_pdu(da, pid, dcs, textsrc, textlen, udh, udhl, outbuf) u_char *da, *textsrc, *udh, *outbuf; unsigned textlen, udhl; { @@ -24,8 +24,8 @@ addr_field_len = ((da[0] + 1) >> 1) + 2; bcopy(da, outp, addr_field_len); outp += addr_field_len; - *outp++ = 0; - *outp++ = 0; + *outp++ = pid; + *outp++ = dcs; if (udh) { udh_octets = udhl + 1; udh_chars = (udh_octets * 8 + 6) / 7;