diff --git a/src/libmisdnuser/suppserv/fac.c b/src/libmisdnuser/suppserv/fac.c index dd55857..43c588a 100644 --- a/src/libmisdnuser/suppserv/fac.c +++ b/src/libmisdnuser/suppserv/fac.c @@ -406,7 +406,7 @@ static int encodeAOCDChargingUnitOperation(__u8 * dest, const struct asn1_parm * p[i++] = 0x30; p[i++] = (0x02 + len); p[i++] = 0x02; // Operation Tag - p[i++] = 0x01; // AOC-D so Sub-Total + p[i++] = 0x01; // Recorded units could take up as much as 3 bytes (0xFFFFFF) p[i] = numberOfUnits & 0xFF; @@ -416,9 +416,9 @@ static int encodeAOCDChargingUnitOperation(__u8 * dest, const struct asn1_parm * p[i+2] = (numberOfUnits >> 16) & 0xFF; i += len; - p[i++] = 0x82; - p[i++] = 0x01; + p[i++] = 0x82; // Type of charging info p[i++] = 0x01; + p[i++] = 0x00; // AOC-D so Sub-Total p[1] = (AOCD_CHARGE_UNIT_IE_LENGTH + len); // IE Payload Length p[4] = p[1] - 3; // Invoke Component Length