NOTE: Code generated by EXIdizer v0.1
@@ -56,19 +56,19 @@ int exiDecodeNextEvent(bitstream_t* stream, exi_state_t* state, /* DocEnd[END_DOCUMENT] */ *nextEvent = END_DOCUMENT; return 0; - case 56: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 75: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - case 100: + case 88: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ - case 17: + case 145: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + case 157: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + case 23: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - case 151: + case 198: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 173: + case 225: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - case 178: + case 230: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ decodeNBitUnsignedInteger(stream, 2, &state->eventCode); if (state->eventCode == 0) { @@ -83,503 +83,8 @@ int exiDecodeNextEvent(bitstream_t* stream, exi_state_t* state, *nextEvent = END_ELEMENT; return 0; } - case 168: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), END_ELEMENT] */ - decodeNBitUnsignedInteger(stream, 5, &state->eventCode); - if (state->eventCode == 0) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 1) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 2) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 3) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 4) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 5) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 6) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 7) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 8) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 9) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 10) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 11) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 12) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 13) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 14) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 15) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 16) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 17) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 18) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 19) { - *nextEvent = END_ELEMENT; - return 0; - } - case 54: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 149: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 172: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - decodeNBitUnsignedInteger(stream, 2, &state->eventCode); - if (state->eventCode == 0) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 1) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 2) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 3) { - *nextEvent = END_ELEMENT; - return 0; - } - case 7: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 48: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - case 114: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ - case 21: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - decodeNBitUnsignedInteger(stream, 1, &state->eventCode); - if (state->eventCode == 0) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 1) { - *nextEvent = START_ELEMENT; - return 0; - } - case 5: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 24: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ - case 25: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - case 28: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ - case 6: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 32: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - case 35: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ - case 36: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ - case 38: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - case 39: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ - case 40: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ - case 42: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ - case 46: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 49: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - case 50: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ - case 57: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ - case 61: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ - case 63: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ - case 8: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 10: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 69: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - case 71: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - case 73: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - case 74: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ - case 11: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ - case 12: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 13: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 82: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ - case 14: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 15: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 87: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ - case 88: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ - case 89: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ - case 90: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ - case 91: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ - case 93: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ - case 16: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 95: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - case 97: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEVoltage)] */ - case 98: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEIMax)] */ - case 99: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ - case 104: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency)] */ - case 105: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff)] */ - case 108: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ - case 115: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ - case 118: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ - case 120: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ - case 128: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ - case 18: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 139: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ - case 141: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ - case 19: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ - case 20: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 158: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - case 22: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - case 160: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - case 162: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - case 163: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - case 23: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ - case 165: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ - case 166: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ - case 170: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ - case 183: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Event)] */ - *nextEvent = START_ELEMENT; - return 0; - case 3: - /* First(xsi:type)StartTag[END_ELEMENT] */ - case 26: - /* Element[END_ELEMENT] */ - case 29: - /* Element[END_ELEMENT] */ - case 31: - /* Element[END_ELEMENT] */ - case 34: - /* Element[END_ELEMENT] */ - case 44: - /* Element[END_ELEMENT] */ - case 52: - /* Element[END_ELEMENT] */ - case 60: - /* Element[END_ELEMENT] */ - case 65: - /* Element[END_ELEMENT] */ - case 67: - /* Element[END_ELEMENT] */ - case 9: - /* FirstStartTag[END_ELEMENT] */ - case 77: - /* Element[END_ELEMENT] */ - case 78: - /* Element[END_ELEMENT] */ - case 80: - /* Element[END_ELEMENT] */ - case 84: - /* Element[END_ELEMENT] */ - case 85: - /* Element[END_ELEMENT] */ - case 94: - /* Element[END_ELEMENT] */ - case 103: - /* Element[END_ELEMENT] */ - case 113: - /* Element[END_ELEMENT] */ - case 117: - /* Element[END_ELEMENT] */ - case 127: - /* Element[END_ELEMENT] */ - case 131: - /* Element[END_ELEMENT] */ - case 134: - /* Element[END_ELEMENT] */ - case 138: - /* Element[END_ELEMENT] */ - case 148: - /* Element[END_ELEMENT] */ - case 154: - /* Element[END_ELEMENT] */ - case 155: - /* Element[END_ELEMENT] */ - case 156: - /* Element[END_ELEMENT] */ - case 159: - /* Element[END_ELEMENT] */ - case 164: - /* Element[END_ELEMENT] */ - case 167: - /* Element[END_ELEMENT] */ - case 171: - /* Element[END_ELEMENT] */ - case 176: - /* Element[END_ELEMENT] */ - case 182: - /* Element[END_ELEMENT] */ - case 184: - /* Element[END_ELEMENT] */ - case 186: - /* Element[END_ELEMENT] */ - *nextEvent = END_ELEMENT; - return 0; - case 27: - /* FirstStartTag[CHARACTERS[BOOLEAN]] */ - case 30: - /* FirstStartTag[CHARACTERS[BOOLEAN]] */ - case 33: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 37: - /* FirstStartTag[CHARACTERS[BOOLEAN]] */ - case 41: - /* FirstStartTag[CHARACTERS[BOOLEAN]] */ - case 43: - /* FirstStartTag[CHARACTERS[BOOLEAN]] */ - case 45: - /* FirstStartTag[CHARACTERS[INTEGER_32]] */ - case 47: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 51: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 55: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 62: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 64: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 66: - /* First(xsi:type)StartTag[CHARACTERS[INTEGER_32]] */ - case 59: - /* FirstStartTag[CHARACTERS[INTEGER_16]] */ - case 68: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 70: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 72: - /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ - case 79: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 81: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 86: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 92: - /* FirstStartTag[CHARACTERS[INTEGER_16]] */ - case 96: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 102: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 106: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 116: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 129: - /* FirstStartTag[CHARACTERS[UNSIGNED_INTEGER_32]] */ - case 133: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 135: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 137: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 150: - /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ - case 152: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 157: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 161: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 174: - /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ - case 177: - /* FirstStartTag[CHARACTERS[STRING]] */ - case 179: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - case 181: - /* First(xsi:type)StartTag[CHARACTERS[STRING]] */ - case 185: - /* FirstStartTag[CHARACTERS[ENUMERATION]] */ - *nextEvent = CHARACTERS; - return 0; - case 53: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - decodeNBitUnsignedInteger(stream, 3, &state->eventCode); - if (state->eventCode == 0) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 1) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 2) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 3) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 4) { - *nextEvent = END_ELEMENT; - return 0; - } - case 58: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 76: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - case 83: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ - case 101: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ - case 107: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 109: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 110: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 111: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 112: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 119: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 121: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 122: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 123: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 124: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 125: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 126: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 130: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice), END_ELEMENT] */ - case 132: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - case 136: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ - case 140: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 142: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 143: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 144: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 145: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 146: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 147: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 153: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 169: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ - case 175: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - case 180: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - decodeNBitUnsignedInteger(stream, 1, &state->eventCode); - if (state->eventCode == 0) { - *nextEvent = START_ELEMENT; - return 0; - } - else if (state->eventCode == 1) { - *nextEvent = END_ELEMENT; - return 0; - } - case 1: - /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT_GENERIC] */ + case 220: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), END_ELEMENT] */ decodeNBitUnsignedInteger(stream, 5, &state->eventCode); if (state->eventCode == 0) { *nextEvent = START_ELEMENT; @@ -662,6 +167,695 @@ int exiDecodeNextEvent(bitstream_t* stream, exi_state_t* state, return 0; } else if (state->eventCode == 20) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 21) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 22) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 23) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 24) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 25) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 26) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 27) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 28) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 29) { + *nextEvent = END_ELEMENT; + return 0; + } + case 143: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + case 196: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + case 224: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + decodeNBitUnsignedInteger(stream, 2, &state->eventCode); + if (state->eventCode == 0) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 1) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 2) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 3) { + *nextEvent = END_ELEMENT; + return 0; + } + case 102: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + case 13: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 138: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ + case 27: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + decodeNBitUnsignedInteger(stream, 1, &state->eventCode); + if (state->eventCode == 0) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 1) { + *nextEvent = START_ELEMENT; + return 0; + } + case 5: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 35: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + case 36: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + case 38: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ReadyToCharge)] */ + case 6: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 43: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 46: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ + case 47: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ + case 49: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + case 50: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ + case 51: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ + case 53: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ + case 55: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + case 57: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEMalfunction)] */ + case 58: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}StopCharging)] */ + case 7: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 62: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargingMode)] */ + case 63: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ + case 65: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ + case 66: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ + case 68: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ + case 69: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ + case 71: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ + case 72: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxCurrent)] */ + case 73: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinCurrent)] */ + case 67: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ + case 75: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ + case 77: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ + case 8: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 81: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 83: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxVoltage)] */ + case 84: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinVoltage)] */ + case 85: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxCurrent)] */ + case 86: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinCurrent)] */ + case 87: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ + case 92: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency)] */ + case 93: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff)] */ + case 96: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ + case 104: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + case 107: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ + case 109: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ + case 117: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ + case 9: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 121: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + case 122: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + case 123: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDifferential)] */ + case 124: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + case 10: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 126: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 128: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + case 129: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentCurrent)] */ + case 11: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 131: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ + case 12: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 133: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 136: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 139: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ + case 140: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ + case 14: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 16: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 151: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + case 153: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 155: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + case 156: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ + case 17: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ + case 18: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 162: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + case 19: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 165: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ + case 20: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 168: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 21: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 171: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + case 172: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + case 173: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + case 22: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 175: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 177: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + case 24: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 186: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ + case 188: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ + case 25: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ + case 26: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 205: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 28: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 207: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + case 209: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 210: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + case 29: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 30: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 213: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 215: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + case 31: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ + case 217: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ + case 218: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ + case 222: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ + case 235: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Event)] */ + case 32: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + case 33: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + case 240: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + case 242: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + *nextEvent = START_ELEMENT; + return 0; + case 3: + /* First(xsi:type)StartTag[END_ELEMENT] */ + case 34: + /* Element[END_ELEMENT] */ + case 40: + /* Element[END_ELEMENT] */ + case 42: + /* Element[END_ELEMENT] */ + case 45: + /* Element[END_ELEMENT] */ + case 60: + /* Element[END_ELEMENT] */ + case 74: + /* Element[END_ELEMENT] */ + case 79: + /* Element[END_ELEMENT] */ + case 91: + /* Element[END_ELEMENT] */ + case 101: + /* Element[END_ELEMENT] */ + case 106: + /* Element[END_ELEMENT] */ + case 116: + /* Element[END_ELEMENT] */ + case 120: + /* Element[END_ELEMENT] */ + case 125: + /* Element[END_ELEMENT] */ + case 130: + /* Element[END_ELEMENT] */ + case 132: + /* Element[END_ELEMENT] */ + case 135: + /* Element[END_ELEMENT] */ + case 141: + /* Element[END_ELEMENT] */ + case 148: + /* Element[END_ELEMENT] */ + case 149: + /* Element[END_ELEMENT] */ + case 15: + /* FirstStartTag[END_ELEMENT] */ + case 159: + /* Element[END_ELEMENT] */ + case 160: + /* Element[END_ELEMENT] */ + case 164: + /* Element[END_ELEMENT] */ + case 167: + /* Element[END_ELEMENT] */ + case 170: + /* Element[END_ELEMENT] */ + case 174: + /* Element[END_ELEMENT] */ + case 178: + /* Element[END_ELEMENT] */ + case 181: + /* Element[END_ELEMENT] */ + case 185: + /* Element[END_ELEMENT] */ + case 195: + /* Element[END_ELEMENT] */ + case 201: + /* Element[END_ELEMENT] */ + case 202: + /* Element[END_ELEMENT] */ + case 203: + /* Element[END_ELEMENT] */ + case 206: + /* Element[END_ELEMENT] */ + case 211: + /* Element[END_ELEMENT] */ + case 212: + /* Element[END_ELEMENT] */ + case 216: + /* Element[END_ELEMENT] */ + case 219: + /* Element[END_ELEMENT] */ + case 223: + /* Element[END_ELEMENT] */ + case 228: + /* Element[END_ELEMENT] */ + case 234: + /* Element[END_ELEMENT] */ + case 236: + /* Element[END_ELEMENT] */ + case 238: + /* Element[END_ELEMENT] */ + case 239: + /* Element[END_ELEMENT] */ + case 243: + /* Element[END_ELEMENT] */ + *nextEvent = END_ELEMENT; + return 0; + case 37: + /* FirstStartTag[CHARACTERS[BOOLEAN]] */ + case 39: + /* FirstStartTag[CHARACTERS[BOOLEAN]] */ + case 41: + /* First(xsi:type)StartTag[CHARACTERS[BOOLEAN]] */ + case 44: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 48: + /* FirstStartTag[CHARACTERS[BOOLEAN]] */ + case 52: + /* FirstStartTag[CHARACTERS[BOOLEAN]] */ + case 54: + /* FirstStartTag[CHARACTERS[BOOLEAN]] */ + case 56: + /* FirstStartTag[CHARACTERS[INTEGER_32]] */ + case 59: + /* First(xsi:type)StartTag[CHARACTERS[BOOLEAN]] */ + case 61: + /* First(xsi:type)StartTag[CHARACTERS[BOOLEAN]] */ + case 64: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 76: + /* FirstStartTag[CHARACTERS[INTEGER_16]] */ + case 78: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 80: + /* First(xsi:type)StartTag[CHARACTERS[INTEGER_32]] */ + case 70: + /* FirstStartTag[CHARACTERS[INTEGER_16]] */ + case 82: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 90: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 94: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 103: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 105: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 118: + /* FirstStartTag[CHARACTERS[UNSIGNED_INTEGER_32]] */ + case 127: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 134: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 137: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 144: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 147: + /* FirstStartTag[CHARACTERS[INTEGER_16]] */ + case 150: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 152: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 154: + /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ + case 161: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 163: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 169: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 176: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 180: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 182: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 184: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 197: + /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ + case 199: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 204: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 208: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 214: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 226: + /* FirstStartTag[CHARACTERS[BINARY_HEX]] */ + case 229: + /* FirstStartTag[CHARACTERS[STRING]] */ + case 231: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 233: + /* First(xsi:type)StartTag[CHARACTERS[STRING]] */ + case 237: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + case 241: + /* FirstStartTag[CHARACTERS[ENUMERATION]] */ + *nextEvent = CHARACTERS; + return 0; + case 142: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + decodeNBitUnsignedInteger(stream, 3, &state->eventCode); + if (state->eventCode == 0) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 1) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 2) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 3) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 4) { + *nextEvent = END_ELEMENT; + return 0; + } + case 89: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ + case 95: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 97: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 98: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 99: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 100: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 108: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 110: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 111: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 112: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 113: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 114: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 115: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 119: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice), END_ELEMENT] */ + case 146: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + case 158: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + case 166: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ + case 179: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ + case 183: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ + case 187: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 189: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 190: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 191: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 192: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 193: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 194: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 200: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + case 221: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ + case 227: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ + case 232: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + decodeNBitUnsignedInteger(stream, 1, &state->eventCode); + if (state->eventCode == 0) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 1) { + *nextEvent = END_ELEMENT; + return 0; + } + case 1: + /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), START_ELEMENT_GENERIC] */ + decodeNBitUnsignedInteger(stream, 5, &state->eventCode); + if (state->eventCode == 0) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 1) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 2) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 3) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 4) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 5) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 6) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 7) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 8) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 9) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 10) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 11) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 12) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 13) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 14) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 15) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 16) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 17) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 18) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 19) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 20) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 21) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 22) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 23) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 24) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 25) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 26) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 27) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 28) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 29) { + *nextEvent = START_ELEMENT; + return 0; + } + else if (state->eventCode == 30) { *nextEvent = START_ELEMENT_GENERIC; return 0; } @@ -711,709 +905,921 @@ int exiDecodeStartElement(bitstream_t* stream, exi_state_t* state, eqname_t* se) { switch (state->grammarStack[state->stackIndex]) { case 1: - /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT_GENERIC] */ + /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), START_ELEMENT_GENERIC] */ if (state->eventCode == 0) { return _exiDecodeStartElement(state, se, 6, 2, 2, 3); } else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 10, 2, 5); + return _exiDecodeStartElement(state, se, 4, 0, 2, 5); } else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 4, 12, 2, 6); + return _exiDecodeStartElement(state, se, 4, 2, 2, 6); } else if (state->eventCode == 3) { - return _exiDecodeStartElement(state, se, 4, 15, 2, 7); + return _exiDecodeStartElement(state, se, 4, 4, 2, 7); } else if (state->eventCode == 4) { - return _exiDecodeStartElement(state, se, 4, 17, 2, 8); + return _exiDecodeStartElement(state, se, 4, 6, 2, 8); } else if (state->eventCode == 5) { - return _exiDecodeStartElement(state, se, 4, 19, 2, 9); + return _exiDecodeStartElement(state, se, 4, 10, 2, 9); } else if (state->eventCode == 6) { - return _exiDecodeStartElement(state, se, 4, 21, 2, 10); + return _exiDecodeStartElement(state, se, 4, 12, 2, 10); } else if (state->eventCode == 7) { - return _exiDecodeStartElement(state, se, 4, 30, 2, 11); + return _exiDecodeStartElement(state, se, 4, 28, 2, 11); } else if (state->eventCode == 8) { - return _exiDecodeStartElement(state, se, 4, 32, 2, 12); + return _exiDecodeStartElement(state, se, 4, 30, 2, 12); } else if (state->eventCode == 9) { - return _exiDecodeStartElement(state, se, 4, 34, 2, 13); + return _exiDecodeStartElement(state, se, 4, 33, 2, 13); } else if (state->eventCode == 10) { - return _exiDecodeStartElement(state, se, 4, 36, 2, 14); + return _exiDecodeStartElement(state, se, 4, 35, 2, 14); } else if (state->eventCode == 11) { - return _exiDecodeStartElement(state, se, 4, 38, 2, 15); + return _exiDecodeStartElement(state, se, 4, 37, 2, 15); } else if (state->eventCode == 12) { - return _exiDecodeStartElement(state, se, 4, 40, 2, 16); + return _exiDecodeStartElement(state, se, 4, 39, 2, 16); } else if (state->eventCode == 13) { - return _exiDecodeStartElement(state, se, 4, 45, 2, 17); + return _exiDecodeStartElement(state, se, 4, 52, 2, 17); } else if (state->eventCode == 14) { - return _exiDecodeStartElement(state, se, 4, 47, 2, 18); + return _exiDecodeStartElement(state, se, 4, 54, 2, 18); } else if (state->eventCode == 15) { - return _exiDecodeStartElement(state, se, 4, 50, 2, 19); + return _exiDecodeStartElement(state, se, 4, 56, 2, 19); } else if (state->eventCode == 16) { - return _exiDecodeStartElement(state, se, 4, 52, 2, 20); + return _exiDecodeStartElement(state, se, 4, 58, 2, 20); } else if (state->eventCode == 17) { - return _exiDecodeStartElement(state, se, 4, 56, 2, 21); + return _exiDecodeStartElement(state, se, 4, 60, 2, 21); } else if (state->eventCode == 18) { - return _exiDecodeStartElement(state, se, 4, 58, 2, 22); + return _exiDecodeStartElement(state, se, 4, 62, 2, 22); } else if (state->eventCode == 19) { - return _exiDecodeStartElement(state, se, 6, 5, 2, 23); + return _exiDecodeStartElement(state, se, 4, 67, 2, 23); + } + else if (state->eventCode == 20) { + return _exiDecodeStartElement(state, se, 4, 69, 2, 24); + } + else if (state->eventCode == 21) { + return _exiDecodeStartElement(state, se, 4, 72, 2, 25); + } + else if (state->eventCode == 22) { + return _exiDecodeStartElement(state, se, 4, 74, 2, 26); + } + else if (state->eventCode == 23) { + return _exiDecodeStartElement(state, se, 4, 78, 2, 27); + } + else if (state->eventCode == 24) { + return _exiDecodeStartElement(state, se, 4, 80, 2, 28); + } + else if (state->eventCode == 25) { + return _exiDecodeStartElement(state, se, 4, 85, 2, 29); + } + else if (state->eventCode == 26) { + return _exiDecodeStartElement(state, se, 4, 87, 2, 30); + } + else if (state->eventCode == 27) { + return _exiDecodeStartElement(state, se, 6, 5, 2, 31); + } + else if (state->eventCode == 28) { + return _exiDecodeStartElement(state, se, 4, 90, 2, 32); + } + else if (state->eventCode == 29) { + return _exiDecodeStartElement(state, se, 4, 92, 2, 33); } break; case 5: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - return _exiDecodeStartElement(state, se, 4, 29, 24, 25); + return _exiDecodeStartElement(state, se, 4, 50, 34, 35); break; case 6: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 32, 33); + return _exiDecodeStartElement(state, se, 4, 66, 43, 44); break; case 7: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 24, 46, 47); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 29, 48, 25); - } + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 62, 35); break; case 8: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 67, 68); + return _exiDecodeStartElement(state, se, 4, 66, 81, 82); + break; + case 9: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 121, 35); break; case 10: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 69, 70); + return _exiDecodeStartElement(state, se, 4, 66, 126, 127); break; case 11: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ - return _exiDecodeStartElement(state, se, 4, 0, 78, 79); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 131, 35); break; case 12: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 80, 81); + return _exiDecodeStartElement(state, se, 4, 66, 133, 134); break; case 13: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - return _exiDecodeStartElement(state, se, 4, 29, 82, 25); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 43, 136, 137); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 50, 138, 35); + } break; case 14: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 85, 86); - break; - case 15: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - return _exiDecodeStartElement(state, se, 4, 29, 87, 25); + return _exiDecodeStartElement(state, se, 4, 66, 149, 150); break; case 16: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 95, 96); + return _exiDecodeStartElement(state, se, 4, 66, 151, 152); break; case 17: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 55, 132, 133); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 54, 134, 135); - } + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ + return _exiDecodeStartElement(state, se, 4, 9, 160, 161); break; case 18: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 136, 137); + return _exiDecodeStartElement(state, se, 4, 66, 162, 163); break; case 19: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ - return _exiDecodeStartElement(state, se, 4, 49, 155, 139); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 165, 35); break; case 20: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 156, 157); + return _exiDecodeStartElement(state, se, 4, 66, 168, 169); break; case 21: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 24, 158, 47); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 29, 159, 25); - } + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 171, 35); break; case 22: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - return _exiDecodeStartElement(state, se, 4, 44, 160, 161); + return _exiDecodeStartElement(state, se, 4, 66, 175, 176); break; case 23: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ - return _exiDecodeStartElement(state, se, 6, 4, 165, 166); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 77, 179, 180); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 76, 181, 182); + } break; case 24: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ - return _exiDecodeStartElement(state, se, 4, 42, 26, 27); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + return _exiDecodeStartElement(state, se, 4, 66, 183, 184); break; case 25: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - return _exiDecodeStartElement(state, se, 5, 4, 28, 27); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ + return _exiDecodeStartElement(state, se, 4, 71, 202, 186); + break; + case 26: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + return _exiDecodeStartElement(state, se, 4, 66, 203, 204); + break; + case 27: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 43, 205, 137); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 50, 206, 35); + } break; case 28: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ - return _exiDecodeStartElement(state, se, 5, 0, 29, 30); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + return _exiDecodeStartElement(state, se, 4, 66, 207, 208); + break; + case 29: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 212, 35); + break; + case 30: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + return _exiDecodeStartElement(state, se, 4, 66, 213, 214); + break; + case 31: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ + return _exiDecodeStartElement(state, se, 6, 4, 217, 218); break; case 32: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - return _exiDecodeStartElement(state, se, 4, 6, 34, 35); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 239, 35); + break; + case 33: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + return _exiDecodeStartElement(state, se, 4, 66, 240, 241); break; case 35: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ - return _exiDecodeStartElement(state, se, 5, 12, 36, 37); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + return _exiDecodeStartElement(state, se, 5, 4, 36, 37); break; case 36: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ - return _exiDecodeStartElement(state, se, 5, 7, 38, 30); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + return _exiDecodeStartElement(state, se, 5, 0, 38, 39); break; case 38: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - return _exiDecodeStartElement(state, se, 5, 4, 39, 27); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ReadyToCharge)] */ + return _exiDecodeStartElement(state, se, 5, 27, 40, 41); break; - case 39: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ - return _exiDecodeStartElement(state, se, 5, 23, 40, 41); - break; - case 40: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ - return _exiDecodeStartElement(state, se, 5, 25, 42, 43); - break; - case 42: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ - return _exiDecodeStartElement(state, se, 5, 36, 44, 45); + case 43: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 45, 46); break; case 46: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - return _exiDecodeStartElement(state, se, 4, 29, 48, 25); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ + return _exiDecodeStartElement(state, se, 5, 13, 47, 48); break; - case 48: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 60, 49, 45); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 61, 50, 51); - } + case 47: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ + return _exiDecodeStartElement(state, se, 5, 8, 49, 39); break; case 49: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - return _exiDecodeStartElement(state, se, 4, 61, 50, 51); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + return _exiDecodeStartElement(state, se, 5, 4, 50, 37); break; case 50: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ - return _exiDecodeStartElement(state, se, 4, 14, 52, 53); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ + return _exiDecodeStartElement(state, se, 5, 24, 51, 52); + break; + case 51: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ + return _exiDecodeStartElement(state, se, 5, 26, 53, 54); break; case 53: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 16, 54, 55); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 18, 56, 57); - } - else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 5, 19, 58, 59); - } - else if (state->eventCode == 3) { - return _exiDecodeStartElement(state, se, 5, 37, 60, 45); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ + return _exiDecodeStartElement(state, se, 5, 38, 55, 56); break; - case 54: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 18, 56, 57); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 19, 58, 59); - } - else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 5, 37, 60, 45); - } - break; - case 56: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 19, 58, 59); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 37, 60, 45); - } + case 55: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + return _exiDecodeStartElement(state, se, 5, 0, 57, 39); break; case 57: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ - return _exiDecodeStartElement(state, se, 5, 20, 61, 62); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEMalfunction)] */ + return _exiDecodeStartElement(state, se, 5, 7, 58, 59); break; case 58: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 37, 60, 45); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}StopCharging)] */ + return _exiDecodeStartElement(state, se, 5, 39, 60, 61); break; - case 61: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ - return _exiDecodeStartElement(state, se, 5, 49, 63, 64); + case 62: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargingMode)] */ + return _exiDecodeStartElement(state, se, 4, 8, 63, 64); break; case 63: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ - return _exiDecodeStartElement(state, se, 5, 50, 65, 66); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ + return _exiDecodeStartElement(state, se, 4, 27, 65, 56); + break; + case 65: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ + return _exiDecodeStartElement(state, se, 4, 15, 66, 67); + break; + case 66: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ + return _exiDecodeStartElement(state, se, 4, 46, 68, 67); + break; + case 67: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ + return _exiDecodeStartElement(state, se, 5, 21, 75, 76); + break; + case 68: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ + return _exiDecodeStartElement(state, se, 4, 45, 69, 70); break; case 69: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - return _exiDecodeStartElement(state, se, 4, 2, 71, 72); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 47, 71, 67); break; case 71: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - return _exiDecodeStartElement(state, se, 4, 6, 73, 35); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 49, 72, 67); + break; + case 72: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 44, 73, 67); break; case 73: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - return _exiDecodeStartElement(state, se, 4, 60, 74, 45); - break; - case 74: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ - return _exiDecodeStartElement(state, se, 4, 5, 75, 57); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 48, 74, 67); break; case 75: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 23, 76, 57); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 14, 77, 53); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ + return _exiDecodeStartElement(state, se, 5, 52, 77, 78); break; - case 76: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 14, 77, 53); - } + case 77: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ + return _exiDecodeStartElement(state, se, 5, 53, 79, 80); break; - case 82: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ - return _exiDecodeStartElement(state, se, 4, 43, 83, 41); + case 81: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 83, 46); break; case 83: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 61, 84, 51); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 20, 84, 67); + break; + case 84: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 22, 85, 67); + break; + case 85: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 17, 86, 67); + break; + case 86: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 21, 87, 67); break; case 87: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ - return _exiDecodeStartElement(state, se, 4, 9, 88, 45); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ + return _exiDecodeStartElement(state, se, 4, 18, 88, 70); break; case 88: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ - return _exiDecodeStartElement(state, se, 4, 1, 89, 57); - break; - case 89: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ - return _exiDecodeStartElement(state, se, 4, 26, 90, 57); - break; - case 90: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ - return _exiDecodeStartElement(state, se, 4, 25, 91, 92); - break; - case 91: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ - return _exiDecodeStartElement(state, se, 4, 27, 93, 57); - break; - case 93: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ - return _exiDecodeStartElement(state, se, 4, 28, 94, 57); - break; - case 95: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - return _exiDecodeStartElement(state, se, 4, 6, 97, 35); - break; - case 97: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEVoltage)] */ - return _exiDecodeStartElement(state, se, 4, 7, 98, 57); - break; - case 98: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEIMax)] */ - return _exiDecodeStartElement(state, se, 4, 3, 99, 57); - break; - case 99: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ - return _exiDecodeStartElement(state, se, 4, 4, 100, 92); - break; - case 100: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 8, 101, 102); + return _exiDecodeStartElement(state, se, 4, 26, 89, 90); } else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 62, 103, 104); + return _exiDecodeStartElement(state, se, 4, 84, 91, 92); } break; - case 101: + case 89: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 62, 103, 104); + return _exiDecodeStartElement(state, se, 4, 84, 91, 92); + } + break; + case 92: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency)] */ + return _exiDecodeStartElement(state, se, 5, 5, 93, 94); + break; + case 93: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff)] */ + return _exiDecodeStartElement(state, se, 5, 41, 95, 96); + break; + case 95: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 41, 97, 96); + } + break; + case 96: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ + return _exiDecodeStartElement(state, se, 5, 48, 102, 103); + break; + case 97: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 41, 98, 96); + } + break; + case 98: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 41, 99, 96); + } + break; + case 99: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 41, 100, 96); + } + break; + case 100: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 41, 101, 96); + } + break; + case 102: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 43, 104, 105); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 44, 106, 107); } break; case 104: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency)] */ - return _exiDecodeStartElement(state, se, 5, 5, 105, 106); - break; - case 105: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff)] */ - return _exiDecodeStartElement(state, se, 5, 38, 107, 108); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + return _exiDecodeStartElement(state, se, 5, 44, 106, 107); break; case 107: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 38, 109, 108); - } + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ + return _exiDecodeStartElement(state, se, 5, 46, 108, 109); break; case 108: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ - return _exiDecodeStartElement(state, se, 5, 45, 114, 51); - break; - case 109: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 38, 110, 108); + return _exiDecodeStartElement(state, se, 5, 46, 110, 109); } break; + case 109: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ + return _exiDecodeStartElement(state, se, 5, 50, 117, 118); + break; case 110: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 38, 111, 108); + return _exiDecodeStartElement(state, se, 5, 46, 111, 109); } break; case 111: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 38, 112, 108); + return _exiDecodeStartElement(state, se, 5, 46, 112, 109); } break; case 112: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 38, 113, 108); + return _exiDecodeStartElement(state, se, 5, 46, 113, 109); + } + break; + case 113: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 46, 114, 109); } break; case 114: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 40, 115, 116); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 41, 117, 118); + return _exiDecodeStartElement(state, se, 5, 46, 115, 109); } break; case 115: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ - return _exiDecodeStartElement(state, se, 5, 41, 117, 118); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 46, 116, 109); + } break; - case 118: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ - return _exiDecodeStartElement(state, se, 5, 43, 119, 120); + case 117: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ + return _exiDecodeStartElement(state, se, 5, 49, 119, 67); break; case 119: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 121, 120); - } - break; - case 120: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ - return _exiDecodeStartElement(state, se, 5, 47, 128, 129); - break; - case 121: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 122, 120); - } - break; - case 122: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 123, 120); - } - break; - case 123: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 124, 120); - } - break; - case 124: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 125, 120); - } - break; - case 125: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 126, 120); - } - break; - case 126: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 43, 127, 120); - } - break; - case 128: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ - return _exiDecodeStartElement(state, se, 5, 46, 130, 57); - break; - case 130: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 6, 131, 57); + return _exiDecodeStartElement(state, se, 5, 6, 120, 67); } break; - case 132: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 54, 134, 135); - } + case 121: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 51, 122, 67); + break; + case 122: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 42, 123, 67); + break; + case 123: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDifferential)] */ + return _exiDecodeStartElement(state, se, 4, 14, 124, 67); + break; + case 124: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + return _exiDecodeStartElement(state, se, 4, 89, 125, 67); + break; + case 126: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 128, 46); + break; + case 128: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 24, 129, 67); + break; + case 129: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 23, 130, 67); + break; + case 131: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ + return _exiDecodeStartElement(state, se, 4, 64, 132, 37); + break; + case 133: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 135, 46); break; case 136: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 138, 35); + break; + case 138: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 4, 49, 138, 139); + return _exiDecodeStartElement(state, se, 4, 82, 139, 56); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 83, 140, 103); } break; case 139: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ - return _exiDecodeStartElement(state, se, 5, 26, 140, 141); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ + return _exiDecodeStartElement(state, se, 4, 83, 140, 103); break; case 140: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 142, 141); - } - break; - case 141: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ - return _exiDecodeStartElement(state, se, 5, 28, 149, 150); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ + return _exiDecodeStartElement(state, se, 4, 32, 141, 142); break; case 142: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 143, 141); + return _exiDecodeStartElement(state, se, 5, 17, 143, 144); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 19, 145, 67); + } + else if (state->eventCode == 2) { + return _exiDecodeStartElement(state, se, 5, 20, 146, 147); + } + else if (state->eventCode == 3) { + return _exiDecodeStartElement(state, se, 5, 40, 148, 56); } break; case 143: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 144, 141); + return _exiDecodeStartElement(state, se, 5, 19, 145, 67); } - break; - case 144: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 145, 141); + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 20, 146, 147); + } + else if (state->eventCode == 2) { + return _exiDecodeStartElement(state, se, 5, 40, 148, 56); } break; case 145: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 146, 141); + return _exiDecodeStartElement(state, se, 5, 20, 146, 147); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 40, 148, 56); } break; case 146: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 147, 141); - } - break; - case 147: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 26, 148, 141); - } - break; - case 149: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 30, 151, 152); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 33, 153, 133); - } - else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 5, 31, 154, 135); + return _exiDecodeStartElement(state, se, 5, 40, 148, 56); } break; case 151: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 33, 153, 133); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 31, 154, 135); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + return _exiDecodeStartElement(state, se, 4, 16, 153, 154); break; case 153: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 155, 46); + break; + case 155: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 82, 156, 56); + break; + case 156: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ + return _exiDecodeStartElement(state, se, 4, 19, 157, 67); + break; + case 157: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 31, 154, 135); + return _exiDecodeStartElement(state, se, 4, 41, 158, 67); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 32, 159, 142); } break; case 158: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - return _exiDecodeStartElement(state, se, 4, 29, 159, 25); - break; - case 160: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - return _exiDecodeStartElement(state, se, 4, 2, 162, 72); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 32, 159, 142); + } break; case 162: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - return _exiDecodeStartElement(state, se, 4, 6, 163, 35); - break; - case 163: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - return _exiDecodeStartElement(state, se, 4, 60, 164, 45); + return _exiDecodeStartElement(state, se, 4, 82, 164, 56); break; case 165: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ - return _exiDecodeStartElement(state, se, 6, 0, 167, 168); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ + return _exiDecodeStartElement(state, se, 4, 65, 166, 52); break; case 166: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ - return _exiDecodeStartElement(state, se, 7, 2, 169, 170); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 83, 167, 103); + } break; case 168: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 6, 2, 186, 3); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 4, 10, 186, 5); - } - else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 4, 12, 186, 6); - } - else if (state->eventCode == 3) { - return _exiDecodeStartElement(state, se, 4, 15, 186, 7); - } - else if (state->eventCode == 4) { - return _exiDecodeStartElement(state, se, 4, 17, 186, 8); - } - else if (state->eventCode == 5) { - return _exiDecodeStartElement(state, se, 4, 19, 186, 9); - } - else if (state->eventCode == 6) { - return _exiDecodeStartElement(state, se, 4, 21, 186, 10); - } - else if (state->eventCode == 7) { - return _exiDecodeStartElement(state, se, 4, 30, 186, 11); - } - else if (state->eventCode == 8) { - return _exiDecodeStartElement(state, se, 4, 32, 186, 12); - } - else if (state->eventCode == 9) { - return _exiDecodeStartElement(state, se, 4, 34, 186, 13); - } - else if (state->eventCode == 10) { - return _exiDecodeStartElement(state, se, 4, 36, 186, 14); - } - else if (state->eventCode == 11) { - return _exiDecodeStartElement(state, se, 4, 38, 186, 15); - } - else if (state->eventCode == 12) { - return _exiDecodeStartElement(state, se, 4, 40, 186, 16); - } - else if (state->eventCode == 13) { - return _exiDecodeStartElement(state, se, 4, 45, 186, 17); - } - else if (state->eventCode == 14) { - return _exiDecodeStartElement(state, se, 4, 47, 186, 18); - } - else if (state->eventCode == 15) { - return _exiDecodeStartElement(state, se, 4, 50, 186, 19); - } - else if (state->eventCode == 16) { - return _exiDecodeStartElement(state, se, 4, 52, 186, 20); - } - else if (state->eventCode == 17) { - return _exiDecodeStartElement(state, se, 4, 56, 186, 21); - } - else if (state->eventCode == 18) { - return _exiDecodeStartElement(state, se, 4, 58, 186, 22); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 170, 46); break; - case 169: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 7, 1, 171, 172); - } - break; - case 170: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ - return _exiDecodeStartElement(state, se, 5, 34, 173, 174); + case 171: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 51, 172, 67); break; case 172: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 13, 178, 179); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 14, 180, 181); - } - else if (state->eventCode == 2) { - return _exiDecodeStartElement(state, se, 5, 10, 182, 183); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 42, 173, 67); break; case 173: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 32, 175, 174); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 24, 176, 177); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + return _exiDecodeStartElement(state, se, 4, 89, 174, 67); break; case 175: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 24, 176, 177); - } + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 177, 46); break; - case 178: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 14, 180, 181); - } - else if (state->eventCode == 1) { - return _exiDecodeStartElement(state, se, 5, 10, 182, 183); - } + case 177: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 24, 178, 67); break; - case 180: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + case 179: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ if (state->eventCode == 0) { - return _exiDecodeStartElement(state, se, 5, 10, 182, 183); + return _exiDecodeStartElement(state, se, 4, 76, 181, 182); } break; case 183: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 4, 71, 185, 186); + } + break; + case 186: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ + return _exiDecodeStartElement(state, se, 5, 28, 187, 188); + break; + case 187: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 189, 188); + } + break; + case 188: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ + return _exiDecodeStartElement(state, se, 5, 30, 196, 197); + break; + case 189: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 190, 188); + } + break; + case 190: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 191, 188); + } + break; + case 191: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 192, 188); + } + break; + case 192: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 193, 188); + } + break; + case 193: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 194, 188); + } + break; + case 194: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 28, 195, 188); + } + break; + case 196: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 32, 198, 199); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 35, 200, 180); + } + else if (state->eventCode == 2) { + return _exiDecodeStartElement(state, se, 5, 33, 201, 182); + } + break; + case 198: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 35, 200, 180); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 33, 201, 182); + } + break; + case 200: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 33, 201, 182); + } + break; + case 205: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + return _exiDecodeStartElement(state, se, 4, 50, 206, 35); + break; + case 207: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + return _exiDecodeStartElement(state, se, 4, 16, 209, 154); + break; + case 209: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 210, 46); + break; + case 210: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + return _exiDecodeStartElement(state, se, 4, 82, 211, 56); + break; + case 213: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 215, 46); + break; + case 215: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 24, 216, 67); + break; + case 217: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ + return _exiDecodeStartElement(state, se, 6, 0, 219, 220); + break; + case 218: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ + return _exiDecodeStartElement(state, se, 7, 2, 221, 222); + break; + case 220: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 6, 2, 238, 3); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 4, 0, 238, 5); + } + else if (state->eventCode == 2) { + return _exiDecodeStartElement(state, se, 4, 2, 238, 6); + } + else if (state->eventCode == 3) { + return _exiDecodeStartElement(state, se, 4, 4, 238, 7); + } + else if (state->eventCode == 4) { + return _exiDecodeStartElement(state, se, 4, 6, 238, 8); + } + else if (state->eventCode == 5) { + return _exiDecodeStartElement(state, se, 4, 10, 238, 9); + } + else if (state->eventCode == 6) { + return _exiDecodeStartElement(state, se, 4, 12, 238, 10); + } + else if (state->eventCode == 7) { + return _exiDecodeStartElement(state, se, 4, 28, 238, 11); + } + else if (state->eventCode == 8) { + return _exiDecodeStartElement(state, se, 4, 30, 238, 12); + } + else if (state->eventCode == 9) { + return _exiDecodeStartElement(state, se, 4, 33, 238, 13); + } + else if (state->eventCode == 10) { + return _exiDecodeStartElement(state, se, 4, 35, 238, 14); + } + else if (state->eventCode == 11) { + return _exiDecodeStartElement(state, se, 4, 37, 238, 15); + } + else if (state->eventCode == 12) { + return _exiDecodeStartElement(state, se, 4, 39, 238, 16); + } + else if (state->eventCode == 13) { + return _exiDecodeStartElement(state, se, 4, 52, 238, 17); + } + else if (state->eventCode == 14) { + return _exiDecodeStartElement(state, se, 4, 54, 238, 18); + } + else if (state->eventCode == 15) { + return _exiDecodeStartElement(state, se, 4, 56, 238, 19); + } + else if (state->eventCode == 16) { + return _exiDecodeStartElement(state, se, 4, 58, 238, 20); + } + else if (state->eventCode == 17) { + return _exiDecodeStartElement(state, se, 4, 60, 238, 21); + } + else if (state->eventCode == 18) { + return _exiDecodeStartElement(state, se, 4, 62, 238, 22); + } + else if (state->eventCode == 19) { + return _exiDecodeStartElement(state, se, 4, 67, 238, 23); + } + else if (state->eventCode == 20) { + return _exiDecodeStartElement(state, se, 4, 69, 238, 24); + } + else if (state->eventCode == 21) { + return _exiDecodeStartElement(state, se, 4, 72, 238, 25); + } + else if (state->eventCode == 22) { + return _exiDecodeStartElement(state, se, 4, 74, 238, 26); + } + else if (state->eventCode == 23) { + return _exiDecodeStartElement(state, se, 4, 78, 238, 27); + } + else if (state->eventCode == 24) { + return _exiDecodeStartElement(state, se, 4, 80, 238, 28); + } + else if (state->eventCode == 25) { + return _exiDecodeStartElement(state, se, 4, 85, 238, 29); + } + else if (state->eventCode == 26) { + return _exiDecodeStartElement(state, se, 4, 87, 238, 30); + } + else if (state->eventCode == 27) { + return _exiDecodeStartElement(state, se, 4, 90, 238, 32); + } + else if (state->eventCode == 28) { + return _exiDecodeStartElement(state, se, 4, 92, 238, 33); + } + break; + case 221: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 7, 1, 223, 224); + } + break; + case 222: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ + return _exiDecodeStartElement(state, se, 5, 36, 225, 226); + break; + case 224: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 14, 230, 231); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 15, 232, 233); + } + else if (state->eventCode == 2) { + return _exiDecodeStartElement(state, se, 5, 11, 234, 235); + } + break; + case 225: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 34, 227, 226); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 25, 228, 229); + } + break; + case 227: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 25, 228, 229); + } + break; + case 230: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 15, 232, 233); + } + else if (state->eventCode == 1) { + return _exiDecodeStartElement(state, se, 5, 11, 234, 235); + } + break; + case 232: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if (state->eventCode == 0) { + return _exiDecodeStartElement(state, se, 5, 11, 234, 235); + } + break; + case 235: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Event)] */ - return _exiDecodeStartElement(state, se, 5, 9, 184, 185); + return _exiDecodeStartElement(state, se, 5, 10, 236, 237); + break; + case 240: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + return _exiDecodeStartElement(state, se, 4, 25, 242, 46); + break; + case 242: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + return _exiDecodeStartElement(state, se, 4, 24, 243, 67); break; default: @@ -1447,150 +1853,170 @@ int exiDecodeCharacters(bitstream_t* stream, exi_state_t* state, uint32_t xsi; uint32_t bits; switch (state->grammarStack[state->stackIndex]) { - case 62: + case 103: /* CHARACTERS[ENUMERATION] */ - val->type = ENUMERATION; - decodeNBitUnsignedInteger(stream, 4, &val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 27: - /* CHARACTERS[BOOLEAN] */ - case 30: - /* CHARACTERS[BOOLEAN] */ - case 37: - /* CHARACTERS[BOOLEAN] */ - case 41: - /* CHARACTERS[BOOLEAN] */ - case 43: - /* CHARACTERS[BOOLEAN] */ - val->type = BOOLEAN; - decodeBoolean(stream, &val->boolean); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 47: - /* CHARACTERS[STRING] */ - case 55: - /* CHARACTERS[STRING] */ - case 79: - /* CHARACTERS[STRING] */ - case 102: - /* CHARACTERS[STRING] */ - case 106: - /* CHARACTERS[STRING] */ - case 116: - /* CHARACTERS[STRING] */ - case 135: - /* CHARACTERS[STRING] */ - case 152: - /* CHARACTERS[STRING] */ - case 177: - /* CHARACTERS[STRING] */ - val->type = STRING; - decodeStringValue(stream, &val->string); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 68: + case 169: /* CHARACTERS[ENUMERATION] */ - case 70: + case 184: /* CHARACTERS[ENUMERATION] */ - case 96: + case 208: /* CHARACTERS[ENUMERATION] */ - val->type = ENUMERATION; - decodeNBitUnsignedInteger(stream, 1, &val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 33: - /* CHARACTERS[ENUMERATION] */ - case 81: - /* CHARACTERS[ENUMERATION] */ - case 133: - /* CHARACTERS[ENUMERATION] */ - case 157: - /* CHARACTERS[ENUMERATION] */ - case 179: - /* CHARACTERS[ENUMERATION] */ - val->type = ENUMERATION; - decodeNBitUnsignedInteger(stream, 2, &val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 72: - /* CHARACTERS[BINARY_HEX] */ - case 150: - /* CHARACTERS[BINARY_HEX] */ - case 174: - /* CHARACTERS[BINARY_HEX] */ - val->type = BINARY_HEX; - decodeBinary(stream, &val->binary); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 181: - /* CHARACTERS[STRING] */ - /* xsi:type OR xsi:nil */ - decodeNBitUnsignedInteger(stream, 1, &xsi); - val->type = STRING; - decodeStringValue(stream, &val->string); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 66: - /* CHARACTERS[INTEGER_32] */ - /* xsi:type OR xsi:nil */ - decodeNBitUnsignedInteger(stream, 1, &xsi); - val->type = INTEGER_32; - decodeInteger32(stream, &val->int32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 51: - /* CHARACTERS[ENUMERATION] */ - case 86: - /* CHARACTERS[ENUMERATION] */ - case 137: - /* CHARACTERS[ENUMERATION] */ - case 161: - /* CHARACTERS[ENUMERATION] */ - case 185: + case 237: /* CHARACTERS[ENUMERATION] */ val->type = ENUMERATION; decodeNBitUnsignedInteger(stream, 3, &val->enumeration); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; return 0; - case 59: + case 44: + /* CHARACTERS[ENUMERATION] */ + case 64: + /* CHARACTERS[ENUMERATION] */ + case 127: + /* CHARACTERS[ENUMERATION] */ + case 150: + /* CHARACTERS[ENUMERATION] */ + case 152: + /* CHARACTERS[ENUMERATION] */ + case 176: + /* CHARACTERS[ENUMERATION] */ + case 214: + /* CHARACTERS[ENUMERATION] */ + case 241: + /* CHARACTERS[ENUMERATION] */ + val->type = ENUMERATION; + decodeNBitUnsignedInteger(stream, 1, &val->enumeration); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 80: + /* CHARACTERS[INTEGER_32] */ + /* xsi:type OR xsi:nil */ + decodeNBitUnsignedInteger(stream, 1, &xsi); + val->type = INTEGER_32; + decodeInteger32(stream, &val->int32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 82: + /* CHARACTERS[ENUMERATION] */ + case 134: + /* CHARACTERS[ENUMERATION] */ + case 163: + /* CHARACTERS[ENUMERATION] */ + case 180: + /* CHARACTERS[ENUMERATION] */ + case 204: + /* CHARACTERS[ENUMERATION] */ + case 231: + /* CHARACTERS[ENUMERATION] */ + val->type = ENUMERATION; + decodeNBitUnsignedInteger(stream, 2, &val->enumeration); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 90: + /* CHARACTERS[STRING] */ + case 94: + /* CHARACTERS[STRING] */ + case 105: + /* CHARACTERS[STRING] */ + case 137: + /* CHARACTERS[STRING] */ + case 144: + /* CHARACTERS[STRING] */ + case 161: + /* CHARACTERS[STRING] */ + case 182: + /* CHARACTERS[STRING] */ + case 199: + /* CHARACTERS[STRING] */ + case 229: + /* CHARACTERS[STRING] */ + val->type = STRING; + decodeStringValue(stream, &val->string); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 76: /* CHARACTERS[INTEGER_16] */ - case 92: + case 70: + /* CHARACTERS[INTEGER_16] */ + case 147: /* CHARACTERS[INTEGER_16] */ val->type = INTEGER_16; decodeInteger32(stream, &val->int32); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; return 0; - case 45: - /* CHARACTERS[INTEGER_32] */ - val->type = INTEGER_32; - decodeInteger32(stream, &val->int32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - case 64: + case 78: /* CHARACTERS[ENUMERATION] */ val->type = ENUMERATION; decodeNBitUnsignedInteger(stream, 5, &val->enumeration); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; return 0; - case 129: + case 118: /* CHARACTERS[UNSIGNED_INTEGER_32] */ val->type = UNSIGNED_INTEGER_32; decodeUnsignedInteger32(stream, &val->uint32); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; + return 0; + case 37: + /* CHARACTERS[BOOLEAN] */ + case 39: + /* CHARACTERS[BOOLEAN] */ + case 48: + /* CHARACTERS[BOOLEAN] */ + case 52: + /* CHARACTERS[BOOLEAN] */ + case 54: + /* CHARACTERS[BOOLEAN] */ + val->type = BOOLEAN; + decodeBoolean(stream, &val->boolean); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 41: + /* CHARACTERS[BOOLEAN] */ + case 59: + /* CHARACTERS[BOOLEAN] */ + case 61: + /* CHARACTERS[BOOLEAN] */ + /* xsi:type OR xsi:nil */ + decodeNBitUnsignedInteger(stream, 1, &xsi); + val->type = BOOLEAN; + decodeBoolean(stream, &val->boolean); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 56: + /* CHARACTERS[INTEGER_32] */ + val->type = INTEGER_32; + decodeInteger32(stream, &val->int32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 233: + /* CHARACTERS[STRING] */ + /* xsi:type OR xsi:nil */ + decodeNBitUnsignedInteger(stream, 1, &xsi); + val->type = STRING; + decodeStringValue(stream, &val->string); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + case 154: + /* CHARACTERS[BINARY_HEX] */ + case 197: + /* CHARACTERS[BINARY_HEX] */ + case 226: + /* CHARACTERS[BINARY_HEX] */ + val->type = BINARY_HEX; + decodeBinary(stream, &val->binary); + /* move on */ + state->grammarStack[state->stackIndex] = 42; return 0; default: diff --git a/src/codec/EXIDecoder.h b/src/codec/EXIDecoder.h index db000d4..91e650e 100644 --- a/src/codec/EXIDecoder.h +++ b/src/codec/EXIDecoder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXIEncoder.c b/src/codec/EXIEncoder.c index 730a88e..12222e5 100644 --- a/src/codec/EXIEncoder.c +++ b/src/codec/EXIEncoder.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * *NOTE: Code generated by EXIdizer v0.1
@@ -84,1001 +84,1347 @@ int exiEncodeStartElement(bitstream_t* stream, exi_state_t* state, eqname_t* se) { switch (state->grammarStack[state->stackIndex]) { case 1: - /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT_GENERIC] */ + /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), START_ELEMENT_GENERIC] */ if ( se->localPart == 2 && se->namespaceURI == 6 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement) */ return _exiEncodeStartElement(stream, 5, 0, state, se, 2, 3); } - else if ( se->localPart == 10 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq) */ + else if ( se->localPart == 0 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq) */ return _exiEncodeStartElement(stream, 5, 1, state, se, 2, 5); } - else if ( se->localPart == 12 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes) */ + else if ( se->localPart == 2 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes) */ return _exiEncodeStartElement(stream, 5, 2, state, se, 2, 6); } - else if ( se->localPart == 15 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq) */ + else if ( se->localPart == 4 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq) */ return _exiEncodeStartElement(stream, 5, 3, state, se, 2, 7); } - else if ( se->localPart == 17 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes) */ + else if ( se->localPart == 6 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes) */ return _exiEncodeStartElement(stream, 5, 4, state, se, 2, 8); } - else if ( se->localPart == 19 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq) */ + else if ( se->localPart == 10 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq) */ return _exiEncodeStartElement(stream, 5, 5, state, se, 2, 9); } - else if ( se->localPart == 21 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes) */ + else if ( se->localPart == 12 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes) */ return _exiEncodeStartElement(stream, 5, 6, state, se, 2, 10); } - else if ( se->localPart == 30 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq) */ + else if ( se->localPart == 28 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq) */ return _exiEncodeStartElement(stream, 5, 7, state, se, 2, 11); } - else if ( se->localPart == 32 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes) */ + else if ( se->localPart == 30 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes) */ return _exiEncodeStartElement(stream, 5, 8, state, se, 2, 12); } - else if ( se->localPart == 34 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq) */ + else if ( se->localPart == 33 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq) */ return _exiEncodeStartElement(stream, 5, 9, state, se, 2, 13); } - else if ( se->localPart == 36 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes) */ + else if ( se->localPart == 35 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes) */ return _exiEncodeStartElement(stream, 5, 10, state, se, 2, 14); } - else if ( se->localPart == 38 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq) */ + else if ( se->localPart == 37 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq) */ return _exiEncodeStartElement(stream, 5, 11, state, se, 2, 15); } - else if ( se->localPart == 40 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes) */ + else if ( se->localPart == 39 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes) */ return _exiEncodeStartElement(stream, 5, 12, state, se, 2, 16); } - else if ( se->localPart == 45 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq) */ + else if ( se->localPart == 52 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq) */ return _exiEncodeStartElement(stream, 5, 13, state, se, 2, 17); } - else if ( se->localPart == 47 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes) */ + else if ( se->localPart == 54 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes) */ return _exiEncodeStartElement(stream, 5, 14, state, se, 2, 18); } - else if ( se->localPart == 50 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq) */ + else if ( se->localPart == 56 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq) */ return _exiEncodeStartElement(stream, 5, 15, state, se, 2, 19); } - else if ( se->localPart == 52 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes) */ + else if ( se->localPart == 58 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes) */ return _exiEncodeStartElement(stream, 5, 16, state, se, 2, 20); } - else if ( se->localPart == 56 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq) */ + else if ( se->localPart == 60 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq) */ return _exiEncodeStartElement(stream, 5, 17, state, se, 2, 21); } - else if ( se->localPart == 58 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes) */ + else if ( se->localPart == 62 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes) */ return _exiEncodeStartElement(stream, 5, 18, state, se, 2, 22); } + else if ( se->localPart == 67 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq) */ + return _exiEncodeStartElement(stream, 5, 19, state, se, 2, 23); + } + else if ( se->localPart == 69 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes) */ + return _exiEncodeStartElement(stream, 5, 20, state, se, 2, 24); + } + else if ( se->localPart == 72 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq) */ + return _exiEncodeStartElement(stream, 5, 21, state, se, 2, 25); + } + else if ( se->localPart == 74 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes) */ + return _exiEncodeStartElement(stream, 5, 22, state, se, 2, 26); + } + else if ( se->localPart == 78 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq) */ + return _exiEncodeStartElement(stream, 5, 23, state, se, 2, 27); + } + else if ( se->localPart == 80 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes) */ + return _exiEncodeStartElement(stream, 5, 24, state, se, 2, 28); + } + else if ( se->localPart == 85 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq) */ + return _exiEncodeStartElement(stream, 5, 25, state, se, 2, 29); + } + else if ( se->localPart == 87 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes) */ + return _exiEncodeStartElement(stream, 5, 26, state, se, 2, 30); + } else if ( se->localPart == 5 && se->namespaceURI == 6 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}V2G_Message) */ - return _exiEncodeStartElement(stream, 5, 19, state, se, 2, 23); + return _exiEncodeStartElement(stream, 5, 27, state, se, 2, 31); + } + else if ( se->localPart == 90 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq) */ + return _exiEncodeStartElement(stream, 5, 28, state, se, 2, 32); + } + else if ( se->localPart == 92 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes) */ + return _exiEncodeStartElement(stream, 5, 29, state, se, 2, 33); } break; case 5: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 29 && se->namespaceURI == 4 ) { + if ( se->localPart == 50 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 24, 25); + return _exiEncodeStartElement(stream, 0, 0, state, se, 34, 35); } break; case 6: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 32, 33); + return _exiEncodeStartElement(stream, 0, 0, state, se, 43, 44); } break; case 7: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 24 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 46, 47); - } - else if ( se->localPart == 29 && se->namespaceURI == 4 ) { + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 1, 1, state, se, 48, 25); + return _exiEncodeStartElement(stream, 0, 0, state, se, 62, 35); } break; case 8: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 67, 68); + return _exiEncodeStartElement(stream, 0, 0, state, se, 81, 82); + } + break; + case 9: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 121, 35); } break; case 10: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 69, 70); + return _exiEncodeStartElement(stream, 0, 0, state, se, 126, 127); } break; case 11: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ - if ( se->localPart == 0 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 78, 79); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 131, 35); } break; case 12: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 80, 81); + return _exiEncodeStartElement(stream, 0, 0, state, se, 133, 134); } break; case 13: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 29 && se->namespaceURI == 4 ) { + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 43 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 136, 137); + } + else if ( se->localPart == 50 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 82, 25); + return _exiEncodeStartElement(stream, 1, 1, state, se, 138, 35); } break; case 14: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 85, 86); - } - break; - case 15: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 29 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 87, 25); + return _exiEncodeStartElement(stream, 0, 0, state, se, 149, 150); } break; case 16: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 95, 96); + return _exiEncodeStartElement(stream, 0, 0, state, se, 151, 152); } break; case 17: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - if ( se->localPart == 55 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 132, 133); - } - else if ( se->localPart == 54 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 134, 135); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID)] */ + if ( se->localPart == 9 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ContractID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 160, 161); } break; case 18: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 136, 137); + return _exiEncodeStartElement(stream, 0, 0, state, se, 162, 163); } break; case 19: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ - if ( se->localPart == 49 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 155, 139); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 165, 35); } break; case 20: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 156, 157); + return _exiEncodeStartElement(stream, 0, 0, state, se, 168, 169); } break; case 21: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 24 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 158, 47); - } - else if ( se->localPart == 29 && se->namespaceURI == 4 ) { + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 1, 1, state, se, 159, 25); + return _exiEncodeStartElement(stream, 0, 0, state, se, 171, 35); } break; case 22: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ - if ( se->localPart == 44 && se->namespaceURI == 4 ) { + if ( se->localPart == 66 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 160, 161); + return _exiEncodeStartElement(stream, 0, 0, state, se, 175, 176); } break; case 23: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ - if ( se->localPart == 4 && se->namespaceURI == 6 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 165, 166); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ + if ( se->localPart == 77 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 179, 180); + } + else if ( se->localPart == 76 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 181, 182); } break; case 24: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ - if ( se->localPart == 42 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 26, 27); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + if ( se->localPart == 66 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 183, 184); } break; case 25: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - if ( se->localPart == 4 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 28, 27); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList)] */ + if ( se->localPart == 71 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 202, 186); + } + break; + case 26: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + if ( se->localPart == 66 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 203, 204); + } + break; + case 27: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 43 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVID) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 205, 137); + } + else if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 1, 1, state, se, 206, 35); } break; case 28: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ - if ( se->localPart == 0 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 29, 30); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + if ( se->localPart == 66 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 207, 208); + } + break; + case 29: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 212, 35); + } + break; + case 30: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + if ( se->localPart == 66 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 213, 214); + } + break; + case 31: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header)] */ + if ( se->localPart == 4 && se->namespaceURI == 6 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Header) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 217, 218); } break; case 32: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - if ( se->localPart == 6 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 34, 35); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 239, 35); + } + break; + case 33: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode)] */ + if ( se->localPart == 66 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ResponseCode) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 240, 241); } break; case 35: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ - if ( se->localPart == 12 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError) */ + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + if ( se->localPart == 4 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked) */ return _exiEncodeStartElement(stream, 0, 0, state, se, 36, 37); } break; case 36: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ - if ( se->localPart == 7 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 38, 30); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + if ( se->localPart == 0 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 38, 39); } break; case 38: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ - if ( se->localPart == 4 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 39, 27); - } - break; - case 39: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ - if ( se->localPart == 23 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed) */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ReadyToCharge)] */ + if ( se->localPart == 27 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ReadyToCharge) */ return _exiEncodeStartElement(stream, 0, 0, state, se, 40, 41); } break; - case 40: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ - if ( se->localPart == 25 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 42, 43); - } - break; - case 42: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ - if ( se->localPart == 36 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 44, 45); + case 43: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 45, 46); } break; case 46: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 29 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 48, 25); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError)] */ + if ( se->localPart == 13 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FatalError) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 47, 48); } break; - case 48: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - if ( se->localPart == 60 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 49, 45); - } - else if ( se->localPart == 61 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ - return _exiEncodeStartElement(stream, 1, 1, state, se, 50, 51); + case 47: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby)] */ + if ( se->localPart == 8 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEStandby) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 49, 39); } break; case 49: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ - if ( se->localPart == 61 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 50, 51); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked)] */ + if ( se->localPart == 4 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ConnectorLocked) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 50, 37); } break; case 50: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ - if ( se->localPart == 14 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 52, 53); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed)] */ + if ( se->localPart == 24 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}PowerSwitchClosed) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 51, 52); + } + break; + case 51: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD)] */ + if ( se->localPart == 26 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}RCD) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 53, 54); } break; case 53: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if ( se->localPart == 16 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID) */ - return _exiEncodeStartElement(stream, 3, 0, state, se, 54, 55); - } - else if ( se->localPart == 18 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading) */ - return _exiEncodeStartElement(stream, 3, 1, state, se, 56, 57); - } - else if ( se->localPart == 19 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ - return _exiEncodeStartElement(stream, 3, 2, state, se, 58, 59); - } - else if ( se->localPart == 37 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ - return _exiEncodeStartElement(stream, 3, 3, state, se, 60, 45); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime)] */ + if ( se->localPart == 38 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ShutDownTime) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 55, 56); } break; - case 54: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if ( se->localPart == 18 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 56, 57); - } - else if ( se->localPart == 19 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 58, 59); - } - else if ( se->localPart == 37 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ - return _exiEncodeStartElement(stream, 2, 2, state, se, 60, 45); - } - break; - case 56: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if ( se->localPart == 19 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 58, 59); - } - else if ( se->localPart == 37 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 60, 45); + case 55: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby)] */ + if ( se->localPart == 0 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ChargerStandby) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 57, 39); } break; case 57: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ - if ( se->localPart == 20 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 61, 62); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEMalfunction)] */ + if ( se->localPart == 7 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EVSEMalfunction) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 58, 59); } break; case 58: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - if ( se->localPart == 37 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 60, 45); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}StopCharging)] */ + if ( se->localPart == 39 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}StopCharging) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 60, 61); } break; - case 61: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ - if ( se->localPart == 49 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit) */ + case 62: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargingMode)] */ + if ( se->localPart == 8 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargingMode) */ return _exiEncodeStartElement(stream, 0, 0, state, se, 63, 64); } break; case 63: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ - if ( se->localPart == 50 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 65, 66); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ + if ( se->localPart == 27 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 65, 56); + } + break; + case 65: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ + if ( se->localPart == 15 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 66, 67); + } + break; + case 66: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ + if ( se->localPart == 46 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 68, 67); + } + break; + case 67: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier)] */ + if ( se->localPart == 21 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Multiplier) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 75, 76); + } + break; + case 68: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ + if ( se->localPart == 45 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 69, 70); } break; case 69: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - if ( se->localPart == 2 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 71, 72); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ + if ( se->localPart == 47 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 71, 67); } break; case 71: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - if ( se->localPart == 6 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 73, 35); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ + if ( se->localPart == 49 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 72, 67); + } + break; + case 72: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxCurrent)] */ + if ( se->localPart == 44 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 73, 67); } break; case 73: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - if ( se->localPart == 60 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 74, 45); - } - break; - case 74: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ - if ( se->localPart == 5 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 75, 57); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinCurrent)] */ + if ( se->localPart == 48 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 74, 67); } break; case 75: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - if ( se->localPart == 23 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 76, 57); - } - else if ( se->localPart == 14 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 77, 53); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit)] */ + if ( se->localPart == 52 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Unit) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 77, 78); } break; - case 76: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - if ( se->localPart == 14 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 77, 53); + case 77: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value)] */ + if ( se->localPart == 53 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Value) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 79, 80); } break; - case 82: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ - if ( se->localPart == 43 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 83, 41); + case 81: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 83, 46); } break; case 83: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ - if ( se->localPart == 61 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 84, 51); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxVoltage)] */ + if ( se->localPart == 20 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 84, 67); + } + break; + case 84: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinVoltage)] */ + if ( se->localPart == 22 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 85, 67); + } + break; + case 85: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxCurrent)] */ + if ( se->localPart == 17 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 86, 67); + } + break; + case 86: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinCurrent)] */ + if ( se->localPart == 21 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMinCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 87, 67); } break; case 87: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC)] */ - if ( se->localPart == 9 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EoC) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 88, 45); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ + if ( se->localPart == 18 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 88, 70); } break; case 88: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount)] */ - if ( se->localPart == 1 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EAmount) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 89, 57); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ + if ( se->localPart == 26 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 89, 90); + } + else if ( se->localPart == 84 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 91, 92); } break; case 89: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower)] */ - if ( se->localPart == 26 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPower) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 90, 57); - } - break; - case 90: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases)] */ - if ( se->localPart == 25 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxPhases) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 91, 92); - } - break; - case 91: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage)] */ - if ( se->localPart == 27 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMaxVoltage) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 93, 57); - } - break; - case 93: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage)] */ - if ( se->localPart == 28 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVMinVoltage) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 94, 57); - } - break; - case 95: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - if ( se->localPart == 6 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 97, 35); - } - break; - case 97: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEVoltage)] */ - if ( se->localPart == 7 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEVoltage) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 98, 57); - } - break; - case 98: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEIMax)] */ - if ( se->localPart == 3 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEIMax) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 99, 57); - } - break; - case 99: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases)] */ - if ( se->localPart == 4 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPhases) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 100, 92); - } - break; - case 100: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ - if ( se->localPart == 8 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 101, 102); - } - else if ( se->localPart == 62 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 103, 104); - } - break; - case 101: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ - if ( se->localPart == 62 && se->namespaceURI == 4 ) { + if ( se->localPart == 84 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 103, 104); + return _exiEncodeStartElement(stream, 1, 0, state, se, 91, 92); } break; - case 104: + case 92: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency)] */ if ( se->localPart == 5 && se->namespaceURI == 5 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Currency) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 105, 106); + return _exiEncodeStartElement(stream, 0, 0, state, se, 93, 94); } break; - case 105: + case 93: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff)] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { + if ( se->localPart == 41 && se->namespaceURI == 5 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 107, 108); + return _exiEncodeStartElement(stream, 0, 0, state, se, 95, 96); + } + break; + case 95: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 97, 96); + } + break; + case 96: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ + if ( se->localPart == 48 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 102, 103); + } + break; + case 97: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 98, 96); + } + break; + case 98: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 99, 96); + } + break; + case 99: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 100, 96); + } + break; + case 100: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 101, 96); + } + break; + case 102: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + if ( se->localPart == 43 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 104, 105); + } + else if ( se->localPart == 44 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries) */ + return _exiEncodeStartElement(stream, 1, 1, state, se, 106, 107); + } + break; + case 104: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ + if ( se->localPart == 44 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 106, 107); } break; case 107: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 109, 108); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 108, 109); } break; case 108: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID)] */ - if ( se->localPart == 45 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 114, 51); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 110, 109); } break; case 109: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 110, 108); - } - break; - case 110: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 111, 108); - } - break; - case 111: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 112, 108); - } - break; - case 112: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - if ( se->localPart == 38 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 113, 108); - } - break; - case 114: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ - if ( se->localPart == 40 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffDescription) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 115, 116); - } - else if ( se->localPart == 41 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries) */ - return _exiEncodeStartElement(stream, 1, 1, state, se, 117, 118); - } - break; - case 115: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries)] */ - if ( se->localPart == 41 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntries) */ + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ + if ( se->localPart == 50 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart) */ return _exiEncodeStartElement(stream, 0, 0, state, se, 117, 118); } break; - case 118: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry)] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { + case 110: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 119, 120); + return _exiEncodeStartElement(stream, 1, 0, state, se, 111, 109); + } + break; + case 111: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 112, 109); + } + break; + case 112: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 113, 109); + } + break; + case 113: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 114, 109); + } + break; + case 114: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 115, 109); + } + break; + case 115: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + if ( se->localPart == 46 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 116, 109); + } + break; + case 117: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ + if ( se->localPart == 49 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 119, 67); } break; case 119: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 121, 120); - } - break; - case 120: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart)] */ - if ( se->localPart == 47 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffStart) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 128, 129); - } - break; - case 121: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 122, 120); - } - break; - case 122: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 123, 120); - } - break; - case 123: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 124, 120); - } - break; - case 124: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 125, 120); - } - break; - case 125: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 126, 120); - } - break; - case 126: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - if ( se->localPart == 43 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 127, 120); - } - break; - case 128: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax)] */ - if ( se->localPart == 46 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffPMax) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 130, 57); - } - break; - case 130: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice), END_ELEMENT] */ if ( se->localPart == 6 && se->namespaceURI == 5 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 131, 57); + return _exiEncodeStartElement(stream, 1, 0, state, se, 120, 67); } break; - case 132: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - if ( se->localPart == 54 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 134, 135); + case 121: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + if ( se->localPart == 51 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 122, 67); + } + break; + case 122: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + if ( se->localPart == 42 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 123, 67); + } + break; + case 123: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDifferential)] */ + if ( se->localPart == 14 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDifferential) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 124, 67); + } + break; + case 124: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + if ( se->localPart == 89 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 125, 67); + } + break; + case 126: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 128, 46); + } + break; + case 128: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + if ( se->localPart == 24 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 129, 67); + } + break; + case 129: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentCurrent)] */ + if ( se->localPart == 23 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 130, 67); + } + break; + case 131: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus)] */ + if ( se->localPart == 64 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqLockStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 132, 37); + } + break; + case 133: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 135, 46); } break; case 136: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ - if ( se->localPart == 49 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 138, 139); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 138, 35); + } + break; + case 138: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ + if ( se->localPart == 82 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 139, 56); + } + else if ( se->localPart == 83 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ + return _exiEncodeStartElement(stream, 1, 1, state, se, 140, 103); } break; case 139: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 140, 141); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff)] */ + if ( se->localPart == 83 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 140, 103); } break; case 140: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 142, 141); - } - break; - case 141: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ - if ( se->localPart == 28 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 149, 150); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo)] */ + if ( se->localPart == 32 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 141, 142); } break; case 142: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 143, 141); + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + if ( se->localPart == 17 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID) */ + return _exiEncodeStartElement(stream, 3, 0, state, se, 143, 144); + } + else if ( se->localPart == 19 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading) */ + return _exiEncodeStartElement(stream, 3, 1, state, se, 145, 67); + } + else if ( se->localPart == 20 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ + return _exiEncodeStartElement(stream, 3, 2, state, se, 146, 147); + } + else if ( se->localPart == 40 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ + return _exiEncodeStartElement(stream, 3, 3, state, se, 148, 56); } break; case 143: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 144, 141); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + if ( se->localPart == 19 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 145, 67); } - break; - case 144: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 145, 141); + else if ( se->localPart == 20 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 146, 147); + } + else if ( se->localPart == 40 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ + return _exiEncodeStartElement(stream, 2, 2, state, se, 148, 56); } break; case 145: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 146, 141); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + if ( se->localPart == 20 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 146, 147); + } + else if ( se->localPart == 40 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 148, 56); } break; case 146: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 147, 141); - } - break; - case 147: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - if ( se->localPart == 26 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 148, 141); - } - break; - case 149: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - if ( se->localPart == 30 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 151, 152); - } - else if ( se->localPart == 33 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 153, 133); - } - else if ( se->localPart == 31 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ - return _exiEncodeStartElement(stream, 2, 2, state, se, 154, 135); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + if ( se->localPart == 40 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 148, 56); } break; case 151: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - if ( se->localPart == 33 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 153, 133); - } - else if ( se->localPart == 31 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 154, 135); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + if ( se->localPart == 16 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 153, 154); } break; case 153: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - if ( se->localPart == 31 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 154, 135); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 155, 46); + } + break; + case 155: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + if ( se->localPart == 82 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 156, 56); + } + break; + case 156: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower)] */ + if ( se->localPart == 19 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEMaxPower) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 157, 67); + } + break; + case 157: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + if ( se->localPart == 41 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 158, 67); + } + else if ( se->localPart == 32 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 159, 142); } break; case 158: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ - if ( se->localPart == 29 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 159, 25); - } - break; - case 160: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ - if ( se->localPart == 2 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 162, 72); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + if ( se->localPart == 32 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 159, 142); } break; case 162: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ - if ( se->localPart == 6 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 163, 35); - } - break; - case 163: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ - if ( se->localPart == 60 && se->namespaceURI == 4 ) { + if ( se->localPart == 82 && se->namespaceURI == 4 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 164, 45); + return _exiEncodeStartElement(stream, 0, 0, state, se, 164, 56); } break; case 165: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ - if ( se->localPart == 0 && se->namespaceURI == 6 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 167, 168); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus)] */ + if ( se->localPart == 65 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ReqSwitchStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 166, 52); } break; case 166: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ - if ( se->localPart == 2 && se->namespaceURI == 7 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 169, 170); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ + if ( se->localPart == 83 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 167, 103); } break; case 168: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), END_ELEMENT] */ - if ( se->localPart == 2 && se->namespaceURI == 6 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement) */ - return _exiEncodeStartElement(stream, 5, 0, state, se, 186, 3); - } - else if ( se->localPart == 10 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq) */ - return _exiEncodeStartElement(stream, 5, 1, state, se, 186, 5); - } - else if ( se->localPart == 12 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes) */ - return _exiEncodeStartElement(stream, 5, 2, state, se, 186, 6); - } - else if ( se->localPart == 15 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq) */ - return _exiEncodeStartElement(stream, 5, 3, state, se, 186, 7); - } - else if ( se->localPart == 17 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes) */ - return _exiEncodeStartElement(stream, 5, 4, state, se, 186, 8); - } - else if ( se->localPart == 19 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq) */ - return _exiEncodeStartElement(stream, 5, 5, state, se, 186, 9); - } - else if ( se->localPart == 21 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes) */ - return _exiEncodeStartElement(stream, 5, 6, state, se, 186, 10); - } - else if ( se->localPart == 30 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq) */ - return _exiEncodeStartElement(stream, 5, 7, state, se, 186, 11); - } - else if ( se->localPart == 32 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes) */ - return _exiEncodeStartElement(stream, 5, 8, state, se, 186, 12); - } - else if ( se->localPart == 34 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq) */ - return _exiEncodeStartElement(stream, 5, 9, state, se, 186, 13); - } - else if ( se->localPart == 36 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes) */ - return _exiEncodeStartElement(stream, 5, 10, state, se, 186, 14); - } - else if ( se->localPart == 38 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq) */ - return _exiEncodeStartElement(stream, 5, 11, state, se, 186, 15); - } - else if ( se->localPart == 40 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes) */ - return _exiEncodeStartElement(stream, 5, 12, state, se, 186, 16); - } - else if ( se->localPart == 45 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq) */ - return _exiEncodeStartElement(stream, 5, 13, state, se, 186, 17); - } - else if ( se->localPart == 47 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes) */ - return _exiEncodeStartElement(stream, 5, 14, state, se, 186, 18); - } - else if ( se->localPart == 50 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq) */ - return _exiEncodeStartElement(stream, 5, 15, state, se, 186, 19); - } - else if ( se->localPart == 52 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes) */ - return _exiEncodeStartElement(stream, 5, 16, state, se, 186, 20); - } - else if ( se->localPart == 56 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq) */ - return _exiEncodeStartElement(stream, 5, 17, state, se, 186, 21); - } - else if ( se->localPart == 58 && se->namespaceURI == 4 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes) */ - return _exiEncodeStartElement(stream, 5, 18, state, se, 186, 22); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 170, 46); } break; - case 169: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ - if ( se->localPart == 1 && se->namespaceURI == 7 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 171, 172); - } - break; - case 170: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ - if ( se->localPart == 34 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 173, 174); + case 171: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage)] */ + if ( se->localPart == 51 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVTargetVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 172, 67); } break; case 172: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - if ( se->localPart == 13 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 178, 179); - } - else if ( se->localPart == 14 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 180, 181); - } - else if ( se->localPart == 10 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ - return _exiEncodeStartElement(stream, 2, 2, state, se, 182, 183); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent)] */ + if ( se->localPart == 42 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVDemandCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 173, 67); } break; case 173: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - if ( se->localPart == 32 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 175, 174); - } - else if ( se->localPart == 24 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 176, 177); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential)] */ + if ( se->localPart == 89 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}VoltageDifferential) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 174, 67); } break; case 175: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - if ( se->localPart == 24 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 176, 177); + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 177, 46); } break; - case 178: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - if ( se->localPart == 14 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg) */ - return _exiEncodeStartElement(stream, 2, 0, state, se, 180, 181); - } - else if ( se->localPart == 10 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ - return _exiEncodeStartElement(stream, 2, 1, state, se, 182, 183); + case 177: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + if ( se->localPart == 24 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 178, 67); } break; - case 180: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ - if ( se->localPart == 10 && se->namespaceURI == 5 ) { - /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ - return _exiEncodeStartElement(stream, 1, 0, state, se, 182, 183); + case 179: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ + if ( se->localPart == 76 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 181, 182); } break; case 183: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ + if ( se->localPart == 71 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 185, 186); + } + break; + case 186: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service)] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 187, 188); + } + break; + case 187: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 189, 188); + } + break; + case 188: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID)] */ + if ( se->localPart == 30 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 196, 197); + } + break; + case 189: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 190, 188); + } + break; + case 190: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 191, 188); + } + break; + case 191: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 192, 188); + } + break; + case 192: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 193, 188); + } + break; + case 193: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 194, 188); + } + break; + case 194: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + if ( se->localPart == 28 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 195, 188); + } + break; + case 196: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if ( se->localPart == 32 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 198, 199); + } + else if ( se->localPart == 35 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 200, 180); + } + else if ( se->localPart == 33 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ + return _exiEncodeStartElement(stream, 2, 2, state, se, 201, 182); + } + break; + case 198: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if ( se->localPart == 35 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 200, 180); + } + else if ( se->localPart == 33 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 201, 182); + } + break; + case 200: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ + if ( se->localPart == 33 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 201, 182); + } + break; + case 205: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus)] */ + if ( se->localPart == 50 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PEVStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 206, 35); + } + break; + case 207: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID)] */ + if ( se->localPart == 16 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 209, 154); + } + break; + case 209: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 210, 46); + } + break; + case 210: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent)] */ + if ( se->localPart == 82 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TCurrent) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 211, 56); + } + break; + case 213: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 215, 46); + } + break; + case 215: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + if ( se->localPart == 24 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 216, 67); + } + break; + case 217: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body)] */ + if ( se->localPart == 0 && se->namespaceURI == 6 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}Body) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 219, 220); + } + break; + case 218: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation)] */ + if ( se->localPart == 2 && se->namespaceURI == 7 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}SessionInformation) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 221, 222); + } + break; + case 220: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), END_ELEMENT] */ + if ( se->localPart == 2 && se->namespaceURI == 6 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement) */ + return _exiEncodeStartElement(stream, 5, 0, state, se, 238, 3); + } + else if ( se->localPart == 0 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq) */ + return _exiEncodeStartElement(stream, 5, 1, state, se, 238, 5); + } + else if ( se->localPart == 2 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes) */ + return _exiEncodeStartElement(stream, 5, 2, state, se, 238, 6); + } + else if ( se->localPart == 4 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq) */ + return _exiEncodeStartElement(stream, 5, 3, state, se, 238, 7); + } + else if ( se->localPart == 6 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes) */ + return _exiEncodeStartElement(stream, 5, 4, state, se, 238, 8); + } + else if ( se->localPart == 10 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq) */ + return _exiEncodeStartElement(stream, 5, 5, state, se, 238, 9); + } + else if ( se->localPart == 12 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes) */ + return _exiEncodeStartElement(stream, 5, 6, state, se, 238, 10); + } + else if ( se->localPart == 28 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq) */ + return _exiEncodeStartElement(stream, 5, 7, state, se, 238, 11); + } + else if ( se->localPart == 30 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes) */ + return _exiEncodeStartElement(stream, 5, 8, state, se, 238, 12); + } + else if ( se->localPart == 33 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq) */ + return _exiEncodeStartElement(stream, 5, 9, state, se, 238, 13); + } + else if ( se->localPart == 35 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes) */ + return _exiEncodeStartElement(stream, 5, 10, state, se, 238, 14); + } + else if ( se->localPart == 37 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq) */ + return _exiEncodeStartElement(stream, 5, 11, state, se, 238, 15); + } + else if ( se->localPart == 39 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes) */ + return _exiEncodeStartElement(stream, 5, 12, state, se, 238, 16); + } + else if ( se->localPart == 52 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq) */ + return _exiEncodeStartElement(stream, 5, 13, state, se, 238, 17); + } + else if ( se->localPart == 54 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes) */ + return _exiEncodeStartElement(stream, 5, 14, state, se, 238, 18); + } + else if ( se->localPart == 56 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq) */ + return _exiEncodeStartElement(stream, 5, 15, state, se, 238, 19); + } + else if ( se->localPart == 58 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes) */ + return _exiEncodeStartElement(stream, 5, 16, state, se, 238, 20); + } + else if ( se->localPart == 60 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq) */ + return _exiEncodeStartElement(stream, 5, 17, state, se, 238, 21); + } + else if ( se->localPart == 62 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes) */ + return _exiEncodeStartElement(stream, 5, 18, state, se, 238, 22); + } + else if ( se->localPart == 67 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq) */ + return _exiEncodeStartElement(stream, 5, 19, state, se, 238, 23); + } + else if ( se->localPart == 69 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes) */ + return _exiEncodeStartElement(stream, 5, 20, state, se, 238, 24); + } + else if ( se->localPart == 72 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq) */ + return _exiEncodeStartElement(stream, 5, 21, state, se, 238, 25); + } + else if ( se->localPart == 74 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes) */ + return _exiEncodeStartElement(stream, 5, 22, state, se, 238, 26); + } + else if ( se->localPart == 78 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq) */ + return _exiEncodeStartElement(stream, 5, 23, state, se, 238, 27); + } + else if ( se->localPart == 80 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes) */ + return _exiEncodeStartElement(stream, 5, 24, state, se, 238, 28); + } + else if ( se->localPart == 85 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq) */ + return _exiEncodeStartElement(stream, 5, 25, state, se, 238, 29); + } + else if ( se->localPart == 87 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes) */ + return _exiEncodeStartElement(stream, 5, 26, state, se, 238, 30); + } + else if ( se->localPart == 90 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq) */ + return _exiEncodeStartElement(stream, 5, 27, state, se, 238, 32); + } + else if ( se->localPart == 92 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes) */ + return _exiEncodeStartElement(stream, 5, 28, state, se, 238, 33); + } + break; + case 221: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ + if ( se->localPart == 1 && se->namespaceURI == 7 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 223, 224); + } + break; + case 222: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID)] */ + if ( se->localPart == 36 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}SessionID) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 225, 226); + } + break; + case 224: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if ( se->localPart == 14 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 230, 231); + } + else if ( se->localPart == 15 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 232, 233); + } + else if ( se->localPart == 11 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ + return _exiEncodeStartElement(stream, 2, 2, state, se, 234, 235); + } + break; + case 225: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ + if ( se->localPart == 34 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 227, 226); + } + else if ( se->localPart == 25 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 228, 229); + } + break; + case 227: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ + if ( se->localPart == 25 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 228, 229); + } + break; + case 230: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if ( se->localPart == 15 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg) */ + return _exiEncodeStartElement(stream, 2, 0, state, se, 232, 233); + } + else if ( se->localPart == 11 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ + return _exiEncodeStartElement(stream, 2, 1, state, se, 234, 235); + } + break; + case 232: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ + if ( se->localPart == 11 && se->namespaceURI == 5 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList) */ + return _exiEncodeStartElement(stream, 1, 0, state, se, 234, 235); + } + break; + case 235: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Event)] */ - if ( se->localPart == 9 && se->namespaceURI == 5 ) { + if ( se->localPart == 10 && se->namespaceURI == 5 ) { /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Event) */ - return _exiEncodeStartElement(stream, 0, 0, state, se, 184, 185); + return _exiEncodeStartElement(stream, 0, 0, state, se, 236, 237); + } + break; + case 240: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus)] */ + if ( se->localPart == 25 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEStatus) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 242, 46); + } + break; + case 242: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage)] */ + if ( se->localPart == 24 && se->namespaceURI == 4 ) { + /* START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EVSEPresentVoltage) */ + return _exiEncodeStartElement(stream, 0, 0, state, se, 243, 67); } break; @@ -1092,170 +1438,190 @@ int exiEncodeStartElement(bitstream_t* stream, exi_state_t* state, int exiEncodeEndElement(bitstream_t* stream, exi_state_t* state, eqname_t* ee) { switch (state->grammarStack[state->stackIndex]) { - case 53: + case 220: + /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CableCheckRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ChargeParameterDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}CurrentDemandRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PreChargeRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TerminateChargingRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}WeldingDetectionRes), END_ELEMENT] */ + encodeNBitUnsignedInteger(stream, 5, 29); + break; + case 142: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ encodeNBitUnsignedInteger(stream, 3, 4); break; case 3: /* First(xsi:type)StartTag[END_ELEMENT] */ - case 26: - /* Element[END_ELEMENT] */ - case 29: - /* Element[END_ELEMENT] */ - case 31: - /* Element[END_ELEMENT] */ case 34: /* Element[END_ELEMENT] */ - case 44: + case 40: /* Element[END_ELEMENT] */ - case 52: + case 42: + /* Element[END_ELEMENT] */ + case 45: /* Element[END_ELEMENT] */ case 60: /* Element[END_ELEMENT] */ - case 65: + case 74: /* Element[END_ELEMENT] */ - case 67: + case 79: /* Element[END_ELEMENT] */ - case 9: - /* FirstStartTag[END_ELEMENT] */ - case 77: + case 91: /* Element[END_ELEMENT] */ - case 78: + case 101: /* Element[END_ELEMENT] */ - case 80: + case 106: /* Element[END_ELEMENT] */ - case 84: + case 116: /* Element[END_ELEMENT] */ - case 85: + case 120: /* Element[END_ELEMENT] */ - case 94: + case 125: /* Element[END_ELEMENT] */ - case 103: + case 130: /* Element[END_ELEMENT] */ - case 113: + case 132: /* Element[END_ELEMENT] */ - case 117: + case 135: /* Element[END_ELEMENT] */ - case 127: - /* Element[END_ELEMENT] */ - case 131: - /* Element[END_ELEMENT] */ - case 134: - /* Element[END_ELEMENT] */ - case 138: + case 141: /* Element[END_ELEMENT] */ case 148: /* Element[END_ELEMENT] */ - case 154: - /* Element[END_ELEMENT] */ - case 155: - /* Element[END_ELEMENT] */ - case 156: + case 149: /* Element[END_ELEMENT] */ + case 15: + /* FirstStartTag[END_ELEMENT] */ case 159: /* Element[END_ELEMENT] */ + case 160: + /* Element[END_ELEMENT] */ case 164: /* Element[END_ELEMENT] */ case 167: /* Element[END_ELEMENT] */ - case 171: + case 170: /* Element[END_ELEMENT] */ - case 176: + case 174: /* Element[END_ELEMENT] */ - case 182: + case 178: /* Element[END_ELEMENT] */ - case 184: + case 181: /* Element[END_ELEMENT] */ - case 186: + case 185: + /* Element[END_ELEMENT] */ + case 195: + /* Element[END_ELEMENT] */ + case 201: + /* Element[END_ELEMENT] */ + case 202: + /* Element[END_ELEMENT] */ + case 203: + /* Element[END_ELEMENT] */ + case 206: + /* Element[END_ELEMENT] */ + case 211: + /* Element[END_ELEMENT] */ + case 212: + /* Element[END_ELEMENT] */ + case 216: + /* Element[END_ELEMENT] */ + case 219: + /* Element[END_ELEMENT] */ + case 223: + /* Element[END_ELEMENT] */ + case 228: + /* Element[END_ELEMENT] */ + case 234: + /* Element[END_ELEMENT] */ + case 236: + /* Element[END_ELEMENT] */ + case 238: + /* Element[END_ELEMENT] */ + case 239: + /* Element[END_ELEMENT] */ + case 243: /* Element[END_ELEMENT] */ break; - case 54: + case 143: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 149: + case 196: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 172: + case 224: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ encodeNBitUnsignedInteger(stream, 2, 3); break; - case 168: - /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}SessionSetupRes), END_ELEMENT] */ - encodeNBitUnsignedInteger(stream, 5, 19); - break; - case 58: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 76: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - case 83: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ - case 101: + case 89: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ + case 100: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 99: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 98: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 97: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 95: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + case 115: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 114: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ + case 113: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ case 112: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ case 111: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ case 110: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 109: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 107: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Tariff), END_ELEMENT] */ - case 126: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 125: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 124: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 123: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 122: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 121: + case 108: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ case 119: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TariffEntry), END_ELEMENT] */ - case 130: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EPrice), END_ELEMENT] */ - case 132: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - case 136: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ - case 147: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ case 146: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + case 158: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + case 166: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}Tariff), END_ELEMENT] */ + case 179: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ + case 183: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceList), END_ELEMENT] */ + case 194: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 145: + case 193: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 144: + case 192: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 143: + case 191: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 142: + case 190: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 140: + case 189: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ - case 153: + case 187: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}Service), END_ELEMENT] */ + case 200: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 169: + case 221: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgHeader}Notification), END_ELEMENT] */ - case 175: + case 227: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - case 180: + case 232: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ encodeNBitUnsignedInteger(stream, 1, 1); break; - case 56: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ - case 75: - /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ - case 100: + case 88: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}TariffTable), END_ELEMENT] */ - case 17: + case 145: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}TMeter), END_ELEMENT] */ + case 157: + /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}MeterInfo), END_ELEMENT] */ + case 23: /* FirstStartTag[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgBody}ServiceScope), END_ELEMENT] */ - case 151: + case 198: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceScope), END_ELEMENT] */ - case 173: + case 225: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}ProtocolVersion), END_ELEMENT] */ - case 178: + case 230: /* Element[START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:eval1.0:MsgDataTypes}EventList), END_ELEMENT] */ encodeNBitUnsignedInteger(stream, 2, 2); break; @@ -1272,149 +1638,160 @@ int exiEncodeCharacters(bitstream_t* stream, exi_state_t* state, exi_value_t* val) { uint32_t bits; switch (state->grammarStack[state->stackIndex]) { - case 33: - case 81: - case 133: - case 157: - case 179: - /* CHARACTERS[ENUMERATION] */ - if (val->type == ENUMERATION) { - encodeNBitUnsignedInteger(stream, 2, val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 72: - case 150: - case 174: + case 154: + case 197: + case 226: /* CHARACTERS[BINARY_HEX] */ if (val->type == BINARY_HEX) { encodeBinary(stream, &val->binary); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; return 0; } break; - case 66: - /* CHARACTERS[INTEGER_32] */ - /* xsi:type OR xsi:nil */ - encodeNBitUnsignedInteger(stream, 1, 0); - if (val->type == INTEGER_32) { - encodeInteger32(stream, val->int32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 181: - /* CHARACTERS[STRING] */ - /* xsi:type OR xsi:nil */ - encodeNBitUnsignedInteger(stream, 1, 0); - if (val->type == STRING) { - encodeStringValue(stream, &val->string); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 27: - case 30: - case 37: case 41: - case 43: + case 59: + case 61: /* CHARACTERS[BOOLEAN] */ + /* xsi:type OR xsi:nil */ + encodeNBitUnsignedInteger(stream, 1, 0); if (val->type == BOOLEAN) { encodeBoolean(stream, val->boolean); /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 59: - case 92: - /* CHARACTERS[INTEGER_16] */ - if (val->type == INTEGER_16) { - encodeInteger32(stream, val->int32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 129: - /* CHARACTERS[UNSIGNED_INTEGER_32] */ - if (val->type == UNSIGNED_INTEGER_32) { - encodeUnsignedInteger32(stream, val->uint32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 47: - case 55: - case 79: - case 102: - case 106: - case 116: - case 135: - case 152: - case 177: - /* CHARACTERS[STRING] */ - if (val->type == STRING) { - encodeStringValue(stream, &val->string); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 62: - /* CHARACTERS[ENUMERATION] */ - if (val->type == ENUMERATION) { - encodeNBitUnsignedInteger(stream, 4, val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 51: - case 86: - case 137: - case 161: - case 185: - /* CHARACTERS[ENUMERATION] */ - if (val->type == ENUMERATION) { - encodeNBitUnsignedInteger(stream, 3, val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 45: - /* CHARACTERS[INTEGER_32] */ - if (val->type == INTEGER_32) { - encodeInteger32(stream, val->int32); - /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; return 0; } break; + case 44: case 64: - /* CHARACTERS[ENUMERATION] */ - if (val->type == ENUMERATION) { - encodeNBitUnsignedInteger(stream, 5, val->enumeration); - /* move on */ - state->grammarStack[state->stackIndex] = 31; - return 0; - } - break; - case 68: - case 70: - case 96: + case 127: + case 150: + case 152: + case 176: + case 214: + case 241: /* CHARACTERS[ENUMERATION] */ if (val->type == ENUMERATION) { encodeNBitUnsignedInteger(stream, 1, val->enumeration); /* move on */ - state->grammarStack[state->stackIndex] = 31; + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 233: + /* CHARACTERS[STRING] */ + /* xsi:type OR xsi:nil */ + encodeNBitUnsignedInteger(stream, 1, 0); + if (val->type == STRING) { + encodeStringValue(stream, &val->string); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 103: + case 169: + case 184: + case 208: + case 237: + /* CHARACTERS[ENUMERATION] */ + if (val->type == ENUMERATION) { + encodeNBitUnsignedInteger(stream, 3, val->enumeration); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 56: + /* CHARACTERS[INTEGER_32] */ + if (val->type == INTEGER_32) { + encodeInteger32(stream, val->int32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 118: + /* CHARACTERS[UNSIGNED_INTEGER_32] */ + if (val->type == UNSIGNED_INTEGER_32) { + encodeUnsignedInteger32(stream, val->uint32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 78: + /* CHARACTERS[ENUMERATION] */ + if (val->type == ENUMERATION) { + encodeNBitUnsignedInteger(stream, 5, val->enumeration); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 80: + /* CHARACTERS[INTEGER_32] */ + /* xsi:type OR xsi:nil */ + encodeNBitUnsignedInteger(stream, 1, 0); + if (val->type == INTEGER_32) { + encodeInteger32(stream, val->int32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 37: + case 39: + case 48: + case 52: + case 54: + /* CHARACTERS[BOOLEAN] */ + if (val->type == BOOLEAN) { + encodeBoolean(stream, val->boolean); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 76: + case 70: + case 147: + /* CHARACTERS[INTEGER_16] */ + if (val->type == INTEGER_16) { + encodeInteger32(stream, val->int32); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 90: + case 94: + case 105: + case 137: + case 144: + case 161: + case 182: + case 199: + case 229: + /* CHARACTERS[STRING] */ + if (val->type == STRING) { + encodeStringValue(stream, &val->string); + /* move on */ + state->grammarStack[state->stackIndex] = 42; + return 0; + } + break; + case 82: + case 134: + case 163: + case 180: + case 204: + case 231: + /* CHARACTERS[ENUMERATION] */ + if (val->type == ENUMERATION) { + encodeNBitUnsignedInteger(stream, 2, val->enumeration); + /* move on */ + state->grammarStack[state->stackIndex] = 42; return 0; } break; diff --git a/src/codec/EXIEncoder.h b/src/codec/EXIEncoder.h index 84423f3..08ea7cb 100644 --- a/src/codec/EXIEncoder.h +++ b/src/codec/EXIEncoder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXIHeaderDecoder.c b/src/codec/EXIHeaderDecoder.c index fb17f8d..d3edaa2 100644 --- a/src/codec/EXIHeaderDecoder.c +++ b/src/codec/EXIHeaderDecoder.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXIHeaderDecoder.h b/src/codec/EXIHeaderDecoder.h index f5a2daa..3533b0b 100644 --- a/src/codec/EXIHeaderDecoder.h +++ b/src/codec/EXIHeaderDecoder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXIHeaderEncoder.c b/src/codec/EXIHeaderEncoder.c index 92b30a1..02d38d8 100644 --- a/src/codec/EXIHeaderEncoder.c +++ b/src/codec/EXIHeaderEncoder.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXIHeaderEncoder.h b/src/codec/EXIHeaderEncoder.h index 8177ef9..daf7862 100644 --- a/src/codec/EXIHeaderEncoder.h +++ b/src/codec/EXIHeaderEncoder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/EXITypes.h b/src/codec/EXITypes.h index 30ad418..cfd3568 100644 --- a/src/codec/EXITypes.h +++ b/src/codec/EXITypes.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/StringTable.c b/src/codec/StringTable.c index aff058f..8bec0df 100644 --- a/src/codec/StringTable.c +++ b/src/codec/StringTable.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/StringTable.h b/src/codec/StringTable.h index 9d96317..be22fa8 100644 --- a/src/codec/StringTable.h +++ b/src/codec/StringTable.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/StringTableEntries.c b/src/codec/StringTableEntries.c index fb740a6..83158c8 100644 --- a/src/codec/StringTableEntries.c +++ b/src/codec/StringTableEntries.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -59,41 +59,49 @@ const char * localNames3[] = { }; /* localName entries for URI id = 4 */ const char * localNames4[] = { - "ContractID", "EAmount", "EVSEID", "EVSEIMax", "EVSEMaxPhases", - "EVSEMaxPower", "EVSEStatus", "EVSEVoltage", "EnergyProvider", "EoC", - "LineLockReq", "LineLockReqType", "LineLockRes", "LineLockResType", "MeterInfo", - "MeteringReceiptReq", "MeteringReceiptReqType", "MeteringReceiptRes", "MeteringReceiptResType", "MeteringStatusReq", - "MeteringStatusReqType", "MeteringStatusRes", "MeteringStatusResType", "PCurrent", "PEVID", - "PEVMaxPhases", "PEVMaxPower", "PEVMaxVoltage", "PEVMinVoltage", "PEVStatus", - "PaymentDetailsReq", "PaymentDetailsReqType", "PaymentDetailsRes", "PaymentDetailsResType", "PowerDeliveryReq", - "PowerDeliveryReqType", "PowerDeliveryRes", "PowerDeliveryResType", "PowerDiscoveryReq", "PowerDiscoveryReqType", - "PowerDiscoveryRes", "PowerDiscoveryResType", "ReqLockStatus", "ReqSwitchStatus", "ResponseCode", - "ServiceDiscoveryReq", "ServiceDiscoveryReqType", "ServiceDiscoveryRes", "ServiceDiscoveryResType", "ServiceList", - "ServicePaymentSelectionReq", "ServicePaymentSelectionReqType", "ServicePaymentSelectionRes", "ServicePaymentSelectionResType", "ServiceScope", - "ServiceType", "SessionSetupReq", "SessionSetupReqType", "SessionSetupRes", "SessionSetupResType", - "TCurrent", "Tariff", "TariffTable" + "CableCheckReq", "CableCheckReqType", "CableCheckRes", "CableCheckResType", "ChargeParameterDiscoveryReq", + "ChargeParameterDiscoveryReqType", "ChargeParameterDiscoveryRes", "ChargeParameterDiscoveryResType", "ChargingMode", "ContractID", + "CurrentDemandReq", "CurrentDemandReqType", "CurrentDemandRes", "CurrentDemandResType", "CurrentDifferential", + "EAmount", "EVSEID", "EVSEMaxCurrent", "EVSEMaxPhases", "EVSEMaxPower", + "EVSEMaxVoltage", "EVSEMinCurrent", "EVSEMinVoltage", "EVSEPresentCurrent", "EVSEPresentVoltage", + "EVSEStatus", "EnergyProvider", "EoC", "LineLockReq", "LineLockReqType", + "LineLockRes", "LineLockResType", "MeterInfo", "MeteringReceiptReq", "MeteringReceiptReqType", + "MeteringReceiptRes", "MeteringReceiptResType", "MeteringStatusReq", "MeteringStatusReqType", "MeteringStatusRes", + "MeteringStatusResType", "PCurrent", "PEVDemandCurrent", "PEVID", "PEVMaxCurrent", + "PEVMaxPhases", "PEVMaxPower", "PEVMaxVoltage", "PEVMinCurrent", "PEVMinVoltage", + "PEVStatus", "PEVTargetVoltage", "PaymentDetailsReq", "PaymentDetailsReqType", "PaymentDetailsRes", + "PaymentDetailsResType", "PowerDeliveryReq", "PowerDeliveryReqType", "PowerDeliveryRes", "PowerDeliveryResType", + "PreChargeReq", "PreChargeReqType", "PreChargeRes", "PreChargeResType", "ReqLockStatus", + "ReqSwitchStatus", "ResponseCode", "ServiceDiscoveryReq", "ServiceDiscoveryReqType", "ServiceDiscoveryRes", + "ServiceDiscoveryResType", "ServiceList", "ServicePaymentSelectionReq", "ServicePaymentSelectionReqType", "ServicePaymentSelectionRes", + "ServicePaymentSelectionResType", "ServiceScope", "ServiceType", "SessionSetupReq", "SessionSetupReqType", + "SessionSetupRes", "SessionSetupResType", "TCurrent", "Tariff", "TariffTable", + "TerminateChargingReq", "TerminateChargingReqType", "TerminateChargingRes", "TerminateChargingResType", "VoltageDifferential", + "WeldingDetectionReq", "WeldingDetectionReqType", "WeldingDetectionRes", "WeldingDetectionResType" }; /* localName entries for URI id = 5 */ const char * localNames5[] = { "ChargerStandby", "ChargingProfileEntryMaxPower", "ChargingProfileEntryStart", "ChargingProfileType", "ConnectorLocked", - "Currency", "EPrice", "EVSEStandby", "EVSEStatusType", "Event", - "EventList", "EventListType", "FatalError", "FaultCode", "FaultMsg", - "FloatingValueType", "MeterID", "MeterInfoType", "MeterReading", "MeterStatus", - "Multiplier", "NotificationType", "PEVStatusType", "PowerSwitchClosed", "ProtocolVersion", - "RCD", "Service", "ServiceDescriptionType", "ServiceID", "ServiceListType", - "ServiceName", "ServiceScope", "ServiceSessionID", "ServiceType", "SessionID", - "SessionInformationType", "ShutDownTime", "TMeter", "Tariff", "TariffDescrType", - "TariffDescription", "TariffEntries", "TariffEntriesType", "TariffEntry", "TariffEntryType", - "TariffID", "TariffPMax", "TariffStart", "TariffTableType", "Unit", - "Value", "contractIDType", "currencyType", "energyProviderType", "eventEntryType", - "evseIDType", "fatalErrorType", "faultCodeType", "lockStatusType", "maxPhasesType", - "meterIDType", "meterStatusType", "paymentOptionListType", "paymentOptionType", "pevIDType", - "protocolVersionType", "pubKeyType", "rcdType", "responseCode_LineLockType", "responseCode_MeteringReceiptType", - "responseCode_MeteringStatusType", "responseCode_PaymentDetailsType", "responseCode_PowerDeliveryType", "responseCode_PowerDiscoveryType", "responseCode_ServiceDiscoveryType", - "responseCode_ServicePaymentSelectionType", "responseCode_SessionSetupType", "serviceDetailsType", "serviceIDType", "serviceNameType", - "serviceScopeType", "serviceTypeType", "sessionIDType", "standbyType", "switchStatusType", - "tariffDescriptionType", "tariffIDType", "tariffStartType", "timeType", "unitMultiplierType", - "unitSymbolType" + "Currency", "EPrice", "EVSEMalfunction", "EVSEStandby", "EVSEStatusType", + "Event", "EventList", "EventListType", "FatalError", "FaultCode", + "FaultMsg", "FloatingValueType", "MeterID", "MeterInfoType", "MeterReading", + "MeterStatus", "Multiplier", "NotificationType", "PEVStatusType", "PowerSwitchClosed", + "ProtocolVersion", "RCD", "ReadyToCharge", "Service", "ServiceDescriptionType", + "ServiceID", "ServiceListType", "ServiceName", "ServiceScope", "ServiceSessionID", + "ServiceType", "SessionID", "SessionInformationType", "ShutDownTime", "StopCharging", + "TMeter", "Tariff", "TariffDescrType", "TariffDescription", "TariffEntries", + "TariffEntriesType", "TariffEntry", "TariffEntryType", "TariffID", "TariffPMax", + "TariffStart", "TariffTableType", "Unit", "Value", "chargingModeType", + "contractIDType", "currencyType", "energyProviderType", "eventEntryType", "evseIDType", + "fatalErrorType", "faultCodeType", "lockStatusType", "maxPhasesType", "meterIDType", + "meterStatusType", "paymentOptionListType", "paymentOptionType", "pevIDType", "protocolVersionType", + "pubKeyType", "rcdType", "responseCode_CableCheckType", "responseCode_ChargeParameterDiscoveryType", "responseCode_CurrentDemandType", + "responseCode_LineLockType", "responseCode_MeteringReceiptType", "responseCode_MeteringStatusType", "responseCode_PaymentDetailsType", "responseCode_PowerDeliveryType", + "responseCode_PreChargeType", "responseCode_ServiceDiscoveryType", "responseCode_ServicePaymentSelectionType", "responseCode_SessionSetupType", "responseCode_TerminateChargingType", + "responseCode_WeldingDetectionType", "serviceDetailsType", "serviceIDType", "serviceNameType", "serviceScopeType", + "serviceTypeType", "sessionIDType", "standbyType", "switchStatusType", "tariffDescriptionType", + "tariffIDType", "tariffStartType", "timeType", "unitMultiplierType", "unitSymbolType" + }; /* localName entries for URI id = 6 */ const char * localNames6[] = { @@ -109,8 +117,8 @@ struct exiPartition localNamePartitions[8] = { { 4, localNames1 }, { 2, localNames2 }, { 46, localNames3 }, - { 63, localNames4 }, - { 91, localNames5 }, + { 94, localNames4 }, + { 100, localNames5 }, { 6, localNames6 }, { 3, localNames7 } }; diff --git a/src/codec/StringTableEntries.h b/src/codec/StringTableEntries.h index f32411c..d3cd6c2 100644 --- a/src/codec/StringTableEntries.h +++ b/src/codec/StringTableEntries.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/UCSString.c b/src/codec/UCSString.c index 5df6029..60530a6 100644 --- a/src/codec/UCSString.c +++ b/src/codec/UCSString.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/codec/UCSString.h b/src/codec/UCSString.h index 803d5b9..9eacf50 100644 --- a/src/codec/UCSString.h +++ b/src/codec/UCSString.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/service/v2g_service.h b/src/service/v2g_service.h index 7d9073b..2c8c366 100644 --- a/src/service/v2g_service.h +++ b/src/service/v2g_service.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/service/v2g_serviceClientDataTransmitter.h b/src/service/v2g_serviceClientDataTransmitter.h index d8b627d..7e3225f 100644 --- a/src/service/v2g_serviceClientDataTransmitter.h +++ b/src/service/v2g_serviceClientDataTransmitter.h @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/service/v2g_serviceClientStubs.c b/src/service/v2g_serviceClientStubs.c index dad79f7..1a629c9 100644 --- a/src/service/v2g_serviceClientStubs.c +++ b/src/service/v2g_serviceClientStubs.c @@ -1,7 +1,7 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -20,7 +20,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -335,13 +335,13 @@ int call_paymentDetails(struct EXIService* service, struct HeaderType* header, s } /** - * \brief Calls the remote powerDiscovery method + * \brief Calls the remote chargeParameterDiscovery method * \param service struct EXIService* Service data structure (has to be initialized before) * \param header struct HeaderType* Header data structure - * \param params struct PowerDiscoveryReqType* Request data for the server (has to be set up before) - * \param result struct PowerDiscoveryResType* Contains the response data from the server + * \param params struct ChargeParameterDiscoveryReqType* Request data for the server (has to be set up before) + * \param result struct ChargeParameterDiscoveryResType* Contains the response data from the server * \return 0 = 0K; -1 = ERROR */ -int call_powerDiscovery(struct EXIService* service, struct HeaderType* header, struct PowerDiscoveryReqType* params, struct PowerDiscoveryResType* result) +int call_chargeParameterDiscovery(struct EXIService* service, struct HeaderType* header, struct ChargeParameterDiscoveryReqType* params, struct ChargeParameterDiscoveryResType* result) { uint16_t posEncode, posDecode; @@ -372,8 +372,8 @@ int call_powerDiscovery(struct EXIService* service, struct HeaderType* header, s /* assign data to service data structure */ service->exiMsg.V2G_Message.Header = header; - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq = params; - service->exiMsg.V2G_Message.Body.isused.PowerDiscoveryReq=1; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq = params; + service->exiMsg.V2G_Message.Body.isused.ChargeParameterDiscoveryReq=1; /* encode data to exi stream*/ if(serialize_message(service)) @@ -391,7 +391,7 @@ int call_powerDiscovery(struct EXIService* service, struct HeaderType* header, s - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes = result; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes = result; /* init decoder (read header, set initial state) */ exiInitDecoder(&(service->inStream), &(service->stateDecode)); @@ -699,6 +699,376 @@ int call_meteringReceipt(struct EXIService* service, struct HeaderType* header, + return 0; +} + +/** + * \brief Calls the remote cableCheck method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct CableCheckReqType* Request data for the server (has to be set up before) + * \param result struct CableCheckResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ +int call_cableCheck(struct EXIService* service, struct HeaderType* header, struct CableCheckReqType* params, struct CableCheckResType* result) +{ + uint16_t posEncode, posDecode; + + /* init uniqueID stack */ + service->idPath.pos=0; + + /* init outStream data structure */ + posEncode = service->transportHeaderOffset; + service->outStream.pos = &posEncode; + service->outStream.buffer = 0; + service->outStream.capacity = 8; + + /* init encoder (write header, set initial state) */ + exiInitEncoder(&(service->outStream), &(service->stateEncode)); + + /* init inStream data structure */ + posDecode = service->transportHeaderOffset; + service->inStream.pos = &posDecode; + service->inStream.buffer=0; + service->inStream.capacity=0; + + + + /* init EXI message */ + init_EXIDocumentType(&(service->exiMsg)); + + + + /* assign data to service data structure */ + service->exiMsg.V2G_Message.Header = header; + service->exiMsg.V2G_Message.Body.CableCheckReq = params; + service->exiMsg.V2G_Message.Body.isused.CableCheckReq=1; + + /* encode data to exi stream*/ + if(serialize_message(service)) + { + + return -1; + } + + /* send data to server and wait for the response message */ + service->errorCode=serviceDataTransmitter(service->outStream.data, (*(service->outStream.pos)-service->transportHeaderOffset), service->inStream.data); + if(service->errorCode) + { + return -1; + } + + + + service->exiMsg.V2G_Message.Body.CableCheckRes = result; + + /* init decoder (read header, set initial state) */ + exiInitDecoder(&(service->inStream), &(service->stateDecode)); + + /* deserilize the response message */ + if(deserializeMessage(service)<0) + { + + return -1; + } + + + + return 0; +} + +/** + * \brief Calls the remote preCharge method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct PreChargeReqType* Request data for the server (has to be set up before) + * \param result struct PreChargeResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ +int call_preCharge(struct EXIService* service, struct HeaderType* header, struct PreChargeReqType* params, struct PreChargeResType* result) +{ + uint16_t posEncode, posDecode; + + /* init uniqueID stack */ + service->idPath.pos=0; + + /* init outStream data structure */ + posEncode = service->transportHeaderOffset; + service->outStream.pos = &posEncode; + service->outStream.buffer = 0; + service->outStream.capacity = 8; + + /* init encoder (write header, set initial state) */ + exiInitEncoder(&(service->outStream), &(service->stateEncode)); + + /* init inStream data structure */ + posDecode = service->transportHeaderOffset; + service->inStream.pos = &posDecode; + service->inStream.buffer=0; + service->inStream.capacity=0; + + + + /* init EXI message */ + init_EXIDocumentType(&(service->exiMsg)); + + + + /* assign data to service data structure */ + service->exiMsg.V2G_Message.Header = header; + service->exiMsg.V2G_Message.Body.PreChargeReq = params; + service->exiMsg.V2G_Message.Body.isused.PreChargeReq=1; + + /* encode data to exi stream*/ + if(serialize_message(service)) + { + + return -1; + } + + /* send data to server and wait for the response message */ + service->errorCode=serviceDataTransmitter(service->outStream.data, (*(service->outStream.pos)-service->transportHeaderOffset), service->inStream.data); + if(service->errorCode) + { + return -1; + } + + + + service->exiMsg.V2G_Message.Body.PreChargeRes = result; + + /* init decoder (read header, set initial state) */ + exiInitDecoder(&(service->inStream), &(service->stateDecode)); + + /* deserilize the response message */ + if(deserializeMessage(service)<0) + { + + return -1; + } + + + + return 0; +} + +/** + * \brief Calls the remote currentDemand method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct CurrentDemandReqType* Request data for the server (has to be set up before) + * \param result struct CurrentDemandResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ +int call_currentDemand(struct EXIService* service, struct HeaderType* header, struct CurrentDemandReqType* params, struct CurrentDemandResType* result) +{ + uint16_t posEncode, posDecode; + + /* init uniqueID stack */ + service->idPath.pos=0; + + /* init outStream data structure */ + posEncode = service->transportHeaderOffset; + service->outStream.pos = &posEncode; + service->outStream.buffer = 0; + service->outStream.capacity = 8; + + /* init encoder (write header, set initial state) */ + exiInitEncoder(&(service->outStream), &(service->stateEncode)); + + /* init inStream data structure */ + posDecode = service->transportHeaderOffset; + service->inStream.pos = &posDecode; + service->inStream.buffer=0; + service->inStream.capacity=0; + + + + /* init EXI message */ + init_EXIDocumentType(&(service->exiMsg)); + + + + /* assign data to service data structure */ + service->exiMsg.V2G_Message.Header = header; + service->exiMsg.V2G_Message.Body.CurrentDemandReq = params; + service->exiMsg.V2G_Message.Body.isused.CurrentDemandReq=1; + + /* encode data to exi stream*/ + if(serialize_message(service)) + { + + return -1; + } + + /* send data to server and wait for the response message */ + service->errorCode=serviceDataTransmitter(service->outStream.data, (*(service->outStream.pos)-service->transportHeaderOffset), service->inStream.data); + if(service->errorCode) + { + return -1; + } + + + + service->exiMsg.V2G_Message.Body.CurrentDemandRes = result; + + /* init decoder (read header, set initial state) */ + exiInitDecoder(&(service->inStream), &(service->stateDecode)); + + /* deserilize the response message */ + if(deserializeMessage(service)<0) + { + + return -1; + } + + + + return 0; +} + +/** + * \brief Calls the remote weldingDetection method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct WeldingDetectionReqType* Request data for the server (has to be set up before) + * \param result struct WeldingDetectionResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ +int call_weldingDetection(struct EXIService* service, struct HeaderType* header, struct WeldingDetectionReqType* params, struct WeldingDetectionResType* result) +{ + uint16_t posEncode, posDecode; + + /* init uniqueID stack */ + service->idPath.pos=0; + + /* init outStream data structure */ + posEncode = service->transportHeaderOffset; + service->outStream.pos = &posEncode; + service->outStream.buffer = 0; + service->outStream.capacity = 8; + + /* init encoder (write header, set initial state) */ + exiInitEncoder(&(service->outStream), &(service->stateEncode)); + + /* init inStream data structure */ + posDecode = service->transportHeaderOffset; + service->inStream.pos = &posDecode; + service->inStream.buffer=0; + service->inStream.capacity=0; + + + + /* init EXI message */ + init_EXIDocumentType(&(service->exiMsg)); + + + + /* assign data to service data structure */ + service->exiMsg.V2G_Message.Header = header; + service->exiMsg.V2G_Message.Body.WeldingDetectionReq = params; + service->exiMsg.V2G_Message.Body.isused.WeldingDetectionReq=1; + + /* encode data to exi stream*/ + if(serialize_message(service)) + { + + return -1; + } + + /* send data to server and wait for the response message */ + service->errorCode=serviceDataTransmitter(service->outStream.data, (*(service->outStream.pos)-service->transportHeaderOffset), service->inStream.data); + if(service->errorCode) + { + return -1; + } + + + + service->exiMsg.V2G_Message.Body.WeldingDetectionRes = result; + + /* init decoder (read header, set initial state) */ + exiInitDecoder(&(service->inStream), &(service->stateDecode)); + + /* deserilize the response message */ + if(deserializeMessage(service)<0) + { + + return -1; + } + + + + return 0; +} + +/** + * \brief Calls the remote terminateCharging method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct TerminateChargingReqType* Request data for the server (has to be set up before) + * \param result struct TerminateChargingResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ +int call_terminateCharging(struct EXIService* service, struct HeaderType* header, struct TerminateChargingReqType* params, struct TerminateChargingResType* result) +{ + uint16_t posEncode, posDecode; + + /* init uniqueID stack */ + service->idPath.pos=0; + + /* init outStream data structure */ + posEncode = service->transportHeaderOffset; + service->outStream.pos = &posEncode; + service->outStream.buffer = 0; + service->outStream.capacity = 8; + + /* init encoder (write header, set initial state) */ + exiInitEncoder(&(service->outStream), &(service->stateEncode)); + + /* init inStream data structure */ + posDecode = service->transportHeaderOffset; + service->inStream.pos = &posDecode; + service->inStream.buffer=0; + service->inStream.capacity=0; + + + + /* init EXI message */ + init_EXIDocumentType(&(service->exiMsg)); + + + + /* assign data to service data structure */ + service->exiMsg.V2G_Message.Header = header; + service->exiMsg.V2G_Message.Body.TerminateChargingReq = params; + service->exiMsg.V2G_Message.Body.isused.TerminateChargingReq=1; + + /* encode data to exi stream*/ + if(serialize_message(service)) + { + + return -1; + } + + /* send data to server and wait for the response message */ + service->errorCode=serviceDataTransmitter(service->outStream.data, (*(service->outStream.pos)-service->transportHeaderOffset), service->inStream.data); + if(service->errorCode) + { + return -1; + } + + + + service->exiMsg.V2G_Message.Body.TerminateChargingRes = result; + + /* init decoder (read header, set initial state) */ + exiInitDecoder(&(service->inStream), &(service->stateDecode)); + + /* deserilize the response message */ + if(deserializeMessage(service)<0) + { + + return -1; + } + + + return 0; } @@ -714,445 +1084,732 @@ static int deserializeElementCharacter(struct EXIService* service) switch(service->eqn.namespaceURI) { case 4: switch(service->eqn.localPart) { - case 44: /*ResponseCode*/ - if(service->val.type == ENUMERATION) + case 66: /*ResponseCode*/ + + if(service->val.type == ENUMERATION) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 47) - { - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 52) - { - service->exiMsg.V2G_Message.Body.ServicePaymentSelectionRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 32) - { - service->exiMsg.V2G_Message.Body.PaymentDetailsRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 36) - { - service->exiMsg.V2G_Message.Body.PowerDeliveryRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->ResponseCode=service->val.enumeration; - - - } else if(service->idPath.id[2] == 17) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptRes->ResponseCode=service->val.enumeration; - - - } + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 69) + { + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 74) + { + service->exiMsg.V2G_Message.Body.ServicePaymentSelectionRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 54) + { + service->exiMsg.V2G_Message.Body.PaymentDetailsRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 35) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->ResponseCode = service->val.enumeration; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->ResponseCode = service->val.enumeration; + } + } else { return -1; /* wrong data type */ } + break; - case 2: /*EVSEID*/ - + case 16: /*EVSEID*/ + if(service->val.type == BINARY_HEX) - { - if(service->idPath.id[2]==58) { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEID.arraylen.data = service->val.binary.len; - } - else - { - memcpy(service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEID.arraylen.data = service->val.binary.len; + if( service->idPath.id[2] == 80) + { + memcpy(service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEID.arraylen.data = service->val.binary.len; + + } else if(service->idPath.id[2] == 39) + { + memcpy(service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEID.arraylen.data = service->val.binary.len; + } - } - } - else - { - return -1; /* wrong data type */ - } - - break; - case 60: /*TCurrent*/ - if(service->val.type == INTEGER_32) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->TCurrent=service->val.int32; } else { return -1; /* wrong data type */ } - break; - case 4: /*EVSEMaxPhases*/ - if(service->val.type == INTEGER_16) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEMaxPhases=service->val.int32; - } - else - { - return -1; /* wrong data type */ - } - - break; - case 8: /*EnergyProvider*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EnergyProvider.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EnergyProvider.arraylen.data = service->val.string.len; - + break; + case 82: /*TCurrent*/ + + if(service->val.type == INTEGER_32) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->TCurrent = service->val.int32; + + } else if(service->idPath.id[2] == 54) + { + service->exiMsg.V2G_Message.Body.PaymentDetailsRes->TCurrent = service->val.int32; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->TCurrent = service->val.int32; + } + } else { return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->isused.EnergyProvider=1; + + break; + case 18: /*EVSEMaxPhases*/ + + if(service->val.type == INTEGER_16) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxPhases = service->val.int32; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 26: /*EnergyProvider*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EnergyProvider.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EnergyProvider.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->isused.EnergyProvider=1; + + } + else + { + return -1; /* wrong data type */ + } + + break; } /* close switch(service->eqn.localPart) */ break; case 5: switch(service->eqn.localPart) { - case 34: /*SessionID*/ - - if(service->val.type == BINARY_HEX) - { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.arraylen.data = service->val.binary.len; - - } - else - { - return -1; /* wrong data type */ - } - - break; - case 32: /*ServiceSessionID*/ - - if(service->val.type == BINARY_HEX) - { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.arraylen.data = service->val.binary.len; - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1; - break; - case 24: /*ProtocolVersion*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.arraylen.data = service->val.string.len; + case 36: /*SessionID*/ - - } - else + if(service->val.type == BINARY_HEX) { - return -1; /* wrong data type */ - } - - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1; - break; - case 9: /*Event*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Header->Notification.EventList.Event=service->val.enumeration; - } - else - { - return -1; /* wrong data type */ - } - - break; - case 13: /*FaultCode*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Header->Notification.FaultCode=service->val.enumeration; - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1; - break; - case 14: /*FaultMsg*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->Notification.FaultMsg.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Header->Notification.FaultMsg.arraylen.data = service->val.string.len; + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.arraylen.data = service->val.binary.len; - } else { return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1; + break; - case 12: /*FatalError*/ - if(service->val.type == BOOLEAN) + case 34: /*ServiceSessionID*/ + + if(service->val.type == BINARY_HEX) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.FatalError=service->val.boolean; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.FatalError=service->val.boolean; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.FatalError=service->val.boolean; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.FatalError=service->val.boolean; - - - } + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.arraylen.data = service->val.binary.len; + service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1; + } else { return -1; /* wrong data type */ } + break; - case 7: /*EVSEStandby*/ - if(service->val.type == BOOLEAN) + case 25: /*ProtocolVersion*/ + + if(service->val.type == STRING) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.EVSEStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.EVSEStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.EVSEStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.EVSEStandby=service->val.boolean; - - - } + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1; + } else { return -1; /* wrong data type */ } + + break; + case 10: /*Event*/ + + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Header->Notification.EventList.Event = service->val.enumeration; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 14: /*FaultCode*/ + + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Header->Notification.FaultCode = service->val.enumeration; + service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 15: /*FaultMsg*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Header->Notification.FaultMsg.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Header->Notification.FaultMsg.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 13: /*FatalError*/ + + if(service->val.type == BOOLEAN) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.FatalError = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.FatalError = service->val.boolean; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 8: /*EVSEStandby*/ + + if(service->val.type == BOOLEAN) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.EVSEStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.EVSEStandby = service->val.boolean; + } + + } + else + { + return -1; /* wrong data type */ + } + + break; case 4: /*ConnectorLocked*/ - if(service->val.type == BOOLEAN) + + if(service->val.type == BOOLEAN) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.ConnectorLocked=service->val.boolean; - - - } + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.ConnectorLocked = service->val.boolean; + } + } else { return -1; /* wrong data type */ } + break; - case 23: /*PowerSwitchClosed*/ - if(service->val.type == BOOLEAN) + case 24: /*PowerSwitchClosed*/ + + if(service->val.type == BOOLEAN) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.PowerSwitchClosed=service->val.boolean; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.PowerSwitchClosed=service->val.boolean; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.PowerSwitchClosed=service->val.boolean; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.PowerSwitchClosed=service->val.boolean; - - - } + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.PowerSwitchClosed = service->val.boolean; + } + } else { return -1; /* wrong data type */ } + break; - case 25: /*RCD*/ - if(service->val.type == BOOLEAN) + case 26: /*RCD*/ + + if(service->val.type == BOOLEAN) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.RCD=service->val.boolean; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.RCD=service->val.boolean; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.RCD=service->val.boolean; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.RCD=service->val.boolean; - - - } + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.RCD = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.RCD = service->val.boolean; + } + } else { return -1; /* wrong data type */ } + break; - case 36: /*ShutDownTime*/ - if(service->val.type == INTEGER_32) + case 38: /*ShutDownTime*/ + + if(service->val.type == INTEGER_32) { - if(service->idPath.id[2] == 58) - { - service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.ShutDownTime=service->val.int32; - - - } else if(service->idPath.id[2] == 40) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEStatus.ShutDownTime=service->val.int32; - - - } else if(service->idPath.id[2] == 12) - { - service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.ShutDownTime=service->val.int32; - - - } else if(service->idPath.id[2] == 21) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.ShutDownTime=service->val.int32; - - - } + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.ShutDownTime = service->val.int32; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.ShutDownTime = service->val.int32; + } + } else { return -1; /* wrong data type */ } + break; - case 28: /*ServiceID*/ + case 0: /*ChargerStandby*/ + + if(service->val.type == BOOLEAN) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.ChargerStandby = service->val.boolean; + } + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 7: /*EVSEMalfunction*/ + + if(service->val.type == BOOLEAN) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.EVSEMalfunction = service->val.boolean; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 39: /*StopCharging*/ + + if(service->val.type == BOOLEAN) + { + if( service->idPath.id[2] == 80) + { + service->exiMsg.V2G_Message.Body.SessionSetupRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 30) + { + service->exiMsg.V2G_Message.Body.LineLockRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 58) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 39) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 2) + { + service->exiMsg.V2G_Message.Body.CableCheckRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEStatus.StopCharging = service->val.boolean; + + } else if(service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEStatus.StopCharging = service->val.boolean; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 30: /*ServiceID*/ + if(service->val.type == BINARY_HEX) - { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceID.arraylen.data = service->val.binary.len; - - } - else { - return -1; /* wrong data type */ - } - - break; - case 30: /*ServiceName*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceName.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceName.arraylen.data = service->val.string.len; - - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceName=1; - break; - case 33: /*ServiceType*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceType=service->val.enumeration; - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceType=1; + memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceID.arraylen.data = service->val.binary.len; } else @@ -1160,253 +1817,343 @@ static int deserializeElementCharacter(struct EXIService* service) return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceType=1; - break; - case 31: /*ServiceScope*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceScope.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceScope.arraylen.data = service->val.string.len; - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceScope=1; break; - case 20: /*Multiplier*/ - if(service->val.type == ENUMERATION) - { - if(service->idPath.id[3] == 7) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEVoltage.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 3) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEIMax.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 5) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 23) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Multiplier=service->val.enumeration; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.PCurrent=1; - - - } else if(service->idPath.id[1] == 0) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Multiplier=service->val.enumeration; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterReading=1; - - - } else if(service->idPath.id[7] == 46) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[7] == 6) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Multiplier=service->val.enumeration; - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].isused.EPrice=1; - - - } - } - else - { - return -1; /* wrong data type */ - } - - break; - case 49: /*Unit*/ - if(service->val.type == ENUMERATION) - { - if(service->idPath.id[3] == 7) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEVoltage.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 3) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEIMax.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 5) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 23) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Unit=service->val.enumeration; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.PCurrent=1; - - - } else if(service->idPath.id[1] == 0) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Unit=service->val.enumeration; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterReading=1; - - - } else if(service->idPath.id[7] == 46) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Unit=service->val.enumeration; - - - } else if(service->idPath.id[7] == 6) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Unit=service->val.enumeration; - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].isused.EPrice=1; - - - } - } - else - { - return -1; /* wrong data type */ - } - - break; - case 50: /*Value*/ - if(service->val.type == INTEGER_32) - { - if(service->idPath.id[3] == 7) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEVoltage.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 3) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->EVSEIMax.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 5) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 23) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Value=service->val.int32; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.PCurrent=1; - - - } else if(service->idPath.id[1] == 0) - { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Value=service->val.int32; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterReading=1; - - - } else if(service->idPath.id[7] == 46) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Value=service->val.int32; - - - } else if(service->idPath.id[7] == 6) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Value=service->val.int32; - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].isused.EPrice=1; - - - } - } - else - { - return -1; /* wrong data type */ - } - - break; - case 47: /*TariffStart*/ - if(service->val.type == UNSIGNED_INTEGER_32) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffStart=service->val.uint32; - } - else - { - return -1; /* wrong data type */ - } - - break; - case 45: /*TariffID*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffID=service->val.enumeration; - } - else - { - return -1; /* wrong data type */ - } - - break; - case 40: /*TariffDescription*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffDescription.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffDescription.arraylen.data = service->val.string.len; + case 32: /*ServiceName*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceName.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceName.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceName=1; - } else { return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].isused.TariffDescription=1; + + break; + case 35: /*ServiceType*/ + + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceType = service->val.enumeration; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceType=1; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 33: /*ServiceScope*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceScope.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceScope.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceScope=1; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 21: /*Multiplier*/ + + if(service->val.type == INTEGER_16) + { + if( service->idPath.id[3] == 20) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 22) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 17) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 21) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 41) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEPresentVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 23) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEPresentVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEPresentVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Multiplier = service->val.int32; + + } else if(service->idPath.id[7] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Multiplier = service->val.int32; + + } else if(service->idPath.id[7] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Multiplier = service->val.int32; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 52: /*Unit*/ + + if(service->val.type == ENUMERATION) + { + if( service->idPath.id[3] == 20) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 22) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 17) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 21) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 41) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEPresentVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 23) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEPresentVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEPresentVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Unit = service->val.enumeration; + + } else if(service->idPath.id[7] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Unit = service->val.enumeration; + + } else if(service->idPath.id[7] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Unit = service->val.enumeration; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 53: /*Value*/ + + if(service->val.type == INTEGER_32) + { + if( service->idPath.id[3] == 20) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 22) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 17) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMaxCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 21) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->EVSEMinCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->EVSEMaxPower.Value = service->val.int32; + + } else if(service->idPath.id[3] == 41) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->PCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 62) + { + service->exiMsg.V2G_Message.Body.PreChargeRes->EVSEPresentVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 12) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 23) + { + service->exiMsg.V2G_Message.Body.CurrentDemandRes->EVSEPresentCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 92) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionRes->EVSEPresentVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 24 && service->idPath.id[2] == 87) + { + service->exiMsg.V2G_Message.Body.TerminateChargingRes->EVSEPresentVoltage.Value = service->val.int32; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterReading.Value = service->val.int32; + + } else if(service->idPath.id[7] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffPMax.Value = service->val.int32; + + } else if(service->idPath.id[7] == 6) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].EPrice.Value = service->val.int32; + } + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 50: /*TariffStart*/ + + if(service->val.type == UNSIGNED_INTEGER_32) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].TariffStart = service->val.uint32; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 48: /*TariffID*/ + + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffID = service->val.enumeration; + + } + else + { + return -1; /* wrong data type */ + } + + + break; + case 43: /*TariffDescription*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffDescription.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffDescription.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].isused.TariffDescription=1; + + } + else + { + return -1; /* wrong data type */ + } + + break; case 5: /*Currency*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Currency.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Currency.arraylen.data = service->val.string.len; - + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Currency.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Currency.arraylen.data = service->val.string.len; + } else { return -1; /* wrong data type */ } + break; - case 16: /*MeterID*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterID.arraylen.data = service->val.string.len; + case 17: /*MeterID*/ + + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterID.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterID=1; - } else { return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterID=1; + break; - case 19: /*MeterStatus*/ - if(service->val.type == INTEGER_16) + case 20: /*MeterStatus*/ + + if(service->val.type == INTEGER_16) { - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterStatus=service->val.int32; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.MeterInfo=1; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.MeterStatus = service->val.int32; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterStatus=1; } else @@ -1414,16 +2161,14 @@ static int deserializeElementCharacter(struct EXIService* service) return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterStatus=1; + break; - case 37: /*TMeter*/ - if(service->val.type == INTEGER_32) - { + case 40: /*TMeter*/ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.TMeter=service->val.int32; - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.MeterInfo=1; - + if(service->val.type == INTEGER_32) + { + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.TMeter = service->val.int32; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.TMeter=1; } else @@ -1431,8 +2176,7 @@ static int deserializeElementCharacter(struct EXIService* service) return -1; /* wrong data type */ } - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.TMeter=1; + break; } /* close switch(service->eqn.localPart) */ break; @@ -1450,159 +2194,76 @@ static int deserializeElement(struct EXIService* service) switch(service->eqn.namespaceURI) { case 4: switch(service->eqn.localPart) { - case 49:/* ServiceList */ + case 71:/* ServiceList */ - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->isused.ServiceList=1; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->isused.ServiceList=1; + break; - case 8:/* EnergyProvider */ + case 84:/* TariffTable */ - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->isused.EnergyProvider=1; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->isused.TariffTable=1; + break; - case 62:/* TariffTable */ + case 41:/* PCurrent */ - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->isused.TariffTable=1; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.PCurrent=1; + break; - case 23:/* PCurrent */ + case 32:/* MeterInfo */ - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.PCurrent=1; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.MeterInfo=1; + break; - case 14:/* MeterInfo */ - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->isused.MeterInfo=1; - break; - case 58:/* SessionSetupRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.SessionSetupRes=1; - break; - case 47:/* ServiceDiscoveryRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.ServiceDiscoveryRes=1; - break; - case 52:/* ServicePaymentSelectionRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.ServicePaymentSelectionRes=1; - break; - case 32:/* PaymentDetailsRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.PaymentDetailsRes=1; - break; - case 40:/* PowerDiscoveryRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.PowerDiscoveryRes=1; - break; - case 12:/* LineLockRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.LineLockRes=1; - break; - case 36:/* PowerDeliveryRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.PowerDeliveryRes=1; - break; - case 21:/* MeteringStatusRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.MeteringStatusRes=1; - break; - case 17:/* MeteringReceiptRes */ - - /* is used */ - service->exiMsg.V2G_Message.Body.isused.MeteringReceiptRes=1; - break; } - break;case 5: + break; + case 5: switch(service->eqn.localPart) { - case 32:/* ServiceSessionID */ + case 11:/* EventList */ - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1; + service->exiMsg.V2G_Message.Header->Notification.isused.EventList=1; + break; - case 24:/* ProtocolVersion */ + case 28:/* Service */ - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1; - break; - case 13:/* FaultCode */ - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1; - break; - case 14:/* FaultMsg */ - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1; - break; - case 10:/* EventList */ - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.EventList=1; - break; - case 30:/* ServiceName */ - - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceName=1; - break; - case 31:/* ServiceScope */ - - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceScope=1; - break; - case 26:/* Service */ - - /* increment */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service++; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service++; + break; case 6:/* EPrice */ - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].isused.EPrice=1; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.TariffEntry[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry].isused.EPrice=1; + break; - case 43:/* TariffEntry */ + case 46:/* TariffEntry */ - /* increment */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry++; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff].TariffEntries.arraylen.TariffEntry++; + break; - case 40:/* TariffDescription */ + case 41:/* Tariff */ - /* is used */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.Tariff[service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff].isused.TariffDescription=1; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes->TariffTable.arraylen.Tariff++; + break; - case 38:/* Tariff */ + case 19:/* MeterReading */ - /* increment */ - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes->TariffTable.arraylen.Tariff++; + service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterReading=1; + break; - case 16:/* MeterID */ - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterID=1; - break; - case 18:/* MeterReading */ - - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterReading=1; - break; } - break;case 7: + break; + case 7: switch(service->eqn.localPart) { case 1:/* Notification */ - /* is used */ - service->exiMsg.V2G_Message.Header->isused.Notification=1; + service->exiMsg.V2G_Message.Header->isused.Notification=1; + break; + } break; + + } return 0; } diff --git a/src/service/v2g_serviceClientStubs.h b/src/service/v2g_serviceClientStubs.h index f20c38a..e6b102e 100644 --- a/src/service/v2g_serviceClientStubs.h +++ b/src/service/v2g_serviceClientStubs.h @@ -3,7 +3,7 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -22,7 +22,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -89,13 +89,13 @@ extern "C" { /** - * \brief Calls the remote powerDiscovery method + * \brief Calls the remote chargeParameterDiscovery method * \param service struct EXIService* Service data structure (has to be initialized before) * \param header struct HeaderType* Header data structure - * \param params struct PowerDiscoveryReqType* Request data for the server (has to be set up before) - * \param result struct PowerDiscoveryResType* Contains the response data from the server + * \param params struct ChargeParameterDiscoveryReqType* Request data for the server (has to be set up before) + * \param result struct ChargeParameterDiscoveryResType* Contains the response data from the server * \return 0 = 0K; -1 = ERROR */ - int call_powerDiscovery(struct EXIService* service, struct HeaderType* header, struct PowerDiscoveryReqType* params, struct PowerDiscoveryResType* result); + int call_chargeParameterDiscovery(struct EXIService* service, struct HeaderType* header, struct ChargeParameterDiscoveryReqType* params, struct ChargeParameterDiscoveryResType* result); @@ -147,6 +147,66 @@ extern "C" { +/** + * \brief Calls the remote cableCheck method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct CableCheckReqType* Request data for the server (has to be set up before) + * \param result struct CableCheckResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ + int call_cableCheck(struct EXIService* service, struct HeaderType* header, struct CableCheckReqType* params, struct CableCheckResType* result); + + + + +/** + * \brief Calls the remote preCharge method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct PreChargeReqType* Request data for the server (has to be set up before) + * \param result struct PreChargeResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ + int call_preCharge(struct EXIService* service, struct HeaderType* header, struct PreChargeReqType* params, struct PreChargeResType* result); + + + + +/** + * \brief Calls the remote currentDemand method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct CurrentDemandReqType* Request data for the server (has to be set up before) + * \param result struct CurrentDemandResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ + int call_currentDemand(struct EXIService* service, struct HeaderType* header, struct CurrentDemandReqType* params, struct CurrentDemandResType* result); + + + + +/** + * \brief Calls the remote weldingDetection method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct WeldingDetectionReqType* Request data for the server (has to be set up before) + * \param result struct WeldingDetectionResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ + int call_weldingDetection(struct EXIService* service, struct HeaderType* header, struct WeldingDetectionReqType* params, struct WeldingDetectionResType* result); + + + + +/** + * \brief Calls the remote terminateCharging method + * \param service struct EXIService* Service data structure (has to be initialized before) + * \param header struct HeaderType* Header data structure + * \param params struct TerminateChargingReqType* Request data for the server (has to be set up before) + * \param result struct TerminateChargingResType* Contains the response data from the server + * \return 0 = 0K; -1 = ERROR */ + int call_terminateCharging(struct EXIService* service, struct HeaderType* header, struct TerminateChargingReqType* params, struct TerminateChargingResType* result); + + + + /* Initialize the v2g client */ int init_v2gServiceClient(struct EXIService* service, bytes_t bytes, string_ucs_t string, uint8_t* inStream, size_t max_inStream_size, uint8_t* outStream, size_t max_outStream_size, uint16_t transportHeaderOffset); diff --git a/src/service/v2g_serviceDataSerialization.c b/src/service/v2g_serviceDataSerialization.c index fb25fd2..71c7786 100644 --- a/src/service/v2g_serviceDataSerialization.c +++ b/src/service/v2g_serviceDataSerialization.c @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -41,7 +41,7 @@ static int serialize_SessionInformationType(struct SessionInformationType* type, /* element ID assignment of SessionID*/ service->eqn.namespaceURI=5; - service->eqn.localPart=34; + service->eqn.localPart=36; /* encode start element SessionID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -69,7 +69,7 @@ static int serialize_SessionInformationType(struct SessionInformationType* type, /* element ID assignment of ServiceSessionID*/ service->eqn.namespaceURI=5; - service->eqn.localPart=32; + service->eqn.localPart=34; /* encode start element ServiceSessionID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -98,7 +98,7 @@ static int serialize_SessionInformationType(struct SessionInformationType* type, /* element ID assignment of ProtocolVersion*/ service->eqn.namespaceURI=5; - service->eqn.localPart=24; + service->eqn.localPart=25; /* encode start element ProtocolVersion */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -132,7 +132,7 @@ static int serialize_EventListType(struct EventListType* type, struct EXIService /* element ID assignment of Event*/ service->eqn.namespaceURI=5; - service->eqn.localPart=9; + service->eqn.localPart=10; /* encode start element Event */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -167,7 +167,7 @@ static int serialize_NotificationType(struct NotificationType* type, struct EXIS /* element ID assignment of FaultCode*/ service->eqn.namespaceURI=5; - service->eqn.localPart=13; + service->eqn.localPart=14; /* encode start element FaultCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -195,7 +195,7 @@ static int serialize_NotificationType(struct NotificationType* type, struct EXIS /* element ID assignment of FaultMsg*/ service->eqn.namespaceURI=5; - service->eqn.localPart=14; + service->eqn.localPart=15; /* encode start element FaultMsg */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -224,7 +224,7 @@ static int serialize_NotificationType(struct NotificationType* type, struct EXIS /* element ID assignment of EventList*/ service->eqn.namespaceURI=5; - service->eqn.localPart=10; + service->eqn.localPart=11; /* encode start element EventList */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -353,6 +353,30 @@ static int serialize_PEVStatusType(struct PEVStatusType* type, struct EXIService /* encode end element of ChargerStandby */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of ReadyToCharge*/ + service->eqn.namespaceURI=5; + service->eqn.localPart=27; + /* encode start element ReadyToCharge */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = BOOLEAN; + service->val.boolean=type->ReadyToCharge; + + /* encode character ReadyToCharge */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ReadyToCharge */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + return 0; @@ -367,7 +391,7 @@ static int serialize_SessionSetupReqType(struct SessionSetupReqType* type, struc /* element ID assignment of PEVID*/ service->eqn.namespaceURI=4; - service->eqn.localPart=24; + service->eqn.localPart=43; /* encode start element PEVID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -393,7 +417,7 @@ static int serialize_SessionSetupReqType(struct SessionSetupReqType* type, struc /* element ID assignment of PEVStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=29; + service->eqn.localPart=50; /* encode start element PEVStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -422,7 +446,7 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* element ID assignment of FatalError*/ service->eqn.namespaceURI=5; - service->eqn.localPart=12; + service->eqn.localPart=13; /* encode start element FatalError */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -446,7 +470,7 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* element ID assignment of EVSEStandby*/ service->eqn.namespaceURI=5; - service->eqn.localPart=7; + service->eqn.localPart=8; /* encode start element EVSEStandby */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -494,7 +518,7 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* element ID assignment of PowerSwitchClosed*/ service->eqn.namespaceURI=5; - service->eqn.localPart=23; + service->eqn.localPart=24; /* encode start element PowerSwitchClosed */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -518,7 +542,7 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* element ID assignment of RCD*/ service->eqn.namespaceURI=5; - service->eqn.localPart=25; + service->eqn.localPart=26; /* encode start element RCD */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -542,7 +566,7 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* element ID assignment of ShutDownTime*/ service->eqn.namespaceURI=5; - service->eqn.localPart=36; + service->eqn.localPart=38; /* encode start element ShutDownTime */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -563,6 +587,78 @@ static int serialize_EVSEStatusType(struct EVSEStatusType* type, struct EXIServi /* encode end element of ShutDownTime */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of ChargerStandby*/ + service->eqn.namespaceURI=5; + service->eqn.localPart=0; + /* encode start element ChargerStandby */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = BOOLEAN; + service->val.boolean=type->ChargerStandby; + + /* encode character ChargerStandby */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ChargerStandby */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEMalfunction*/ + service->eqn.namespaceURI=5; + service->eqn.localPart=7; + /* encode start element EVSEMalfunction */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = BOOLEAN; + service->val.boolean=type->EVSEMalfunction; + + /* encode character EVSEMalfunction */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of EVSEMalfunction */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of StopCharging*/ + service->eqn.namespaceURI=5; + service->eqn.localPart=39; + /* encode start element StopCharging */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = BOOLEAN; + service->val.boolean=type->StopCharging; + + /* encode character StopCharging */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of StopCharging */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + return 0; @@ -574,7 +670,7 @@ static int serialize_SessionSetupResType(struct SessionSetupResType* type, struc /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -598,7 +694,7 @@ static int serialize_SessionSetupResType(struct SessionSetupResType* type, struc /* element ID assignment of EVSEID*/ service->eqn.namespaceURI=4; - service->eqn.localPart=2; + service->eqn.localPart=16; /* encode start element EVSEID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -623,7 +719,7 @@ static int serialize_SessionSetupResType(struct SessionSetupResType* type, struc /* element ID assignment of EVSEStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=6; + service->eqn.localPart=25; /* encode start element EVSEStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -644,7 +740,7 @@ static int serialize_SessionSetupResType(struct SessionSetupResType* type, struc /* element ID assignment of TCurrent*/ service->eqn.namespaceURI=4; - service->eqn.localPart=60; + service->eqn.localPart=82; /* encode start element TCurrent */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -679,7 +775,7 @@ static int serialize_ServiceDiscoveryReqType(struct ServiceDiscoveryReqType* typ /* element ID assignment of ServiceType*/ service->eqn.namespaceURI=4; - service->eqn.localPart=55; + service->eqn.localPart=77; /* encode start element ServiceType */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -707,7 +803,7 @@ static int serialize_ServiceDiscoveryReqType(struct ServiceDiscoveryReqType* typ /* element ID assignment of ServiceScope*/ service->eqn.namespaceURI=4; - service->eqn.localPart=54; + service->eqn.localPart=76; /* encode start element ServiceScope */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -741,7 +837,7 @@ static int serialize_ServiceDescriptionType(struct ServiceDescriptionType* type, /* element ID assignment of ServiceID*/ service->eqn.namespaceURI=5; - service->eqn.localPart=28; + service->eqn.localPart=30; /* encode start element ServiceID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -769,7 +865,7 @@ static int serialize_ServiceDescriptionType(struct ServiceDescriptionType* type, /* element ID assignment of ServiceName*/ service->eqn.namespaceURI=5; - service->eqn.localPart=30; + service->eqn.localPart=32; /* encode start element ServiceName */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -798,7 +894,7 @@ static int serialize_ServiceDescriptionType(struct ServiceDescriptionType* type, /* element ID assignment of ServiceType*/ service->eqn.namespaceURI=5; - service->eqn.localPart=33; + service->eqn.localPart=35; /* encode start element ServiceType */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -826,7 +922,7 @@ static int serialize_ServiceDescriptionType(struct ServiceDescriptionType* type, /* element ID assignment of ServiceScope*/ service->eqn.namespaceURI=5; - service->eqn.localPart=31; + service->eqn.localPart=33; /* encode start element ServiceScope */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -865,7 +961,7 @@ static int serialize_ServiceListType(struct ServiceListType* type, struct EXISer /* element ID assignment of Service*/ service->eqn.namespaceURI=5; - service->eqn.localPart=26; + service->eqn.localPart=28; /* encode start element Service */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -894,7 +990,7 @@ static int serialize_ServiceDiscoveryResType(struct ServiceDiscoveryResType* typ /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -921,7 +1017,7 @@ static int serialize_ServiceDiscoveryResType(struct ServiceDiscoveryResType* typ /* element ID assignment of ServiceList*/ service->eqn.namespaceURI=4; - service->eqn.localPart=49; + service->eqn.localPart=71; /* encode start element ServiceList */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -951,7 +1047,7 @@ static int serialize_ServicePaymentSelectionReqType(struct ServicePaymentSelecti /* element ID assignment of ServiceList*/ service->eqn.namespaceURI=4; - service->eqn.localPart=49; + service->eqn.localPart=71; /* encode start element ServiceList */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -980,7 +1076,7 @@ static int serialize_ServicePaymentSelectionResType(struct ServicePaymentSelecti /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1012,7 +1108,7 @@ static int serialize_PaymentDetailsReqType(struct PaymentDetailsReqType* type, s /* element ID assignment of ContractID*/ service->eqn.namespaceURI=4; - service->eqn.localPart=0; + service->eqn.localPart=9; /* encode start element ContractID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1045,7 +1141,7 @@ static int serialize_PaymentDetailsResType(struct PaymentDetailsResType* type, s /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1066,6 +1162,30 @@ static int serialize_PaymentDetailsResType(struct PaymentDetailsResType* type, s /* encode end element of ResponseCode */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of TCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=82; + /* encode start element TCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = INTEGER_32; + service->val.int32=type->TCurrent; + + /* encode character TCurrent */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of TCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + return 0; @@ -1077,15 +1197,15 @@ static int serialize_FloatingValueType(struct FloatingValueType* type, struct EX /* element ID assignment of Multiplier*/ service->eqn.namespaceURI=5; - service->eqn.localPart=20; + service->eqn.localPart=21; /* encode start element Multiplier */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { return -1; } - service->val.type = ENUMERATION; - service->val.enumeration=type->Multiplier; + service->val.type = INTEGER_16; + service->val.int32=type->Multiplier; /* encode character Multiplier */ if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) @@ -1101,7 +1221,7 @@ static int serialize_FloatingValueType(struct FloatingValueType* type, struct EX /* element ID assignment of Unit*/ service->eqn.namespaceURI=5; - service->eqn.localPart=49; + service->eqn.localPart=52; /* encode start element Unit */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1125,7 +1245,7 @@ static int serialize_FloatingValueType(struct FloatingValueType* type, struct EX /* element ID assignment of Value*/ service->eqn.namespaceURI=5; - service->eqn.localPart=50; + service->eqn.localPart=53; /* encode start element Value */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1152,12 +1272,12 @@ static int serialize_FloatingValueType(struct FloatingValueType* type, struct EX } -static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, struct EXIService* service) +static int serialize_ChargeParameterDiscoveryReqType(struct ChargeParameterDiscoveryReqType* type, struct EXIService* service) { /* element ID assignment of PEVStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=29; + service->eqn.localPart=50; /* encode start element PEVStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1176,9 +1296,33 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + /* element ID assignment of ChargingMode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=8; + /* encode start element ChargingMode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ChargingMode; + + /* encode character ChargingMode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ChargingMode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of EoC*/ service->eqn.namespaceURI=4; - service->eqn.localPart=9; + service->eqn.localPart=27; /* encode start element EoC */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1202,7 +1346,7 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* element ID assignment of EAmount*/ service->eqn.namespaceURI=4; - service->eqn.localPart=1; + service->eqn.localPart=15; /* encode start element EAmount */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1223,7 +1367,7 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* element ID assignment of PEVMaxPower*/ service->eqn.namespaceURI=4; - service->eqn.localPart=26; + service->eqn.localPart=46; /* encode start element PEVMaxPower */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1244,7 +1388,7 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* element ID assignment of PEVMaxPhases*/ service->eqn.namespaceURI=4; - service->eqn.localPart=25; + service->eqn.localPart=45; /* encode start element PEVMaxPhases */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1268,7 +1412,7 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* element ID assignment of PEVMaxVoltage*/ service->eqn.namespaceURI=4; - service->eqn.localPart=27; + service->eqn.localPart=47; /* encode start element PEVMaxVoltage */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1289,7 +1433,7 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* element ID assignment of PEVMinVoltage*/ service->eqn.namespaceURI=4; - service->eqn.localPart=28; + service->eqn.localPart=49; /* encode start element PEVMinVoltage */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1307,6 +1451,48 @@ static int serialize_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type, s /* encode end element of PEVMinVoltage */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of PEVMaxCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=44; + /* encode start element PEVMaxCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVMaxCurrent */ + if(serialize_FloatingValueType( &(type->PEVMaxCurrent),service)) + { + return -1; + } + + + + /* encode end element of PEVMaxCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of PEVMinCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=48; + /* encode start element PEVMinCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVMinCurrent */ + if(serialize_FloatingValueType( &(type->PEVMinCurrent),service)) + { + return -1; + } + + + + /* encode end element of PEVMinCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + return 0; @@ -1318,7 +1504,7 @@ static int serialize_TariffEntryType(struct TariffEntryType* type, struct EXISer /* element ID assignment of TariffStart*/ service->eqn.namespaceURI=5; - service->eqn.localPart=47; + service->eqn.localPart=50; /* encode start element TariffStart */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1342,7 +1528,7 @@ static int serialize_TariffEntryType(struct TariffEntryType* type, struct EXISer /* element ID assignment of TariffPMax*/ service->eqn.namespaceURI=5; - service->eqn.localPart=46; + service->eqn.localPart=49; /* encode start element TariffPMax */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1401,7 +1587,7 @@ static int serialize_TariffEntriesType(struct TariffEntriesType* type, struct EX /* element ID assignment of TariffEntry*/ service->eqn.namespaceURI=5; - service->eqn.localPart=43; + service->eqn.localPart=46; /* encode start element TariffEntry */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1430,7 +1616,7 @@ static int serialize_TariffDescrType(struct TariffDescrType* type, struct EXISer /* element ID assignment of TariffID*/ service->eqn.namespaceURI=5; - service->eqn.localPart=45; + service->eqn.localPart=48; /* encode start element TariffID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1457,7 +1643,7 @@ static int serialize_TariffDescrType(struct TariffDescrType* type, struct EXISer /* element ID assignment of TariffDescription*/ service->eqn.namespaceURI=5; - service->eqn.localPart=40; + service->eqn.localPart=43; /* encode start element TariffDescription */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1483,7 +1669,7 @@ static int serialize_TariffDescrType(struct TariffDescrType* type, struct EXISer /* element ID assignment of TariffEntries*/ service->eqn.namespaceURI=5; - service->eqn.localPart=41; + service->eqn.localPart=44; /* encode start element TariffEntries */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1542,7 +1728,7 @@ static int serialize_TariffTableType(struct TariffTableType* type, struct EXISer /* element ID assignment of Tariff*/ service->eqn.namespaceURI=5; - service->eqn.localPart=38; + service->eqn.localPart=41; /* encode start element Tariff */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1566,12 +1752,12 @@ static int serialize_TariffTableType(struct TariffTableType* type, struct EXISer } -static int serialize_PowerDiscoveryResType(struct PowerDiscoveryResType* type, struct EXIService* service) +static int serialize_ChargeParameterDiscoveryResType(struct ChargeParameterDiscoveryResType* type, struct EXIService* service) { /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1595,7 +1781,7 @@ static int serialize_PowerDiscoveryResType(struct PowerDiscoveryResType* type, s /* element ID assignment of EVSEStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=6; + service->eqn.localPart=25; /* encode start element EVSEStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1614,51 +1800,93 @@ static int serialize_PowerDiscoveryResType(struct PowerDiscoveryResType* type, s exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); - /* element ID assignment of EVSEVoltage*/ + /* element ID assignment of EVSEMaxVoltage*/ service->eqn.namespaceURI=4; - service->eqn.localPart=7; - /* encode start element EVSEVoltage */ + service->eqn.localPart=20; + /* encode start element EVSEMaxVoltage */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { return -1; } - /* encode children of EVSEVoltage */ - if(serialize_FloatingValueType( &(type->EVSEVoltage),service)) + /* encode children of EVSEMaxVoltage */ + if(serialize_FloatingValueType( &(type->EVSEMaxVoltage),service)) { return -1; } - /* encode end element of EVSEVoltage */ + /* encode end element of EVSEMaxVoltage */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); - /* element ID assignment of EVSEIMax*/ + /* element ID assignment of EVSEMinVoltage*/ service->eqn.namespaceURI=4; - service->eqn.localPart=3; - /* encode start element EVSEIMax */ + service->eqn.localPart=22; + /* encode start element EVSEMinVoltage */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { return -1; } - /* encode children of EVSEIMax */ - if(serialize_FloatingValueType( &(type->EVSEIMax),service)) + /* encode children of EVSEMinVoltage */ + if(serialize_FloatingValueType( &(type->EVSEMinVoltage),service)) { return -1; } - /* encode end element of EVSEIMax */ + /* encode end element of EVSEMinVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEMaxCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=17; + /* encode start element EVSEMaxCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEMaxCurrent */ + if(serialize_FloatingValueType( &(type->EVSEMaxCurrent),service)) + { + return -1; + } + + + + /* encode end element of EVSEMaxCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEMinCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=21; + /* encode start element EVSEMinCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEMinCurrent */ + if(serialize_FloatingValueType( &(type->EVSEMinCurrent),service)) + { + return -1; + } + + + + /* encode end element of EVSEMinCurrent */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); /* element ID assignment of EVSEMaxPhases*/ service->eqn.namespaceURI=4; - service->eqn.localPart=4; + service->eqn.localPart=18; /* encode start element EVSEMaxPhases */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1685,7 +1913,7 @@ static int serialize_PowerDiscoveryResType(struct PowerDiscoveryResType* type, s /* element ID assignment of EnergyProvider*/ service->eqn.namespaceURI=4; - service->eqn.localPart=8; + service->eqn.localPart=26; /* encode start element EnergyProvider */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1714,7 +1942,7 @@ static int serialize_PowerDiscoveryResType(struct PowerDiscoveryResType* type, s /* element ID assignment of TariffTable*/ service->eqn.namespaceURI=4; - service->eqn.localPart=62; + service->eqn.localPart=84; /* encode start element TariffTable */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1744,7 +1972,7 @@ static int serialize_LineLockReqType(struct LineLockReqType* type, struct EXISer /* element ID assignment of PEVStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=29; + service->eqn.localPart=50; /* encode start element PEVStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1765,7 +1993,7 @@ static int serialize_LineLockReqType(struct LineLockReqType* type, struct EXISer /* element ID assignment of ReqLockStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=42; + service->eqn.localPart=64; /* encode start element ReqLockStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1797,7 +2025,7 @@ static int serialize_LineLockResType(struct LineLockResType* type, struct EXISer /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1821,7 +2049,7 @@ static int serialize_LineLockResType(struct LineLockResType* type, struct EXISer /* element ID assignment of EVSEStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=6; + service->eqn.localPart=25; /* encode start element EVSEStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1850,7 +2078,7 @@ static int serialize_PowerDeliveryReqType(struct PowerDeliveryReqType* type, str /* element ID assignment of PEVStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=29; + service->eqn.localPart=50; /* encode start element PEVStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1871,7 +2099,7 @@ static int serialize_PowerDeliveryReqType(struct PowerDeliveryReqType* type, str /* element ID assignment of ReqSwitchStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=43; + service->eqn.localPart=65; /* encode start element ReqSwitchStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1898,7 +2126,7 @@ static int serialize_PowerDeliveryReqType(struct PowerDeliveryReqType* type, str /* element ID assignment of Tariff*/ service->eqn.namespaceURI=4; - service->eqn.localPart=61; + service->eqn.localPart=83; /* encode start element Tariff */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1931,7 +2159,7 @@ static int serialize_PowerDeliveryResType(struct PowerDeliveryResType* type, str /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -1952,6 +2180,27 @@ static int serialize_PowerDeliveryResType(struct PowerDeliveryResType* type, str /* encode end element of ResponseCode */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + return 0; @@ -1974,7 +2223,7 @@ static int serialize_MeterInfoType(struct MeterInfoType* type, struct EXIService /* element ID assignment of MeterID*/ service->eqn.namespaceURI=5; - service->eqn.localPart=16; + service->eqn.localPart=17; /* encode start element MeterID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2003,7 +2252,7 @@ static int serialize_MeterInfoType(struct MeterInfoType* type, struct EXIService /* element ID assignment of MeterReading*/ service->eqn.namespaceURI=5; - service->eqn.localPart=18; + service->eqn.localPart=19; /* encode start element MeterReading */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2028,7 +2277,7 @@ static int serialize_MeterInfoType(struct MeterInfoType* type, struct EXIService /* element ID assignment of MeterStatus*/ service->eqn.namespaceURI=5; - service->eqn.localPart=19; + service->eqn.localPart=20; /* encode start element MeterStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2056,7 +2305,7 @@ static int serialize_MeterInfoType(struct MeterInfoType* type, struct EXIService /* element ID assignment of TMeter*/ service->eqn.namespaceURI=5; - service->eqn.localPart=37; + service->eqn.localPart=40; /* encode start element TMeter */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2089,7 +2338,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2113,7 +2362,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of EVSEID*/ service->eqn.namespaceURI=4; - service->eqn.localPart=2; + service->eqn.localPart=16; /* encode start element EVSEID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2138,7 +2387,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of EVSEStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=6; + service->eqn.localPart=25; /* encode start element EVSEStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2159,7 +2408,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of TCurrent*/ service->eqn.namespaceURI=4; - service->eqn.localPart=60; + service->eqn.localPart=82; /* encode start element TCurrent */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2183,7 +2432,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of EVSEMaxPower*/ service->eqn.namespaceURI=4; - service->eqn.localPart=5; + service->eqn.localPart=19; /* encode start element EVSEMaxPower */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2207,7 +2456,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of PCurrent*/ service->eqn.namespaceURI=4; - service->eqn.localPart=23; + service->eqn.localPart=41; /* encode start element PCurrent */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2232,7 +2481,7 @@ static int serialize_MeteringStatusResType(struct MeteringStatusResType* type, s /* element ID assignment of MeterInfo*/ service->eqn.namespaceURI=4; - service->eqn.localPart=14; + service->eqn.localPart=32; /* encode start element MeterInfo */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2265,7 +2514,7 @@ static int serialize_MeteringReceiptReqType(struct MeteringReceiptReqType* type, /* element ID assignment of PEVID*/ service->eqn.namespaceURI=4; - service->eqn.localPart=24; + service->eqn.localPart=43; /* encode start element PEVID */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2291,7 +2540,7 @@ static int serialize_MeteringReceiptReqType(struct MeteringReceiptReqType* type, /* element ID assignment of PEVStatus*/ service->eqn.namespaceURI=4; - service->eqn.localPart=29; + service->eqn.localPart=50; /* encode start element PEVStatus */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2315,7 +2564,7 @@ static int serialize_MeteringReceiptReqType(struct MeteringReceiptReqType* type, /* element ID assignment of TCurrent*/ service->eqn.namespaceURI=4; - service->eqn.localPart=60; + service->eqn.localPart=82; /* encode start element TCurrent */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2340,7 +2589,7 @@ static int serialize_MeteringReceiptReqType(struct MeteringReceiptReqType* type, /* element ID assignment of Tariff*/ service->eqn.namespaceURI=4; - service->eqn.localPart=61; + service->eqn.localPart=83; /* encode start element Tariff */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2364,7 +2613,7 @@ static int serialize_MeteringReceiptReqType(struct MeteringReceiptReqType* type, /* element ID assignment of MeterInfo*/ service->eqn.namespaceURI=4; - service->eqn.localPart=14; + service->eqn.localPart=32; /* encode start element MeterInfo */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2393,7 +2642,7 @@ static int serialize_MeteringReceiptResType(struct MeteringReceiptResType* type, /* element ID assignment of ResponseCode*/ service->eqn.namespaceURI=4; - service->eqn.localPart=44; + service->eqn.localPart=66; /* encode start element ResponseCode */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2420,6 +2669,668 @@ static int serialize_MeteringReceiptResType(struct MeteringReceiptResType* type, } +static int serialize_CableCheckReqType(struct CableCheckReqType* type, struct EXIService* service) +{ + + /* element ID assignment of PEVStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=50; + /* encode start element PEVStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVStatus */ + if(serialize_PEVStatusType( &(type->PEVStatus),service)) + { + return -1; + } + + + + /* encode end element of PEVStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_CableCheckResType(struct CableCheckResType* type, struct EXIService* service) +{ + + /* element ID assignment of ResponseCode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=66; + /* encode start element ResponseCode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ResponseCode; + + /* encode character ResponseCode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ResponseCode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_PreChargeReqType(struct PreChargeReqType* type, struct EXIService* service) +{ + + /* element ID assignment of PEVStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=50; + /* encode start element PEVStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVStatus */ + if(serialize_PEVStatusType( &(type->PEVStatus),service)) + { + return -1; + } + + + + /* encode end element of PEVStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of PEVTargetVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=51; + /* encode start element PEVTargetVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVTargetVoltage */ + if(serialize_FloatingValueType( &(type->PEVTargetVoltage),service)) + { + return -1; + } + + + + /* encode end element of PEVTargetVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of PEVDemandCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=42; + /* encode start element PEVDemandCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVDemandCurrent */ + if(serialize_FloatingValueType( &(type->PEVDemandCurrent),service)) + { + return -1; + } + + + + /* encode end element of PEVDemandCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of VoltageDifferential*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=89; + /* encode start element VoltageDifferential */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of VoltageDifferential */ + if(serialize_FloatingValueType( &(type->VoltageDifferential),service)) + { + return -1; + } + + + + /* encode end element of VoltageDifferential */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_PreChargeResType(struct PreChargeResType* type, struct EXIService* service) +{ + + /* element ID assignment of ResponseCode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=66; + /* encode start element ResponseCode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ResponseCode; + + /* encode character ResponseCode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ResponseCode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEPresentVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=24; + /* encode start element EVSEPresentVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEPresentVoltage */ + if(serialize_FloatingValueType( &(type->EVSEPresentVoltage),service)) + { + return -1; + } + + + + /* encode end element of EVSEPresentVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_CurrentDemandReqType(struct CurrentDemandReqType* type, struct EXIService* service) +{ + + /* element ID assignment of PEVStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=50; + /* encode start element PEVStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVStatus */ + if(serialize_PEVStatusType( &(type->PEVStatus),service)) + { + return -1; + } + + + + /* encode end element of PEVStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of PEVTargetVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=51; + /* encode start element PEVTargetVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVTargetVoltage */ + if(serialize_FloatingValueType( &(type->PEVTargetVoltage),service)) + { + return -1; + } + + + + /* encode end element of PEVTargetVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of PEVDemandCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=42; + /* encode start element PEVDemandCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVDemandCurrent */ + if(serialize_FloatingValueType( &(type->PEVDemandCurrent),service)) + { + return -1; + } + + + + /* encode end element of PEVDemandCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of CurrentDifferential*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=14; + /* encode start element CurrentDifferential */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of CurrentDifferential */ + if(serialize_FloatingValueType( &(type->CurrentDifferential),service)) + { + return -1; + } + + + + /* encode end element of CurrentDifferential */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of VoltageDifferential*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=89; + /* encode start element VoltageDifferential */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of VoltageDifferential */ + if(serialize_FloatingValueType( &(type->VoltageDifferential),service)) + { + return -1; + } + + + + /* encode end element of VoltageDifferential */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_CurrentDemandResType(struct CurrentDemandResType* type, struct EXIService* service) +{ + + /* element ID assignment of ResponseCode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=66; + /* encode start element ResponseCode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ResponseCode; + + /* encode character ResponseCode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ResponseCode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEPresentVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=24; + /* encode start element EVSEPresentVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEPresentVoltage */ + if(serialize_FloatingValueType( &(type->EVSEPresentVoltage),service)) + { + return -1; + } + + + + /* encode end element of EVSEPresentVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEPresentCurrent*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=23; + /* encode start element EVSEPresentCurrent */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEPresentCurrent */ + if(serialize_FloatingValueType( &(type->EVSEPresentCurrent),service)) + { + return -1; + } + + + + /* encode end element of EVSEPresentCurrent */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_WeldingDetectionReqType(struct WeldingDetectionReqType* type, struct EXIService* service) +{ + + /* element ID assignment of PEVStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=50; + /* encode start element PEVStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVStatus */ + if(serialize_PEVStatusType( &(type->PEVStatus),service)) + { + return -1; + } + + + + /* encode end element of PEVStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_WeldingDetectionResType(struct WeldingDetectionResType* type, struct EXIService* service) +{ + + /* element ID assignment of ResponseCode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=66; + /* encode start element ResponseCode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ResponseCode; + + /* encode character ResponseCode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ResponseCode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEPresentVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=24; + /* encode start element EVSEPresentVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEPresentVoltage */ + if(serialize_FloatingValueType( &(type->EVSEPresentVoltage),service)) + { + return -1; + } + + + + /* encode end element of EVSEPresentVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_TerminateChargingReqType(struct TerminateChargingReqType* type, struct EXIService* service) +{ + + /* element ID assignment of PEVStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=50; + /* encode start element PEVStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PEVStatus */ + if(serialize_PEVStatusType( &(type->PEVStatus),service)) + { + return -1; + } + + + + /* encode end element of PEVStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + +static int serialize_TerminateChargingResType(struct TerminateChargingResType* type, struct EXIService* service) +{ + + /* element ID assignment of ResponseCode*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=66; + /* encode start element ResponseCode */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + service->val.type = ENUMERATION; + service->val.enumeration=type->ResponseCode; + + /* encode character ResponseCode */ + if (exiEncodeCharacters(&(service->outStream), &(service->stateEncode), &(service->val))) + { + + return -1; + } + + + /* encode end element of ResponseCode */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEStatus*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=25; + /* encode start element EVSEStatus */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEStatus */ + if(serialize_EVSEStatusType( &(type->EVSEStatus),service)) + { + return -1; + } + + + + /* encode end element of EVSEStatus */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + /* element ID assignment of EVSEPresentVoltage*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=24; + /* encode start element EVSEPresentVoltage */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of EVSEPresentVoltage */ + if(serialize_FloatingValueType( &(type->EVSEPresentVoltage),service)) + { + return -1; + } + + + + /* encode end element of EVSEPresentVoltage */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + + + return 0; +} + + static int serialize_BodyType(struct BodyType* type, struct EXIService* service) { @@ -2428,7 +3339,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of SessionSetupReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=56; + service->eqn.localPart=78; /* encode start element SessionSetupReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2453,7 +3364,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of SessionSetupRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=58; + service->eqn.localPart=80; /* encode start element SessionSetupRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2478,7 +3389,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of ServiceDiscoveryReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=45; + service->eqn.localPart=67; /* encode start element ServiceDiscoveryReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2503,7 +3414,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of ServiceDiscoveryRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=47; + service->eqn.localPart=69; /* encode start element ServiceDiscoveryRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2528,7 +3439,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of ServicePaymentSelectionReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=50; + service->eqn.localPart=72; /* encode start element ServicePaymentSelectionReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2553,7 +3464,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of ServicePaymentSelectionRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=52; + service->eqn.localPart=74; /* encode start element ServicePaymentSelectionRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2578,7 +3489,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of PaymentDetailsReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=30; + service->eqn.localPart=52; /* encode start element PaymentDetailsReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2603,7 +3514,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of PaymentDetailsRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=32; + service->eqn.localPart=54; /* encode start element PaymentDetailsRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2623,52 +3534,52 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) } - if(type->isused.PowerDiscoveryReq) + if(type->isused.ChargeParameterDiscoveryReq) { - /* element ID assignment of PowerDiscoveryReq*/ + /* element ID assignment of ChargeParameterDiscoveryReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=38; - /* encode start element PowerDiscoveryReq */ + service->eqn.localPart=4; + /* encode start element ChargeParameterDiscoveryReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { return -1; } - /* encode children of PowerDiscoveryReq */ - if(serialize_PowerDiscoveryReqType( (type->PowerDiscoveryReq),service)) + /* encode children of ChargeParameterDiscoveryReq */ + if(serialize_ChargeParameterDiscoveryReqType( (type->ChargeParameterDiscoveryReq),service)) { return -1; } - /* encode end element of PowerDiscoveryReq */ + /* encode end element of ChargeParameterDiscoveryReq */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); } - if(type->isused.PowerDiscoveryRes) + if(type->isused.ChargeParameterDiscoveryRes) { - /* element ID assignment of PowerDiscoveryRes*/ + /* element ID assignment of ChargeParameterDiscoveryRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=40; - /* encode start element PowerDiscoveryRes */ + service->eqn.localPart=6; + /* encode start element ChargeParameterDiscoveryRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { return -1; } - /* encode children of PowerDiscoveryRes */ - if(serialize_PowerDiscoveryResType( (type->PowerDiscoveryRes),service)) + /* encode children of ChargeParameterDiscoveryRes */ + if(serialize_ChargeParameterDiscoveryResType( (type->ChargeParameterDiscoveryRes),service)) { return -1; } - /* encode end element of PowerDiscoveryRes */ + /* encode end element of ChargeParameterDiscoveryRes */ exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); } @@ -2678,7 +3589,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of LineLockReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=10; + service->eqn.localPart=28; /* encode start element LineLockReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2703,7 +3614,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of LineLockRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=12; + service->eqn.localPart=30; /* encode start element LineLockRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2728,7 +3639,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of PowerDeliveryReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=34; + service->eqn.localPart=56; /* encode start element PowerDeliveryReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2753,7 +3664,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of PowerDeliveryRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=36; + service->eqn.localPart=58; /* encode start element PowerDeliveryRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2778,7 +3689,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of MeteringStatusReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=19; + service->eqn.localPart=37; /* encode start element MeteringStatusReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2803,7 +3714,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of MeteringStatusRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=21; + service->eqn.localPart=39; /* encode start element MeteringStatusRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2828,7 +3739,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of MeteringReceiptReq*/ service->eqn.namespaceURI=4; - service->eqn.localPart=15; + service->eqn.localPart=33; /* encode start element MeteringReceiptReq */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2853,7 +3764,7 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) /* element ID assignment of MeteringReceiptRes*/ service->eqn.namespaceURI=4; - service->eqn.localPart=17; + service->eqn.localPart=35; /* encode start element MeteringReceiptRes */ if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) { @@ -2873,6 +3784,256 @@ static int serialize_BodyType(struct BodyType* type, struct EXIService* service) } + if(type->isused.CableCheckReq) + { + + /* element ID assignment of CableCheckReq*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=0; + /* encode start element CableCheckReq */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of CableCheckReq */ + if(serialize_CableCheckReqType( (type->CableCheckReq),service)) + { + return -1; + } + + + + /* encode end element of CableCheckReq */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.CableCheckRes) + { + + /* element ID assignment of CableCheckRes*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=2; + /* encode start element CableCheckRes */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of CableCheckRes */ + if(serialize_CableCheckResType( (type->CableCheckRes),service)) + { + return -1; + } + + + + /* encode end element of CableCheckRes */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.PreChargeReq) + { + + /* element ID assignment of PreChargeReq*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=60; + /* encode start element PreChargeReq */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PreChargeReq */ + if(serialize_PreChargeReqType( (type->PreChargeReq),service)) + { + return -1; + } + + + + /* encode end element of PreChargeReq */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.PreChargeRes) + { + + /* element ID assignment of PreChargeRes*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=62; + /* encode start element PreChargeRes */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of PreChargeRes */ + if(serialize_PreChargeResType( (type->PreChargeRes),service)) + { + return -1; + } + + + + /* encode end element of PreChargeRes */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.CurrentDemandReq) + { + + /* element ID assignment of CurrentDemandReq*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=10; + /* encode start element CurrentDemandReq */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of CurrentDemandReq */ + if(serialize_CurrentDemandReqType( (type->CurrentDemandReq),service)) + { + return -1; + } + + + + /* encode end element of CurrentDemandReq */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.CurrentDemandRes) + { + + /* element ID assignment of CurrentDemandRes*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=12; + /* encode start element CurrentDemandRes */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of CurrentDemandRes */ + if(serialize_CurrentDemandResType( (type->CurrentDemandRes),service)) + { + return -1; + } + + + + /* encode end element of CurrentDemandRes */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.WeldingDetectionReq) + { + + /* element ID assignment of WeldingDetectionReq*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=90; + /* encode start element WeldingDetectionReq */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of WeldingDetectionReq */ + if(serialize_WeldingDetectionReqType( (type->WeldingDetectionReq),service)) + { + return -1; + } + + + + /* encode end element of WeldingDetectionReq */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.WeldingDetectionRes) + { + + /* element ID assignment of WeldingDetectionRes*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=92; + /* encode start element WeldingDetectionRes */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of WeldingDetectionRes */ + if(serialize_WeldingDetectionResType( (type->WeldingDetectionRes),service)) + { + return -1; + } + + + + /* encode end element of WeldingDetectionRes */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.TerminateChargingReq) + { + + /* element ID assignment of TerminateChargingReq*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=85; + /* encode start element TerminateChargingReq */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of TerminateChargingReq */ + if(serialize_TerminateChargingReqType( (type->TerminateChargingReq),service)) + { + return -1; + } + + + + /* encode end element of TerminateChargingReq */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + + if(type->isused.TerminateChargingRes) + { + + /* element ID assignment of TerminateChargingRes*/ + service->eqn.namespaceURI=4; + service->eqn.localPart=87; + /* encode start element TerminateChargingRes */ + if (exiEncodeStartElement(&(service->outStream), &(service->stateEncode), &(service->eqn))) + { + return -1; + } + + /* encode children of TerminateChargingRes */ + if(serialize_TerminateChargingResType( (type->TerminateChargingRes),service)) + { + return -1; + } + + + + /* encode end element of TerminateChargingRes */ + exiEncodeEndElement(&(service->outStream), &(service->stateEncode), &(service->eqn)); + + } + return 0; } diff --git a/src/service/v2g_serviceDataTypes.c b/src/service/v2g_serviceDataTypes.c index 11bb2ac..657fdc9 100644 --- a/src/service/v2g_serviceDataTypes.c +++ b/src/service/v2g_serviceDataTypes.c @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -29,19 +29,13 @@ #include "v2g_serviceDataTypes.h" -static void init_SessionInformationType_SessionID(struct SessionInformationType_SessionID* type) +static void init_sessionIDType(struct sessionIDType* type) { type->arraylen.data=0; } -static void init_SessionInformationType_ServiceSessionID(struct SessionInformationType_ServiceSessionID* type) -{ - type->arraylen.data=0; - -} - -static void init_SessionInformationType_ProtocolVersion(struct SessionInformationType_ProtocolVersion* type) +static void init_protocolVersionType(struct protocolVersionType* type) { type->arraylen.data=0; @@ -49,15 +43,15 @@ static void init_SessionInformationType_ProtocolVersion(struct SessionInformati static void init_SessionInformationType(struct SessionInformationType* type) { - init_SessionInformationType_SessionID(&(type->SessionID)); - init_SessionInformationType_ServiceSessionID(&(type->ServiceSessionID)); + init_sessionIDType(&(type->SessionID)); + init_sessionIDType(&(type->ServiceSessionID)); type->isused.ServiceSessionID=0; - init_SessionInformationType_ProtocolVersion(&(type->ProtocolVersion)); + init_protocolVersionType(&(type->ProtocolVersion)); type->isused.ProtocolVersion=0; } -static void init_NotificationType_FaultMsg(struct NotificationType_FaultMsg* type) +static void init_service_string(struct service_string* type) { type->arraylen.data=0; @@ -66,7 +60,7 @@ static void init_NotificationType_FaultMsg(struct NotificationType_FaultMsg* ty static void init_NotificationType(struct NotificationType* type) { type->isused.FaultCode=0; - init_NotificationType_FaultMsg(&(type->FaultMsg)); + init_service_string(&(type->FaultMsg)); type->isused.FaultMsg=0; type->isused.EventList=0; @@ -80,7 +74,7 @@ static void init_HeaderType(struct HeaderType* type) } -static void init_SessionSetupReqType_PEVID(struct SessionSetupReqType_PEVID* type) +static void init_pevIDType(struct pevIDType* type) { type->arraylen.data=0; @@ -88,12 +82,12 @@ static void init_SessionSetupReqType_PEVID(struct SessionSetupReqType_PEVID* ty static void init_SessionSetupReqType(struct SessionSetupReqType* type) { - init_SessionSetupReqType_PEVID(&(type->PEVID)); + init_pevIDType(&(type->PEVID)); type->isused.PEVID=0; } -static void init_SessionSetupResType_EVSEID(struct SessionSetupResType_EVSEID* type) +static void init_evseIDType(struct evseIDType* type) { type->arraylen.data=0; @@ -101,11 +95,11 @@ static void init_SessionSetupResType_EVSEID(struct SessionSetupResType_EVSEID* static void init_SessionSetupResType(struct SessionSetupResType* type) { - init_SessionSetupResType_EVSEID(&(type->EVSEID)); + init_evseIDType(&(type->EVSEID)); } -static void init_ServiceDiscoveryReqType_ServiceScope(struct ServiceDiscoveryReqType_ServiceScope* type) +static void init_serviceScopeType(struct serviceScopeType* type) { type->arraylen.data=0; @@ -114,24 +108,18 @@ static void init_ServiceDiscoveryReqType_ServiceScope(struct ServiceDiscoveryRe static void init_ServiceDiscoveryReqType(struct ServiceDiscoveryReqType* type) { type->isused.ServiceType=0; - init_ServiceDiscoveryReqType_ServiceScope(&(type->ServiceScope)); + init_serviceScopeType(&(type->ServiceScope)); type->isused.ServiceScope=0; } -static void init_ServiceDescriptionType_ServiceID(struct ServiceDescriptionType_ServiceID* type) +static void init_serviceIDType(struct serviceIDType* type) { type->arraylen.data=0; } -static void init_ServiceDescriptionType_ServiceName(struct ServiceDescriptionType_ServiceName* type) -{ - type->arraylen.data=0; - -} - -static void init_ServiceDescriptionType_ServiceScope(struct ServiceDescriptionType_ServiceScope* type) +static void init_serviceNameType(struct serviceNameType* type) { type->arraylen.data=0; @@ -139,11 +127,11 @@ static void init_ServiceDescriptionType_ServiceScope(struct ServiceDescriptionT static void init_ServiceDescriptionType(struct ServiceDescriptionType* type) { - init_ServiceDescriptionType_ServiceID(&(type->ServiceID)); - init_ServiceDescriptionType_ServiceName(&(type->ServiceName)); + init_serviceIDType(&(type->ServiceID)); + init_serviceNameType(&(type->ServiceName)); type->isused.ServiceName=0; type->isused.ServiceType=0; - init_ServiceDescriptionType_ServiceScope(&(type->ServiceScope)); + init_serviceScopeType(&(type->ServiceScope)); type->isused.ServiceScope=0; } @@ -174,7 +162,7 @@ static void init_ServicePaymentSelectionReqType(struct ServicePaymentSelectionR } -static void init_PaymentDetailsReqType_ContractID(struct PaymentDetailsReqType_ContractID* type) +static void init_contractIDType(struct contractIDType* type) { type->arraylen.data=0; @@ -182,28 +170,28 @@ static void init_PaymentDetailsReqType_ContractID(struct PaymentDetailsReqType_ static void init_PaymentDetailsReqType(struct PaymentDetailsReqType* type) { - init_PaymentDetailsReqType_ContractID(&(type->ContractID)); + init_contractIDType(&(type->ContractID)); } -static void init_PowerDiscoveryReqType(struct PowerDiscoveryReqType* type) -{ +static void init_ChargeParameterDiscoveryReqType(struct ChargeParameterDiscoveryReqType* type) +{ } -static void init_PowerDiscoveryResType_EnergyProvider(struct PowerDiscoveryResType_EnergyProvider* type) +static void init_energyProviderType(struct energyProviderType* type) { type->arraylen.data=0; } -static void init_TariffTableType_Currency(struct TariffTableType_Currency* type) +static void init_currencyType(struct currencyType* type) { type->arraylen.data=0; } -static void init_TariffDescrType_TariffDescription(struct TariffDescrType_TariffDescription* type) +static void init_tariffDescriptionType(struct tariffDescriptionType* type) { type->arraylen.data=0; @@ -230,7 +218,7 @@ static void init_TariffEntriesType(struct TariffEntriesType* type) static void init_TariffDescrType(struct TariffDescrType* type) { - init_TariffDescrType_TariffDescription(&(type->TariffDescription)); + init_tariffDescriptionType(&(type->TariffDescription)); type->isused.TariffDescription=0; init_TariffEntriesType(&(type->TariffEntries)); @@ -240,7 +228,7 @@ static void init_TariffTableType(struct TariffTableType* type) { int i_loop; - init_TariffTableType_Currency(&(type->Currency)); + init_currencyType(&(type->Currency)); for(i_loop=0; i_loop<6;i_loop++) { init_TariffDescrType(&(type->Tariff[i_loop])); @@ -250,9 +238,9 @@ static void init_TariffTableType(struct TariffTableType* type) } -static void init_PowerDiscoveryResType(struct PowerDiscoveryResType* type) -{ - init_PowerDiscoveryResType_EnergyProvider(&(type->EnergyProvider)); +static void init_ChargeParameterDiscoveryResType(struct ChargeParameterDiscoveryResType* type) +{ + init_energyProviderType(&(type->EnergyProvider)); type->isused.EnergyProvider=0; init_TariffTableType(&(type->TariffTable)); type->isused.TariffTable=0; @@ -275,13 +263,12 @@ static void init_PowerDeliveryReqType(struct PowerDeliveryReqType* type) } -static void init_MeteringStatusResType_EVSEID(struct MeteringStatusResType_EVSEID* type) -{ - type->arraylen.data=0; +static void init_PowerDeliveryResType(struct PowerDeliveryResType* type) +{ } -static void init_MeterInfoType_MeterID(struct MeterInfoType_MeterID* type) +static void init_meterIDType(struct meterIDType* type) { type->arraylen.data=0; @@ -289,7 +276,7 @@ static void init_MeterInfoType_MeterID(struct MeterInfoType_MeterID* type) static void init_MeterInfoType(struct MeterInfoType* type) { - init_MeterInfoType_MeterID(&(type->MeterID)); + init_meterIDType(&(type->MeterID)); type->isused.MeterID=0; type->isused.MeterReading=0; type->isused.MeterStatus=0; @@ -299,28 +286,72 @@ static void init_MeterInfoType(struct MeterInfoType* type) static void init_MeteringStatusResType(struct MeteringStatusResType* type) { - init_MeteringStatusResType_EVSEID(&(type->EVSEID)); + init_evseIDType(&(type->EVSEID)); type->isused.PCurrent=0; init_MeterInfoType(&(type->MeterInfo)); type->isused.MeterInfo=0; } -static void init_MeteringReceiptReqType_PEVID(struct MeteringReceiptReqType_PEVID* type) -{ - type->arraylen.data=0; - -} - static void init_MeteringReceiptReqType(struct MeteringReceiptReqType* type) { - init_MeteringReceiptReqType_PEVID(&(type->PEVID)); + init_pevIDType(&(type->PEVID)); type->isused.PEVID=0; type->isused.TCurrent=0; init_MeterInfoType(&(type->MeterInfo)); } +static void init_CableCheckReqType(struct CableCheckReqType* type) +{ + +} + +static void init_CableCheckResType(struct CableCheckResType* type) +{ + +} + +static void init_PreChargeReqType(struct PreChargeReqType* type) +{ + +} + +static void init_PreChargeResType(struct PreChargeResType* type) +{ + +} + +static void init_CurrentDemandReqType(struct CurrentDemandReqType* type) +{ + +} + +static void init_CurrentDemandResType(struct CurrentDemandResType* type) +{ + +} + +static void init_WeldingDetectionReqType(struct WeldingDetectionReqType* type) +{ + +} + +static void init_WeldingDetectionResType(struct WeldingDetectionResType* type) +{ + +} + +static void init_TerminateChargingReqType(struct TerminateChargingReqType* type) +{ + +} + +static void init_TerminateChargingResType(struct TerminateChargingResType* type) +{ + +} + static void init_BodyType(struct BodyType* type) { type->isused.SessionSetupReq=0; @@ -331,8 +362,8 @@ static void init_BodyType(struct BodyType* type) type->isused.ServicePaymentSelectionRes=0; type->isused.PaymentDetailsReq=0; type->isused.PaymentDetailsRes=0; - type->isused.PowerDiscoveryReq=0; - type->isused.PowerDiscoveryRes=0; + type->isused.ChargeParameterDiscoveryReq=0; + type->isused.ChargeParameterDiscoveryRes=0; type->isused.LineLockReq=0; type->isused.LineLockRes=0; type->isused.PowerDeliveryReq=0; @@ -340,7 +371,17 @@ static void init_BodyType(struct BodyType* type) type->isused.MeteringStatusReq=0; type->isused.MeteringStatusRes=0; type->isused.MeteringReceiptReq=0; - type->isused.MeteringReceiptRes=0; + type->isused.MeteringReceiptRes=0; + type->isused.CableCheckReq=0; + type->isused.CableCheckRes=0; + type->isused.PreChargeReq=0; + type->isused.PreChargeRes=0; + type->isused.CurrentDemandReq=0; + type->isused.CurrentDemandRes=0; + type->isused.WeldingDetectionReq=0; + type->isused.WeldingDetectionRes=0; + type->isused.TerminateChargingReq=0; + type->isused.TerminateChargingRes=0; } diff --git a/src/service/v2g_serviceDataTypes.h b/src/service/v2g_serviceDataTypes.h index 73fb9fa..d6e4c4d 100644 --- a/src/service/v2g_serviceDataTypes.h +++ b/src/service/v2g_serviceDataTypes.h @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -105,19 +105,10 @@ enum responseCode_PaymentDetailsType }; -enum unitMultiplierType +enum chargingModeType { - d_unitMultiplierType, - c_unitMultiplierType, - m_unitMultiplierType, - micro_unitMultiplierType, - n_unitMultiplierType, - p_unitMultiplierType, - k_unitMultiplierType, - M_unitMultiplierType, - G_unitMultiplierType, - T_unitMultiplierType, - none_unitMultiplierType + AC_charging_chargingModeType, + DC_charging_chargingModeType }; @@ -126,16 +117,9 @@ enum unitSymbolType A_unitSymbolType, deg_unitSymbolType, F_unitSymbolType, - g_unitSymbolType, h_unitSymbolType, - J_unitSymbolType, - J_s_unitSymbolType, - kg_J_unitSymbolType, min_unitSymbolType, - N_unitSymbolType, - ohm_unitSymbolType, s_unitSymbolType, - S_unitSymbolType, s_1_unitSymbolType, V_unitSymbolType, V_VAr_unitSymbolType, @@ -147,14 +131,15 @@ enum unitSymbolType W_Hz_unitSymbolType, W_s_unitSymbolType, Wh_unitSymbolType, - Ah_unitSymbolType - + Ah_unitSymbolType, + J_unitSymbolType }; -enum responseCode_PowerDiscoveryType +enum responseCode_ChargeParameterDiscoveryType { - OK_PowerDiscovery_responseCode_PowerDiscoveryType, - FAILED_UnknownError_InPowerDiscovery_responseCode_PowerDiscoveryType + OK_responseCode_ChargeParameterDiscoveryType, + FAILED_BatteryNotCompatible_responseCode_ChargeParameterDiscoveryType, + FAILED_UnknownError_responseCode_ChargeParameterDiscoveryType }; @@ -201,34 +186,55 @@ enum responseCode_MeteringReceiptType }; +enum responseCode_CableCheckType +{ + OK_responseCode_CableCheckType, + FAILED_UnknownError_responseCode_CableCheckType + +}; + +enum responseCode_PreChargeType +{ + OK_responseCode_PreChargeType, + FAILED_UnknownError_responseCode_PreChargeType + +}; + +enum responseCode_CurrentDemandType +{ + OK_responseCode_CurrentDemandType, + FAILED_UnknownError_responseCode_CurrentDemandType + +}; + +enum responseCode_WeldingDetectionType +{ + OK_responseCode_WeldingDetectionType, + FAILED_UnknownError_responseCode_WeldingDetectionType + +}; + +enum responseCode_TerminateChargingType +{ + OK_responseCode_TerminateChargingType, + FAILED_UnknownError_responseCode_TerminateChargingType + +}; -struct arraylen_SessionInformationType_SessionID + +struct arraylen_sessionIDType { size_t data; }; -struct SessionInformationType_SessionID +struct sessionIDType { uint8_t data[8]; - struct arraylen_SessionInformationType_SessionID arraylen; - -}; - -struct arraylen_SessionInformationType_ServiceSessionID -{ - size_t data; - - -}; - -struct SessionInformationType_ServiceSessionID -{ - uint8_t data[8]; - struct arraylen_SessionInformationType_ServiceSessionID arraylen; + struct arraylen_sessionIDType arraylen; }; @@ -240,25 +246,25 @@ struct selection_SessionInformationType }; -struct arraylen_SessionInformationType_ProtocolVersion +struct arraylen_protocolVersionType { size_t data; }; -struct SessionInformationType_ProtocolVersion +struct protocolVersionType { uint32_t data[5]; - struct arraylen_SessionInformationType_ProtocolVersion arraylen; + struct arraylen_protocolVersionType arraylen; }; struct SessionInformationType { - struct SessionInformationType_SessionID SessionID; - struct SessionInformationType_ServiceSessionID ServiceSessionID; - struct SessionInformationType_ProtocolVersion ProtocolVersion; + struct sessionIDType SessionID; + struct sessionIDType ServiceSessionID; + struct protocolVersionType ProtocolVersion; struct selection_SessionInformationType isused; }; @@ -272,17 +278,17 @@ struct selection_NotificationType }; -struct arraylen_NotificationType_FaultMsg +struct arraylen_service_string { size_t data; }; -struct NotificationType_FaultMsg +struct service_string { uint32_t data[256]; - struct arraylen_NotificationType_FaultMsg arraylen; + struct arraylen_service_string arraylen; }; @@ -296,7 +302,7 @@ struct EventListType struct NotificationType { enum faultCodeType FaultCode; - struct NotificationType_FaultMsg FaultMsg; + struct service_string FaultMsg; struct EventListType EventList; struct selection_NotificationType isused; @@ -317,17 +323,17 @@ struct HeaderType }; -struct arraylen_SessionSetupReqType_PEVID +struct arraylen_pevIDType { size_t data; }; -struct SessionSetupReqType_PEVID +struct pevIDType { uint32_t data[32]; - struct arraylen_SessionSetupReqType_PEVID arraylen; + struct arraylen_pevIDType arraylen; }; @@ -342,13 +348,14 @@ struct PEVStatusType { int ConnectorLocked; int ChargerStandby; + int ReadyToCharge; }; struct SessionSetupReqType { - struct SessionSetupReqType_PEVID PEVID; + struct pevIDType PEVID; struct PEVStatusType PEVStatus; struct selection_SessionSetupReqType isused; @@ -364,8 +371,8 @@ struct selection_BodyType unsigned int ServicePaymentSelectionRes:1; unsigned int PaymentDetailsReq:1; unsigned int PaymentDetailsRes:1; - unsigned int PowerDiscoveryReq:1; - unsigned int PowerDiscoveryRes:1; + unsigned int ChargeParameterDiscoveryReq:1; + unsigned int ChargeParameterDiscoveryRes:1; unsigned int LineLockReq:1; unsigned int LineLockRes:1; unsigned int PowerDeliveryReq:1; @@ -374,21 +381,31 @@ struct selection_BodyType unsigned int MeteringStatusRes:1; unsigned int MeteringReceiptReq:1; unsigned int MeteringReceiptRes:1; + unsigned int CableCheckReq:1; + unsigned int CableCheckRes:1; + unsigned int PreChargeReq:1; + unsigned int PreChargeRes:1; + unsigned int CurrentDemandReq:1; + unsigned int CurrentDemandRes:1; + unsigned int WeldingDetectionReq:1; + unsigned int WeldingDetectionRes:1; + unsigned int TerminateChargingReq:1; + unsigned int TerminateChargingRes:1; }; -struct arraylen_SessionSetupResType_EVSEID +struct arraylen_evseIDType { size_t data; }; -struct SessionSetupResType_EVSEID +struct evseIDType { uint8_t data[32]; - struct arraylen_SessionSetupResType_EVSEID arraylen; + struct arraylen_evseIDType arraylen; }; @@ -400,6 +417,9 @@ struct EVSEStatusType int PowerSwitchClosed; int RCD; int32_t ShutDownTime; + int ChargerStandby; + int EVSEMalfunction; + int StopCharging; }; @@ -407,7 +427,7 @@ struct EVSEStatusType struct SessionSetupResType { enum responseCode_SessionSetupType ResponseCode; - struct SessionSetupResType_EVSEID EVSEID; + struct evseIDType EVSEID; struct EVSEStatusType EVSEStatus; int32_t TCurrent; @@ -422,53 +442,53 @@ struct selection_ServiceDiscoveryReqType }; -struct arraylen_ServiceDiscoveryReqType_ServiceScope +struct arraylen_serviceScopeType { size_t data; }; -struct ServiceDiscoveryReqType_ServiceScope +struct serviceScopeType { uint32_t data[20]; - struct arraylen_ServiceDiscoveryReqType_ServiceScope arraylen; + struct arraylen_serviceScopeType arraylen; }; struct ServiceDiscoveryReqType { enum serviceTypeType ServiceType; - struct ServiceDiscoveryReqType_ServiceScope ServiceScope; + struct serviceScopeType ServiceScope; struct selection_ServiceDiscoveryReqType isused; }; -struct arraylen_ServiceDescriptionType_ServiceID +struct arraylen_serviceIDType { size_t data; }; -struct ServiceDescriptionType_ServiceID +struct serviceIDType { uint8_t data[8]; - struct arraylen_ServiceDescriptionType_ServiceID arraylen; + struct arraylen_serviceIDType arraylen; }; -struct arraylen_ServiceDescriptionType_ServiceName +struct arraylen_serviceNameType { size_t data; }; -struct ServiceDescriptionType_ServiceName +struct serviceNameType { uint32_t data[20]; - struct arraylen_ServiceDescriptionType_ServiceName arraylen; + struct arraylen_serviceNameType arraylen; }; @@ -481,26 +501,12 @@ struct selection_ServiceDescriptionType }; -struct arraylen_ServiceDescriptionType_ServiceScope -{ - size_t data; - - -}; - -struct ServiceDescriptionType_ServiceScope -{ - uint32_t data[20]; - struct arraylen_ServiceDescriptionType_ServiceScope arraylen; - -}; - struct ServiceDescriptionType { - struct ServiceDescriptionType_ServiceID ServiceID; - struct ServiceDescriptionType_ServiceName ServiceName; + struct serviceIDType ServiceID; + struct serviceNameType ServiceName; enum serviceTypeType ServiceType; - struct ServiceDescriptionType_ServiceScope ServiceScope; + struct serviceScopeType ServiceScope; struct selection_ServiceDescriptionType isused; }; @@ -548,23 +554,23 @@ struct ServicePaymentSelectionResType }; -struct arraylen_PaymentDetailsReqType_ContractID +struct arraylen_contractIDType { size_t data; }; -struct PaymentDetailsReqType_ContractID +struct contractIDType { uint32_t data[128]; - struct arraylen_PaymentDetailsReqType_ContractID arraylen; + struct arraylen_contractIDType arraylen; }; struct PaymentDetailsReqType { - struct PaymentDetailsReqType_ContractID ContractID; + struct contractIDType ContractID; }; @@ -572,47 +578,51 @@ struct PaymentDetailsReqType struct PaymentDetailsResType { enum responseCode_PaymentDetailsType ResponseCode; + int32_t TCurrent; }; struct FloatingValueType { - enum unitMultiplierType Multiplier; + int16_t Multiplier; enum unitSymbolType Unit; int32_t Value; }; -struct PowerDiscoveryReqType +struct ChargeParameterDiscoveryReqType { struct PEVStatusType PEVStatus; + enum chargingModeType ChargingMode; int32_t EoC; struct FloatingValueType EAmount; struct FloatingValueType PEVMaxPower; int16_t PEVMaxPhases; struct FloatingValueType PEVMaxVoltage; struct FloatingValueType PEVMinVoltage; + struct FloatingValueType PEVMaxCurrent; + struct FloatingValueType PEVMinCurrent; }; -struct arraylen_PowerDiscoveryResType_EnergyProvider +struct arraylen_energyProviderType { size_t data; }; -struct PowerDiscoveryResType_EnergyProvider +struct energyProviderType { uint32_t data[20]; - struct arraylen_PowerDiscoveryResType_EnergyProvider arraylen; + struct arraylen_energyProviderType arraylen; }; -struct selection_PowerDiscoveryResType +struct selection_ChargeParameterDiscoveryResType { unsigned int EnergyProvider:1; unsigned int TariffTable:1; @@ -620,31 +630,31 @@ struct selection_PowerDiscoveryResType }; -struct arraylen_TariffTableType_Currency +struct arraylen_currencyType { size_t data; }; -struct TariffTableType_Currency +struct currencyType { uint32_t data[3]; - struct arraylen_TariffTableType_Currency arraylen; + struct arraylen_currencyType arraylen; }; -struct arraylen_TariffDescrType_TariffDescription +struct arraylen_tariffDescriptionType { size_t data; }; -struct TariffDescrType_TariffDescription +struct tariffDescriptionType { uint32_t data[32]; - struct arraylen_TariffDescrType_TariffDescription arraylen; + struct arraylen_tariffDescriptionType arraylen; }; @@ -688,7 +698,7 @@ struct TariffEntriesType struct TariffDescrType { enum tariffIDType TariffID; - struct TariffDescrType_TariffDescription TariffDescription; + struct tariffDescriptionType TariffDescription; struct TariffEntriesType TariffEntries; struct selection_TariffDescrType isused; @@ -703,22 +713,24 @@ struct arraylen_TariffTableType struct TariffTableType { - struct TariffTableType_Currency Currency; + struct currencyType Currency; struct TariffDescrType Tariff[6]; struct arraylen_TariffTableType arraylen; }; -struct PowerDiscoveryResType +struct ChargeParameterDiscoveryResType { - enum responseCode_PowerDiscoveryType ResponseCode; + enum responseCode_ChargeParameterDiscoveryType ResponseCode; struct EVSEStatusType EVSEStatus; - struct FloatingValueType EVSEVoltage; - struct FloatingValueType EVSEIMax; + struct FloatingValueType EVSEMaxVoltage; + struct FloatingValueType EVSEMinVoltage; + struct FloatingValueType EVSEMaxCurrent; + struct FloatingValueType EVSEMinCurrent; int16_t EVSEMaxPhases; - struct PowerDiscoveryResType_EnergyProvider EnergyProvider; + struct energyProviderType EnergyProvider; struct TariffTableType TariffTable; - struct selection_PowerDiscoveryResType isused; + struct selection_ChargeParameterDiscoveryResType isused; }; @@ -757,6 +769,7 @@ struct PowerDeliveryReqType struct PowerDeliveryResType { enum responseCode_PowerDeliveryType ResponseCode; + struct EVSEStatusType EVSEStatus; }; @@ -769,20 +782,6 @@ struct MeteringStatusReqType }; -struct arraylen_MeteringStatusResType_EVSEID -{ - size_t data; - - -}; - -struct MeteringStatusResType_EVSEID -{ - uint8_t data[32]; - struct arraylen_MeteringStatusResType_EVSEID arraylen; - -}; - struct selection_MeteringStatusResType { unsigned int PCurrent:1; @@ -791,17 +790,17 @@ struct selection_MeteringStatusResType }; -struct arraylen_MeterInfoType_MeterID +struct arraylen_meterIDType { size_t data; }; -struct MeterInfoType_MeterID +struct meterIDType { uint32_t data[32]; - struct arraylen_MeterInfoType_MeterID arraylen; + struct arraylen_meterIDType arraylen; }; @@ -817,7 +816,7 @@ struct selection_MeterInfoType struct MeterInfoType { - struct MeterInfoType_MeterID MeterID; + struct meterIDType MeterID; struct FloatingValueType MeterReading; int16_t MeterStatus; int32_t TMeter; @@ -828,7 +827,7 @@ struct MeterInfoType struct MeteringStatusResType { enum responseCode_MeteringStatusType ResponseCode; - struct MeteringStatusResType_EVSEID EVSEID; + struct evseIDType EVSEID; struct EVSEStatusType EVSEStatus; int32_t TCurrent; struct FloatingValueType EVSEMaxPower; @@ -838,20 +837,6 @@ struct MeteringStatusResType }; -struct arraylen_MeteringReceiptReqType_PEVID -{ - size_t data; - - -}; - -struct MeteringReceiptReqType_PEVID -{ - uint32_t data[32]; - struct arraylen_MeteringReceiptReqType_PEVID arraylen; - -}; - struct selection_MeteringReceiptReqType { unsigned int PEVID:1; @@ -862,7 +847,7 @@ struct selection_MeteringReceiptReqType struct MeteringReceiptReqType { - struct MeteringReceiptReqType_PEVID PEVID; + struct pevIDType PEVID; struct PEVStatusType PEVStatus; int32_t TCurrent; enum tariffIDType Tariff; @@ -876,6 +861,93 @@ struct MeteringReceiptResType enum responseCode_MeteringReceiptType ResponseCode; +}; + +struct CableCheckReqType +{ + struct PEVStatusType PEVStatus; + + +}; + +struct CableCheckResType +{ + enum responseCode_CableCheckType ResponseCode; + struct EVSEStatusType EVSEStatus; + + +}; + +struct PreChargeReqType +{ + struct PEVStatusType PEVStatus; + struct FloatingValueType PEVTargetVoltage; + struct FloatingValueType PEVDemandCurrent; + struct FloatingValueType VoltageDifferential; + + +}; + +struct PreChargeResType +{ + enum responseCode_PreChargeType ResponseCode; + struct EVSEStatusType EVSEStatus; + struct FloatingValueType EVSEPresentVoltage; + + +}; + +struct CurrentDemandReqType +{ + struct PEVStatusType PEVStatus; + struct FloatingValueType PEVTargetVoltage; + struct FloatingValueType PEVDemandCurrent; + struct FloatingValueType CurrentDifferential; + struct FloatingValueType VoltageDifferential; + + +}; + +struct CurrentDemandResType +{ + enum responseCode_CurrentDemandType ResponseCode; + struct EVSEStatusType EVSEStatus; + struct FloatingValueType EVSEPresentVoltage; + struct FloatingValueType EVSEPresentCurrent; + + +}; + +struct WeldingDetectionReqType +{ + struct PEVStatusType PEVStatus; + + +}; + +struct WeldingDetectionResType +{ + enum responseCode_WeldingDetectionType ResponseCode; + struct EVSEStatusType EVSEStatus; + struct FloatingValueType EVSEPresentVoltage; + + +}; + +struct TerminateChargingReqType +{ + struct PEVStatusType PEVStatus; + + +}; + +struct TerminateChargingResType +{ + enum responseCode_TerminateChargingType ResponseCode; + struct EVSEStatusType EVSEStatus; + struct FloatingValueType EVSEPresentVoltage; + + }; struct BodyType @@ -888,8 +960,8 @@ struct BodyType struct ServicePaymentSelectionResType* ServicePaymentSelectionRes; struct PaymentDetailsReqType* PaymentDetailsReq; struct PaymentDetailsResType* PaymentDetailsRes; - struct PowerDiscoveryReqType* PowerDiscoveryReq; - struct PowerDiscoveryResType* PowerDiscoveryRes; + struct ChargeParameterDiscoveryReqType* ChargeParameterDiscoveryReq; + struct ChargeParameterDiscoveryResType* ChargeParameterDiscoveryRes; struct LineLockReqType* LineLockReq; struct LineLockResType* LineLockRes; struct PowerDeliveryReqType* PowerDeliveryReq; @@ -898,6 +970,16 @@ struct BodyType struct MeteringStatusResType* MeteringStatusRes; struct MeteringReceiptReqType* MeteringReceiptReq; struct MeteringReceiptResType* MeteringReceiptRes; + struct CableCheckReqType* CableCheckReq; + struct CableCheckResType* CableCheckRes; + struct PreChargeReqType* PreChargeReq; + struct PreChargeResType* PreChargeRes; + struct CurrentDemandReqType* CurrentDemandReq; + struct CurrentDemandResType* CurrentDemandRes; + struct WeldingDetectionReqType* WeldingDetectionReq; + struct WeldingDetectionResType* WeldingDetectionRes; + struct TerminateChargingReqType* TerminateChargingReq; + struct TerminateChargingResType* TerminateChargingRes; struct selection_BodyType isused; }; diff --git a/src/service/v2g_serviceDispatcher.c b/src/service/v2g_serviceDispatcher.c index b925feb..905269f 100644 --- a/src/service/v2g_serviceDispatcher.c +++ b/src/service/v2g_serviceDispatcher.c @@ -2,7 +2,7 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -21,7 +21,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -50,492 +50,665 @@ static int deserializeElementCharacter(struct EXIService* service) switch(service->eqn.namespaceURI) { case 4: switch(service->eqn.localPart) { - case 24: /*PEVID*/ - - if(service->val.type == STRING) - { - if(service->idPath.id[2] == 56) + case 43: /*PEVID*/ + if(service->val.type == STRING) { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVID.arraylen.data = service->val.string.len; - service->exiMsg.V2G_Message.Body.SessionSetupReq->isused.PEVID=1; - } - else - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVID.arraylen.data = service->val.string.len; - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->isused.PEVID=1; - } - - } - else - { - return -1; /* wrong data type */ - } - - break; - case 55: /*ServiceType*/ - if(service->val.type == ENUMERATION) - { - if(service->idPath.id[1] == 0) - { - service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceType=service->val.enumeration; - service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceType=1; - - - } else if(service->idPath.id[1] == 0) - { - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].ServiceType=service->val.enumeration; - service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.Service[service->exiMsg.V2G_Message.Body.ServiceDiscoveryRes->ServiceList.arraylen.Service].isused.ServiceType=1; - - - } - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceType=1;*/ - break; - case 54: /*ServiceScope*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceScope.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceScope.arraylen.data = service->val.string.len; + if( service->idPath.id[2] == 78) + { + memcpy(service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVID.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.SessionSetupReq->isused.PEVID=1; + + } else if(service->idPath.id[2] == 33) + { + memcpy(service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVID.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->isused.PEVID=1; + } - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceScope=1;*/ - break; - case 0: /*ContractID*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.PaymentDetailsReq->ContractID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.PaymentDetailsReq->ContractID.arraylen.data = service->val.string.len; - } else { return -1; /* wrong data type */ } - + break; - case 9: /*EoC*/ - if(service->val.type == INTEGER_32) + case 77: /*ServiceType*/ + if(service->val.type == ENUMERATION) { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->EoC=service->val.int32; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceType = service->val.enumeration; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceType=1; + + } else { return -1; /* wrong data type */ } - + break; - case 25: /*PEVMaxPhases*/ - if(service->val.type == INTEGER_16) + case 76: /*ServiceScope*/ + if(service->val.type == STRING) { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxPhases=service->val.int32; + memcpy(service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceScope.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->ServiceScope.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceScope=1; + + } else { return -1; /* wrong data type */ } - + break; - case 42: /*ReqLockStatus*/ - if(service->val.type == BOOLEAN) + case 9: /*ContractID*/ + if(service->val.type == STRING) { - service->exiMsg.V2G_Message.Body.LineLockReq->ReqLockStatus=service->val.boolean; + memcpy(service->exiMsg.V2G_Message.Body.PaymentDetailsReq->ContractID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.PaymentDetailsReq->ContractID.arraylen.data = service->val.string.len; + + } else { return -1; /* wrong data type */ } - + break; - case 43: /*ReqSwitchStatus*/ - if(service->val.type == BOOLEAN) + case 8: /*ChargingMode*/ + if(service->val.type == ENUMERATION) { - service->exiMsg.V2G_Message.Body.PowerDeliveryReq->ReqSwitchStatus=service->val.boolean; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->ChargingMode = service->val.enumeration; + + } else { return -1; /* wrong data type */ } - + break; - case 61: /*Tariff*/ - if(service->val.type == ENUMERATION) + case 27: /*EoC*/ + if(service->val.type == INTEGER_32) { - if(service->idPath.id[2] == 34) - { - service->exiMsg.V2G_Message.Body.PowerDeliveryReq->Tariff=service->val.enumeration; - service->exiMsg.V2G_Message.Body.PowerDeliveryReq->isused.Tariff=1; - - - } else if(service->idPath.id[2] == 15) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->Tariff=service->val.enumeration; - - - } + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->EoC = service->val.int32; + + } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.PowerDeliveryReq->isused.Tariff=1;*/ + break; - case 60: /*TCurrent*/ - if(service->val.type == INTEGER_32) + case 45: /*PEVMaxPhases*/ + if(service->val.type == INTEGER_16) { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->TCurrent=service->val.int32; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxPhases = service->val.int32; + + } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.MeteringReceiptReq->isused.TCurrent=1;*/ + + break; + case 64: /*ReqLockStatus*/ + if(service->val.type == BOOLEAN) + { + service->exiMsg.V2G_Message.Body.LineLockReq->ReqLockStatus = service->val.boolean; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 65: /*ReqSwitchStatus*/ + if(service->val.type == BOOLEAN) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->ReqSwitchStatus = service->val.boolean; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 83: /*Tariff*/ + if(service->val.type == ENUMERATION) + { + if( service->idPath.id[2] == 56) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->Tariff = service->val.enumeration; + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->isused.Tariff=1; + + } else if(service->idPath.id[2] == 33) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->Tariff = service->val.enumeration; + } + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 82: /*TCurrent*/ + if(service->val.type == INTEGER_32) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->TCurrent = service->val.int32; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->isused.TCurrent=1; + + + } + else + { + return -1; /* wrong data type */ + } + break; } /* close switch(service->eqn.localPart) */ break; case 5: switch(service->eqn.localPart) { - case 34: /*SessionID*/ - - if(service->val.type == BINARY_HEX) - { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.arraylen.data = service->val.binary.len; - - } - else + case 36: /*SessionID*/ + if(service->val.type == BINARY_HEX) { - return -1; /* wrong data type */ - } - - break; - case 32: /*ServiceSessionID*/ - - if(service->val.type == BINARY_HEX) - { - /* array copy and array length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.data, service->val.binary.data,service->val.binary.len); - service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.arraylen.data = service->val.binary.len; - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - /*service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1;*/ - break; - case 24: /*ProtocolVersion*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.arraylen.data = service->val.string.len; + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Header->SessionInformation.SessionID.arraylen.data = service->val.binary.len; - - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - /*service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1;*/ - break; - case 9: /*Event*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Header->Notification.EventList.Event=service->val.enumeration; - } - else - { - return -1; /* wrong data type */ - } - - break; - case 13: /*FaultCode*/ - if(service->val.type == ENUMERATION) - { - service->exiMsg.V2G_Message.Header->Notification.FaultCode=service->val.enumeration; - } - else - { - return -1; /* wrong data type */ - } - - /* is used */ - /*service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1;*/ - break; - case 14: /*FaultMsg*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Header->Notification.FaultMsg.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Header->Notification.FaultMsg.arraylen.data = service->val.string.len; - } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1;*/ + + break; + case 34: /*ServiceSessionID*/ + if(service->val.type == BINARY_HEX) + { + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.data, service->val.binary.data,service->val.binary.len); + service->exiMsg.V2G_Message.Header->SessionInformation.ServiceSessionID.arraylen.data = service->val.binary.len; + service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 25: /*ProtocolVersion*/ + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Header->SessionInformation.ProtocolVersion.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 10: /*Event*/ + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Header->Notification.EventList.Event = service->val.enumeration; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 14: /*FaultCode*/ + if(service->val.type == ENUMERATION) + { + service->exiMsg.V2G_Message.Header->Notification.FaultCode = service->val.enumeration; + service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1; + + + } + else + { + return -1; /* wrong data type */ + } + + break; + case 15: /*FaultMsg*/ + if(service->val.type == STRING) + { + memcpy(service->exiMsg.V2G_Message.Header->Notification.FaultMsg.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Header->Notification.FaultMsg.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1; + + + } + else + { + return -1; /* wrong data type */ + } + break; case 4: /*ConnectorLocked*/ - if(service->val.type == BOOLEAN) + if(service->val.type == BOOLEAN) { - if(service->idPath.id[2] == 56) - { - service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 38) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 10) - { - service->exiMsg.V2G_Message.Body.LineLockReq->PEVStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 34) - { - service->exiMsg.V2G_Message.Body.PowerDeliveryReq->PEVStatus.ConnectorLocked=service->val.boolean; - - - } else if(service->idPath.id[2] == 15) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVStatus.ConnectorLocked=service->val.boolean; - - - } + if( service->idPath.id[2] == 78) + { + service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 4) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 28) + { + service->exiMsg.V2G_Message.Body.LineLockReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 56) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 33) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 0) + { + service->exiMsg.V2G_Message.Body.CableCheckReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 90) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionReq->PEVStatus.ConnectorLocked = service->val.boolean; + + } else if(service->idPath.id[2] == 85) + { + service->exiMsg.V2G_Message.Body.TerminateChargingReq->PEVStatus.ConnectorLocked = service->val.boolean; + } + + } else { return -1; /* wrong data type */ } - + break; case 0: /*ChargerStandby*/ - if(service->val.type == BOOLEAN) + if(service->val.type == BOOLEAN) { - if(service->idPath.id[2] == 56) - { - service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVStatus.ChargerStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 38) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVStatus.ChargerStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 10) - { - service->exiMsg.V2G_Message.Body.LineLockReq->PEVStatus.ChargerStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 34) - { - service->exiMsg.V2G_Message.Body.PowerDeliveryReq->PEVStatus.ChargerStandby=service->val.boolean; - - - } else if(service->idPath.id[2] == 15) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVStatus.ChargerStandby=service->val.boolean; - - - } + if( service->idPath.id[2] == 78) + { + service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 4) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 28) + { + service->exiMsg.V2G_Message.Body.LineLockReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 56) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 33) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 0) + { + service->exiMsg.V2G_Message.Body.CableCheckReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 90) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionReq->PEVStatus.ChargerStandby = service->val.boolean; + + } else if(service->idPath.id[2] == 85) + { + service->exiMsg.V2G_Message.Body.TerminateChargingReq->PEVStatus.ChargerStandby = service->val.boolean; + } + + } else { return -1; /* wrong data type */ } - + break; - case 20: /*Multiplier*/ - if(service->val.type == ENUMERATION) + case 27: /*ReadyToCharge*/ + if(service->val.type == BOOLEAN) { - if(service->idPath.id[3] == 1) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->EAmount.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 26) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxPower.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 27) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxVoltage.Multiplier=service->val.enumeration; - - - } else if(service->idPath.id[3] == 28) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMinVoltage.Multiplier=service->val.enumeration; - - - }else if(service->idPath.id[3] == 14) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Multiplier=service->val.enumeration; + if( service->idPath.id[2] == 78) + { + service->exiMsg.V2G_Message.Body.SessionSetupReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 4) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 28) + { + service->exiMsg.V2G_Message.Body.LineLockReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 56) + { + service->exiMsg.V2G_Message.Body.PowerDeliveryReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 33) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 0) + { + service->exiMsg.V2G_Message.Body.CableCheckReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 90) + { + service->exiMsg.V2G_Message.Body.WeldingDetectionReq->PEVStatus.ReadyToCharge = service->val.boolean; + + } else if(service->idPath.id[2] == 85) + { + service->exiMsg.V2G_Message.Body.TerminateChargingReq->PEVStatus.ReadyToCharge = service->val.boolean; + } + - } } else { return -1; /* wrong data type */ } - + break; - case 49: /*Unit*/ - if(service->val.type == ENUMERATION) + case 21: /*Multiplier*/ + if(service->val.type == INTEGER_16) { - if(service->idPath.id[3] == 1) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->EAmount.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 26) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxPower.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 27) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxVoltage.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 28) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMinVoltage.Unit=service->val.enumeration; - - - } else if(service->idPath.id[3] == 14) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Unit=service->val.enumeration; + if( service->idPath.id[3] == 15) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->EAmount.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 46) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxPower.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 47) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 44) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 48) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVTargetVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVDemandCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->VoltageDifferential.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVTargetVoltage.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVDemandCurrent.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 14) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->CurrentDifferential.Multiplier = service->val.int32; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->VoltageDifferential.Multiplier = service->val.int32; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Multiplier = service->val.int32; + } + - } } else { return -1; /* wrong data type */ } - + break; - case 50: /*Value*/ - if(service->val.type == INTEGER_32) + case 52: /*Unit*/ + if(service->val.type == ENUMERATION) { - if(service->idPath.id[3] == 1) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->EAmount.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 26) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxPower.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 27) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMaxVoltage.Value=service->val.int32; - - - } else if(service->idPath.id[3] == 28) - { - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq->PEVMinVoltage.Value=service->val.int32; - - - }else if(service->idPath.id[3] == 14) - { - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Value=service->val.int32; + if( service->idPath.id[3] == 15) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->EAmount.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 46) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxPower.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 47) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 44) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 48) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVTargetVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVDemandCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->VoltageDifferential.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVTargetVoltage.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVDemandCurrent.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 14) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->CurrentDifferential.Unit = service->val.enumeration; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->VoltageDifferential.Unit = service->val.enumeration; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Unit = service->val.enumeration; + } + - } } else { return -1; /* wrong data type */ } - + break; - case 16: /*MeterID*/ - - if(service->val.type == STRING) - { - /* string copy and string length assignment */ - memcpy(service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterID.arraylen.data = service->val.string.len; + case 53: /*Value*/ + if(service->val.type == INTEGER_32) + { + if( service->idPath.id[3] == 15) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->EAmount.Value = service->val.int32; + + } else if(service->idPath.id[3] == 46) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxPower.Value = service->val.int32; + + } else if(service->idPath.id[3] == 47) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 49) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 44) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMaxCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 48) + { + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq->PEVMinCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVTargetVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->PEVDemandCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 60) + { + service->exiMsg.V2G_Message.Body.PreChargeReq->VoltageDifferential.Value = service->val.int32; + + } else if(service->idPath.id[3] == 51 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVTargetVoltage.Value = service->val.int32; + + } else if(service->idPath.id[3] == 42 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->PEVDemandCurrent.Value = service->val.int32; + + } else if(service->idPath.id[3] == 14) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->CurrentDifferential.Value = service->val.int32; + + } else if(service->idPath.id[3] == 89 && service->idPath.id[2] == 10) + { + service->exiMsg.V2G_Message.Body.CurrentDemandReq->VoltageDifferential.Value = service->val.int32; + + } else if(service->idPath.id[4] == 19) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterReading.Value = service->val.int32; + } + - } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterID=1;*/ + break; - case 19: /*MeterStatus*/ - if(service->val.type == INTEGER_16) + case 17: /*MeterID*/ + if(service->val.type == STRING) { + memcpy(service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterID.data, service->val.string.codepoints,service->val.string.len*sizeof(uint32_t)); + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterID.arraylen.data = service->val.string.len; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.MeterID=1; - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterStatus=service->val.int32; } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.MeterStatus=1;*/ + break; - case 37: /*TMeter*/ - if(service->val.type == INTEGER_32) + case 20: /*MeterStatus*/ + if(service->val.type == INTEGER_16) { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.MeterStatus = service->val.int32; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.MeterStatus=1; - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.TMeter=service->val.int32; } else { return -1; /* wrong data type */ } - - /* is used */ - /*service->exiMsg.V2G_Message.Body.MeteringStatusRes->MeterInfo.isused.TMeter=1;*/ + + break; + case 40: /*TMeter*/ + if(service->val.type == INTEGER_32) + { + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.TMeter = service->val.int32; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.TMeter=1; + + + } + else + { + return -1; /* wrong data type */ + } + break; } /* close switch(service->eqn.localPart) */ break; @@ -554,19 +727,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) switch(service->eqn.namespaceURI) { case 4: switch(service->eqn.localPart) { - case 54:/* ServiceScope */ - - - /* is used */ - service->exiMsg.V2G_Message.Body.ServiceDiscoveryReq->isused.ServiceScope=1; - break; - case 60:/* TCurrent */ - - - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->isused.TCurrent=1; - break; - case 56:/* SessionSetupReq */ + case 78:/* SessionSetupReq */ @@ -583,6 +744,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.SessionSetupRes=1; + service->exiMsg.V2G_Message.Body.isused.SessionSetupReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -594,7 +756,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 45:/* ServiceDiscoveryReq */ + case 67:/* ServiceDiscoveryReq */ @@ -611,6 +773,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.ServiceDiscoveryRes=1; + service->exiMsg.V2G_Message.Body.isused.ServiceDiscoveryReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -622,7 +785,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 50:/* ServicePaymentSelectionReq */ + case 72:/* ServicePaymentSelectionReq */ @@ -639,6 +802,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.ServicePaymentSelectionRes=1; + service->exiMsg.V2G_Message.Body.isused.ServicePaymentSelectionReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -650,7 +814,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 30:/* PaymentDetailsReq */ + case 52:/* PaymentDetailsReq */ @@ -667,6 +831,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.PaymentDetailsRes=1; + service->exiMsg.V2G_Message.Body.isused.PaymentDetailsReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -678,7 +843,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 38:/* PowerDiscoveryReq */ + case 4:/* ChargeParameterDiscoveryReq */ @@ -691,10 +856,11 @@ static int deserializeElementOrServiceCall(struct EXIService* service) } /* service call */ - powerDiscovery((service->exiMsg.V2G_Message.Body.PowerDiscoveryReq), (service->exiMsg.V2G_Message.Body.PowerDiscoveryRes)); + chargeParameterDiscovery((service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq), (service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes)); /* signalize the response message */ - service->exiMsg.V2G_Message.Body.isused.PowerDiscoveryRes=1; + service->exiMsg.V2G_Message.Body.isused.ChargeParameterDiscoveryRes=1; + service->exiMsg.V2G_Message.Body.isused.ChargeParameterDiscoveryReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -706,7 +872,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 10:/* LineLockReq */ + case 28:/* LineLockReq */ @@ -723,6 +889,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.LineLockRes=1; + service->exiMsg.V2G_Message.Body.isused.LineLockReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -734,7 +901,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 34:/* PowerDeliveryReq */ + case 56:/* PowerDeliveryReq */ @@ -751,6 +918,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.PowerDeliveryRes=1; + service->exiMsg.V2G_Message.Body.isused.PowerDeliveryReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -762,7 +930,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 19:/* MeteringStatusReq */ + case 37:/* MeteringStatusReq */ @@ -779,6 +947,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.MeteringStatusRes=1; + service->exiMsg.V2G_Message.Body.isused.MeteringStatusReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -790,7 +959,7 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; - case 15:/* MeteringReceiptReq */ + case 33:/* MeteringReceiptReq */ @@ -807,6 +976,152 @@ static int deserializeElementOrServiceCall(struct EXIService* service) /* signalize the response message */ service->exiMsg.V2G_Message.Body.isused.MeteringReceiptRes=1; + service->exiMsg.V2G_Message.Body.isused.MeteringReceiptReq=0; + + /* serialize the response data */ + if(serialize_message(service)) + { + /* serializiation error*/ + service->errorCode= EXI_SERIALIZATION_FAILED; + } + + + + break; + case 0:/* CableCheckReq */ + + + + + /* test, if data length is unequal to the expected payload */ + if((service->inStream.size)!= *(service->inStream.pos)) + { + service->errorCode = EXI_NON_VALID_MESSAGE; + return -1; + } + + /* service call */ + cableCheck((service->exiMsg.V2G_Message.Body.CableCheckReq), (service->exiMsg.V2G_Message.Body.CableCheckRes)); + + /* signalize the response message */ + service->exiMsg.V2G_Message.Body.isused.CableCheckRes=1; + service->exiMsg.V2G_Message.Body.isused.CableCheckReq=0; + + /* serialize the response data */ + if(serialize_message(service)) + { + /* serializiation error*/ + service->errorCode= EXI_SERIALIZATION_FAILED; + } + + + + break; + case 60:/* PreChargeReq */ + + + + + /* test, if data length is unequal to the expected payload */ + if((service->inStream.size)!= *(service->inStream.pos)) + { + service->errorCode = EXI_NON_VALID_MESSAGE; + return -1; + } + + /* service call */ + preCharge((service->exiMsg.V2G_Message.Body.PreChargeReq), (service->exiMsg.V2G_Message.Body.PreChargeRes)); + + /* signalize the response message */ + service->exiMsg.V2G_Message.Body.isused.PreChargeRes=1; + service->exiMsg.V2G_Message.Body.isused.PreChargeReq=0; + + /* serialize the response data */ + if(serialize_message(service)) + { + /* serializiation error*/ + service->errorCode= EXI_SERIALIZATION_FAILED; + } + + + + break; + case 10:/* CurrentDemandReq */ + + + + + /* test, if data length is unequal to the expected payload */ + if((service->inStream.size)!= *(service->inStream.pos)) + { + service->errorCode = EXI_NON_VALID_MESSAGE; + return -1; + } + + /* service call */ + currentDemand((service->exiMsg.V2G_Message.Body.CurrentDemandReq), (service->exiMsg.V2G_Message.Body.CurrentDemandRes)); + + /* signalize the response message */ + service->exiMsg.V2G_Message.Body.isused.CurrentDemandRes=1; + service->exiMsg.V2G_Message.Body.isused.CurrentDemandReq=0; + + /* serialize the response data */ + if(serialize_message(service)) + { + /* serializiation error*/ + service->errorCode= EXI_SERIALIZATION_FAILED; + } + + + + break; + case 90:/* WeldingDetectionReq */ + + + + + /* test, if data length is unequal to the expected payload */ + if((service->inStream.size)!= *(service->inStream.pos)) + { + service->errorCode = EXI_NON_VALID_MESSAGE; + return -1; + } + + /* service call */ + weldingDetection((service->exiMsg.V2G_Message.Body.WeldingDetectionReq), (service->exiMsg.V2G_Message.Body.WeldingDetectionRes)); + + /* signalize the response message */ + service->exiMsg.V2G_Message.Body.isused.WeldingDetectionRes=1; + service->exiMsg.V2G_Message.Body.isused.WeldingDetectionReq=0; + + /* serialize the response data */ + if(serialize_message(service)) + { + /* serializiation error*/ + service->errorCode= EXI_SERIALIZATION_FAILED; + } + + + + break; + case 85:/* TerminateChargingReq */ + + + + + /* test, if data length is unequal to the expected payload */ + if((service->inStream.size)!= *(service->inStream.pos)) + { + service->errorCode = EXI_NON_VALID_MESSAGE; + return -1; + } + + /* service call */ + terminateCharging((service->exiMsg.V2G_Message.Body.TerminateChargingReq), (service->exiMsg.V2G_Message.Body.TerminateChargingRes)); + + /* signalize the response message */ + service->exiMsg.V2G_Message.Body.isused.TerminateChargingRes=1; + service->exiMsg.V2G_Message.Body.isused.TerminateChargingReq=0; /* serialize the response data */ if(serialize_message(service)) @@ -822,53 +1137,20 @@ static int deserializeElementOrServiceCall(struct EXIService* service) break; case 5: switch(service->eqn.localPart) { - case 32:/* ServiceSessionID */ + case 11:/* EventList */ - - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ServiceSessionID=1; + service->exiMsg.V2G_Message.Header->Notification.isused.EventList=1; + break; - case 24:/* ProtocolVersion */ + case 28:/* Service */ - - /* is used */ - service->exiMsg.V2G_Message.Header->SessionInformation.isused.ProtocolVersion=1; + service->exiMsg.V2G_Message.Body.ServicePaymentSelectionReq->ServiceList.arraylen.Service++; + break; - case 13:/* FaultCode */ + case 19:/* MeterReading */ - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultCode=1; - break; - case 14:/* FaultMsg */ - - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.FaultMsg=1; - break; - case 10:/* EventList */ - - - /* is used */ - service->exiMsg.V2G_Message.Header->Notification.isused.EventList=1; - break; - case 26:/* Service */ - - /* increment*/ - service->exiMsg.V2G_Message.Body.ServicePaymentSelectionReq->ServiceList.arraylen.Service++; - - break; - case 16:/* MeterID */ - - - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.MeterID=1; - break; - case 18:/* MeterReading */ - - - /* is used */ - service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.MeterReading=1; + service->exiMsg.V2G_Message.Body.MeteringReceiptReq->MeterInfo.isused.MeterReading=1; + break; } break; @@ -876,13 +1158,13 @@ static int deserializeElementOrServiceCall(struct EXIService* service) switch(service->eqn.localPart) { case 1:/* Notification */ - - /* is used */ - service->exiMsg.V2G_Message.Header->isused.Notification=1; + service->exiMsg.V2G_Message.Header->isused.Notification=1; + break; } break; + } return 0; } @@ -931,14 +1213,14 @@ static int deserializePaymentDetailsReqMsg(struct EXIService* service) return deserializeMessage(service); } -static int deserializePowerDiscoveryReqMsg(struct EXIService* service) +static int deserializeChargeParameterDiscoveryReqMsg(struct EXIService* service) { - struct PowerDiscoveryReqType reqMsg; - struct PowerDiscoveryResType resMsg; - init_PowerDiscoveryReqType(&reqMsg); + struct ChargeParameterDiscoveryReqType reqMsg; + struct ChargeParameterDiscoveryResType resMsg; + init_ChargeParameterDiscoveryReqType(&reqMsg); - service->exiMsg.V2G_Message.Body.PowerDiscoveryReq = &reqMsg; - service->exiMsg.V2G_Message.Body.PowerDiscoveryRes = &resMsg; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryReq = &reqMsg; + service->exiMsg.V2G_Message.Body.ChargeParameterDiscoveryRes = &resMsg; return deserializeMessage(service); } @@ -989,6 +1271,60 @@ static int deserializeMeteringReceiptReqMsg(struct EXIService* service) return deserializeMessage(service); } +static int deserializeCableCheckReqMsg(struct EXIService* service) +{ + struct CableCheckReqType reqMsg; + struct CableCheckResType resMsg; + service->exiMsg.V2G_Message.Body.CableCheckReq = &reqMsg; + service->exiMsg.V2G_Message.Body.CableCheckRes = &resMsg; + + return deserializeMessage(service); +} + +static int deserializePreChargeReqMsg(struct EXIService* service) +{ + struct PreChargeReqType reqMsg; + struct PreChargeResType resMsg; + init_PreChargeReqType(&reqMsg); + + service->exiMsg.V2G_Message.Body.PreChargeReq = &reqMsg; + service->exiMsg.V2G_Message.Body.PreChargeRes = &resMsg; + + return deserializeMessage(service); +} + +static int deserializeCurrentDemandReqMsg(struct EXIService* service) +{ + struct CurrentDemandReqType reqMsg; + struct CurrentDemandResType resMsg; + init_CurrentDemandReqType(&reqMsg); + + service->exiMsg.V2G_Message.Body.CurrentDemandReq = &reqMsg; + service->exiMsg.V2G_Message.Body.CurrentDemandRes = &resMsg; + + return deserializeMessage(service); +} + +static int deserializeWeldingDetectionReqMsg(struct EXIService* service) +{ + struct WeldingDetectionReqType reqMsg; + struct WeldingDetectionResType resMsg; + service->exiMsg.V2G_Message.Body.WeldingDetectionReq = &reqMsg; + service->exiMsg.V2G_Message.Body.WeldingDetectionRes = &resMsg; + + return deserializeMessage(service); +} + +static int deserializeTerminateChargingReqMsg(struct EXIService* service) +{ + struct TerminateChargingReqType reqMsg; + struct TerminateChargingResType resMsg; + service->exiMsg.V2G_Message.Body.TerminateChargingReq = &reqMsg; + service->exiMsg.V2G_Message.Body.TerminateChargingRes = &resMsg; + + return deserializeMessage(service); +} + /** * Deserialize the EXI stream * @return 0 = 0K; -1 = ERROR @@ -1028,33 +1364,48 @@ static int deserializeMessage(struct EXIService* service) service->idPath.id[service->idPath.pos++]=service->eqn.localPart; /* setup the request context*/ - if(service->eqn.localPart==56 && service->eqn.namespaceURI==4) + if(service->eqn.localPart==78 && service->eqn.namespaceURI==4) { return deserializeSessionSetupReqMsg(service); - } else if(service->eqn.localPart==45 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==67 && service->eqn.namespaceURI==4) { return deserializeServiceDiscoveryReqMsg(service); - } else if(service->eqn.localPart==50 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==72 && service->eqn.namespaceURI==4) { return deserializeServicePaymentSelectionReqMsg(service); - } else if(service->eqn.localPart==30 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==52 && service->eqn.namespaceURI==4) { return deserializePaymentDetailsReqMsg(service); - } else if(service->eqn.localPart==38 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==4 && service->eqn.namespaceURI==4) { - return deserializePowerDiscoveryReqMsg(service); - } else if(service->eqn.localPart==10 && service->eqn.namespaceURI==4) + return deserializeChargeParameterDiscoveryReqMsg(service); + } else if(service->eqn.localPart==28 && service->eqn.namespaceURI==4) { return deserializeLineLockReqMsg(service); - } else if(service->eqn.localPart==34 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==56 && service->eqn.namespaceURI==4) { return deserializePowerDeliveryReqMsg(service); - } else if(service->eqn.localPart==19 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==37 && service->eqn.namespaceURI==4) { return deserializeMeteringStatusReqMsg(service); - } else if(service->eqn.localPart==15 && service->eqn.namespaceURI==4) + } else if(service->eqn.localPart==33 && service->eqn.namespaceURI==4) { return deserializeMeteringReceiptReqMsg(service); + } else if(service->eqn.localPart==0 && service->eqn.namespaceURI==4) + { + return deserializeCableCheckReqMsg(service); + } else if(service->eqn.localPart==60 && service->eqn.namespaceURI==4) + { + return deserializePreChargeReqMsg(service); + } else if(service->eqn.localPart==10 && service->eqn.namespaceURI==4) + { + return deserializeCurrentDemandReqMsg(service); + } else if(service->eqn.localPart==90 && service->eqn.namespaceURI==4) + { + return deserializeWeldingDetectionReqMsg(service); + } else if(service->eqn.localPart==85 && service->eqn.namespaceURI==4) + { + return deserializeTerminateChargingReqMsg(service); } diff --git a/src/service/v2g_serviceDispatcher.h b/src/service/v2g_serviceDispatcher.h index 24de0aa..9f65eff 100644 --- a/src/service/v2g_serviceDispatcher.h +++ b/src/service/v2g_serviceDispatcher.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/service/v2g_serviceMethods.h b/src/service/v2g_serviceMethods.h index e2cbd9a..bf49988 100644 --- a/src/service/v2g_serviceMethods.h +++ b/src/service/v2g_serviceMethods.h @@ -3,7 +3,7 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -22,7 +22,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.3.2 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -47,7 +47,7 @@ int selectedServicePayment(struct ServicePaymentSelectionReqType* param, struct int paymentDetails(struct PaymentDetailsReqType* param, struct PaymentDetailsResType* result); -int powerDiscovery(struct PowerDiscoveryReqType* param, struct PowerDiscoveryResType* result); +int chargeParameterDiscovery(struct ChargeParameterDiscoveryReqType* param, struct ChargeParameterDiscoveryResType* result); int lineLock(struct LineLockReqType* param, struct LineLockResType* result); @@ -56,6 +56,16 @@ int powerDelivery(struct PowerDeliveryReqType* param, struct PowerDeliveryResTyp int meteringStatus(struct MeteringStatusReqType* param, struct MeteringStatusResType* result); int meteringReceipt(struct MeteringReceiptReqType* param, struct MeteringReceiptResType* result); + +int cableCheck(struct CableCheckReqType* param, struct CableCheckResType* result); + +int preCharge(struct PreChargeReqType* param, struct PreChargeResType* result); + +int currentDemand(struct CurrentDemandReqType* param, struct CurrentDemandResType* result); + +int weldingDetection(struct WeldingDetectionReqType* param, struct WeldingDetectionResType* result); + +int terminateCharging(struct TerminateChargingReqType* param, struct TerminateChargingResType* result); diff --git a/src/test/main.c b/src/test/main.c index 68707c7..42c4fa0 100644 --- a/src/test/main.c +++ b/src/test/main.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ * * @author Daniel.Peintner.EXT@siemens.com * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * *Switch for sample programs: EXI codec only or for entire V2G service
@@ -33,7 +33,8 @@ int main(int argc, char *argv[]) { /* EXI codec only */ - /* return main_codec(argc, argv); */ + /* return main_codec(argc, argv);*/ + /* V2G client / service example scenario */ return main_service(argc, argv); diff --git a/src/test/main.h b/src/test/main.h index 6359256..37cf8b7 100644 --- a/src/test/main.h +++ b/src/test/main.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ * * @author Daniel.Peintner.EXT@siemens.com * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * * diff --git a/src/test/main_codec.c b/src/test/main_codec.c index e6a9b5b..11f6621 100644 --- a/src/test/main_codec.c +++ b/src/test/main_codec.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Daniel.Peintner.EXT@siemens.com - * @version 0.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * *Sample program to illustrate how to read an EXI stream and diff --git a/src/test/main_service.c b/src/test/main_service.c index 11ed4a9..2fbb10d 100644 --- a/src/test/main_service.c +++ b/src/test/main_service.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -37,10 +37,309 @@ #define MAX_STRING_SIZE 256 #define MAX_STREAM_SIZE 60 +static uint8_t byte_array[MAX_BYTE_SIZE]; /* define MAX_BYTE_SIZE before*/ +static uint32_t string_array[MAX_STRING_SIZE]; /* define MAX_STRING_SIZE before*/ + +static void printEVSEStatus(struct EVSEStatusType* status); static void printErrorMessage(struct EXIService* service); -int main_service(int argc, char *argv[]) +static int ac_charging() { + /* define in and out byte stream */ + uint8_t inStream[MAX_STREAM_SIZE]; /* define MAX_STREAM_SIZE before */ + uint8_t outStream[MAX_STREAM_SIZE]; /* define MAX_STREAM_SIZE before */ + + /* define offset variable for transport header data */ + uint16_t transportHeaderOffset; + + /* service data structure */ + struct EXIService service; + struct HeaderType v2gHeader; + struct SessionSetupReqType sessionSetup; + struct SessionSetupResType resultSessionSetup; + struct ChargeParameterDiscoveryReqType powerDiscovery; + struct ChargeParameterDiscoveryResType resultPowerDiscovery; + struct LineLockReqType lineLock; + struct LineLockResType resultLineLock; + struct PowerDeliveryReqType powerDelivery; + struct PowerDeliveryResType resultPowerDelivery; + struct MeteringStatusResType resultMeteringStatus; + struct MeteringReceiptReqType meteringReceipt; + struct MeteringReceiptResType resultMeteringReceipt; + + + struct FloatingValueType float_type; /* test float type*/ + + + /* BINARY memory setup */ + bytes_t bytes = { MAX_BYTE_SIZE, byte_array, 0 }; + + /* STRING memory setup */ + string_ucs_t string = { MAX_STRING_SIZE, string_array, 0 }; + + /* setup offset for DoIP header (otherwise set + * transportHeaderOffset=0 if no transfer protocol is used)*/ + transportHeaderOffset = DOIP_HEADER_LENGTH; + + /******************* + * Init V2G Client * + *******************/ + + init_v2gServiceClient(&service,bytes,string,inStream,MAX_STREAM_SIZE, outStream, MAX_STREAM_SIZE, transportHeaderOffset); + + /******************************* + * Setup data for sessionSetup * + *******************************/ + + /* setup header information */ + v2gHeader.SessionInformation.SessionID.arraylen.data = 0; /* no session id in the initial message -> array length = 0*/ + v2gHeader.SessionInformation.ProtocolVersion.data[0]='1'; /* assign protocol version number*/ + v2gHeader.SessionInformation.ProtocolVersion.arraylen.data=1; /* array string length =1 of protocol version */ + v2gHeader.SessionInformation.isused.ProtocolVersion = 1; /* important: optional elements have to be set used (=1) or not used (=0) */ + v2gHeader.SessionInformation.isused.ServiceSessionID = 0; /* service session is not used */ + v2gHeader.isused.Notification=0; /* no notification */ + + /* setup sessionSetup parameter */ + sessionSetup.isused.PEVID=1; /* PEVID is transported */ + sessionSetup.PEVID.arraylen.data=1; + sessionSetup.PEVID.data[0]=10; + sessionSetup.PEVStatus.ChargerStandby=0; /* charger standby = true */ + sessionSetup.PEVStatus.ConnectorLocked=0; /* connector locked = false */ + sessionSetup.PEVStatus.ReadyToCharge=0; /* ReadyToCharge = false */ + + + + printf("PEV: call EVSE sessionSetup\n"); + + /********************* + * Call sessionSetup * + *********************/ + if(call_sessionSetup(&service,&v2gHeader,&sessionSetup,&resultSessionSetup)) + { + printErrorMessage(&service); + } + else + { + /* show result of the answer message of EVSE sessionSetup */ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d (OK)\n",resultSessionSetup.ResponseCode); + printf("\tEVSEID=%d\n", resultSessionSetup.EVSEID.data[0]); + printEVSEStatus(&resultSessionSetup.EVSEStatus); + printf("\tTCurrent=%d\n",resultSessionSetup.TCurrent); + } + + + /******************************************* + * Setup data for chargeParameterDiscovery * + *******************************************/ + + powerDiscovery.PEVStatus.ChargerStandby = 1; + powerDiscovery.PEVStatus.ConnectorLocked = 0; + powerDiscovery.PEVStatus.ReadyToCharge=0; + powerDiscovery.ChargingMode = AC_charging_chargingModeType; + powerDiscovery.EoC = 12345678; + + float_type.Multiplier = 0; + float_type.Unit = J_unitSymbolType; + float_type.Value = 100; + + powerDiscovery.EAmount = float_type; + powerDiscovery.PEVMaxPhases = 3; + + float_type.Unit = W_unitSymbolType; + float_type.Value = 600; + powerDiscovery.PEVMaxPower = float_type; + + float_type.Unit = V_unitSymbolType; + float_type.Value = 1000; + powerDiscovery.PEVMaxVoltage = float_type; + float_type.Value = 200; + powerDiscovery.PEVMinVoltage = float_type; + + /* only required for DC */ + float_type.Unit = A_unitSymbolType; + float_type.Value = 200; + powerDiscovery.PEVMaxCurrent = float_type; + powerDiscovery.PEVMinCurrent = float_type; + + + /********************************* + * Call chargeParameterDiscovery * + *********************************/ + printf("\nPEV: call EVSE chargeParameterDiscovery\n"); + + if(call_chargeParameterDiscovery(&service,&v2gHeader,&powerDiscovery,&resultPowerDiscovery)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPowerDiscovery.ResponseCode); + printEVSEStatus(&resultPowerDiscovery.EVSEStatus); + printf("\tEVSEMaxVoltage=%d\n",resultPowerDiscovery.EVSEMaxVoltage.Value); + /*printf("\tEVSEMaxCurrent=%d\n",resultPowerDiscovery.EVSEMaxCurrent.Value);*/ + printf("\tEVSEMaxPhases=%d\n",resultPowerDiscovery.EVSEMaxPhases); + + /*printf("\tEnergyProvider=%d\n",resultPowerDiscovery.EnergyProvider.data[0]);*/ + + } + + + + + /********************************* + * Setup data for lineLock * + *********************************/ + + lineLock.PEVStatus.ChargerStandby = 1; + lineLock.PEVStatus.ConnectorLocked = 1; + lineLock.PEVStatus.ReadyToCharge = 1; + lineLock.ReqLockStatus = 1; + + /*********************** + * Call lineLock * + ***********************/ + printf("\nPEV: call EVSE lineLock\n"); + + if(call_lineLock(&service,&v2gHeader,&lineLock,&resultLineLock)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultLineLock.ResponseCode); + printEVSEStatus(&resultLineLock.EVSEStatus); + + } + + + + /********************************* + * Setup data for powerDelivery * + *********************************/ + + powerDelivery.PEVStatus = lineLock.PEVStatus; /* PEV status, taken from lineLock */ + /*powerDelivery.isused.Tariff = 0; + powerDelivery.Tariff = Green_charge_tariffIDType;*/ + + /*********************** + * Call powerDelivery * + ***********************/ + printf("\nPEV: call EVSE powerDelivery\n"); + + if(call_powerDelivery(&service,&v2gHeader,&powerDelivery,&resultPowerDelivery)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPowerDelivery.ResponseCode); + } + + + + + + + /******************** + * Call meterStatus * + ********************/ + + printf("\nPEV: call EVSE meterStatus\n"); + + if(call_meteringStatus(&service,&v2gHeader,&resultMeteringStatus)) + { + printErrorMessage(&service); + } + else + { + + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPowerDiscovery.ResponseCode); + printEVSEStatus(&resultPowerDiscovery.EVSEStatus); + printf("\tEVSEID=%d\n",resultMeteringStatus.EVSEID.data[0]); + printf("\tEVSEMaxPower=%d\n",resultMeteringStatus.EVSEMaxPower.Value); + printf("\tisused.MeterInfo=%d\n", resultMeteringStatus.isused.MeterInfo); + printf("\t\tMeterInfo.MeterID=%d\n", resultMeteringStatus.MeterInfo.MeterID.data[0]); + printf("\t\tMeterInfo.MeterReading.Value=%d\n", resultMeteringStatus.MeterInfo.MeterReading.Value); + printf("\t\tMeterInfo.MeterStatus=%d\n", resultMeteringStatus.MeterInfo.MeterStatus); + /* printf("\t\tMeterInfo.TMeter=%d\n", resultMeteringStatus.MeterInfo.TMeter);*/ + /* printf("\t\tisused.PCurrent=%d\n", resultMeteringStatus.isused.PCurrent); + printf("\t\tPCurrent=%d\n", resultMeteringStatus.PCurrent.Value);*/ + + } + + + + + /********************************* + * Setup data for meteringReceipt * + *********************************/ + + meteringReceipt.PEVID.arraylen.data=1; + meteringReceipt.PEVID.data[0]=10; + meteringReceipt.isused.PEVID=1; + + meteringReceipt.PEVStatus = powerDelivery.PEVStatus; /* PEV status, taken from sessionSetup */ + + meteringReceipt.TCurrent = 12345; + meteringReceipt.isused.TCurrent = 1; + meteringReceipt.Tariff = Green_charge_tariffIDType; + meteringReceipt.MeterInfo.MeterStatus = 2; + meteringReceipt.MeterInfo.isused.MeterStatus = 1; + + + meteringReceipt.MeterInfo.MeterID.arraylen.data=1; + meteringReceipt.MeterInfo.MeterID.data[0]=3; + meteringReceipt.MeterInfo.isused.MeterID = 1; + + meteringReceipt.MeterInfo.MeterReading.Multiplier = 0; + meteringReceipt.MeterInfo.MeterReading.Unit = A_unitSymbolType; + meteringReceipt.MeterInfo.MeterReading.Value = 500; + meteringReceipt.MeterInfo.isused.MeterReading = 1; + + meteringReceipt.MeterInfo.TMeter =123456789; + meteringReceipt.MeterInfo.isused.TMeter = 1; + + + + /*********************** + * Call meteringReceipt * + ***********************/ + printf("\nPEV: call EVSE meteringReceipt\n"); + + + + if(call_meteringReceipt(&service,&v2gHeader,&meteringReceipt,&resultMeteringReceipt)) + { + printErrorMessage(&service); + } + else + { + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultMeteringReceipt.ResponseCode); + } + + + return 0; + + +} + +static int dc_charging() +{ + + static uint8_t byte_array[MAX_BYTE_SIZE]; /* define MAX_BYTE_SIZE before*/ static uint32_t string_array[MAX_STRING_SIZE]; /* define MAX_STRING_SIZE before*/ @@ -58,11 +357,27 @@ int main_service(int argc, char *argv[]) struct HeaderType v2gHeader; struct SessionSetupReqType sessionSetup; struct SessionSetupResType resultSessionSetup; - /*struct PowerDiscoveryReqType powerDiscovery; - struct PowerDiscoveryResType resultPowerDiscovery; */ + struct ChargeParameterDiscoveryReqType powerDiscovery; + struct ChargeParameterDiscoveryResType resultPowerDiscovery; + struct CableCheckReqType cableCheck; + struct CableCheckResType resultCableCheck; + struct PowerDeliveryReqType powerDelivery; + struct PowerDeliveryResType resultPowerDelivery; + struct PreChargeReqType preCharge; + struct PreChargeResType resultPreCharge; + struct CurrentDemandReqType currentDemand; + struct CurrentDemandResType resultCurrentDemand; + struct WeldingDetectionReqType weldingDetection; + struct WeldingDetectionResType resultWeldingDetection; + struct TerminateChargingReqType terminateCharging; + struct TerminateChargingResType resultTerminateCharging; + + struct FloatingValueType float_type; /* test float type*/ + + /* BINARY memory setup */ bytes_t bytes = { MAX_BYTE_SIZE, byte_array, 0 }; @@ -74,8 +389,6 @@ int main_service(int argc, char *argv[]) transportHeaderOffset = DOIP_HEADER_LENGTH; - printf("+++Start V2G Client / Service Example+++\n\n"); - /******************* * Init V2G Client * *******************/ @@ -83,22 +396,26 @@ int main_service(int argc, char *argv[]) init_v2gServiceClient(&service,bytes,string,inStream,MAX_STREAM_SIZE, outStream, MAX_STREAM_SIZE, transportHeaderOffset); /******************************* - * Setup data for sessionSetup * + * Setup data for sessionSetup * *******************************/ /* setup header information */ v2gHeader.SessionInformation.SessionID.arraylen.data = 0; /* no session id in the initial message -> array length = 0*/ v2gHeader.SessionInformation.ProtocolVersion.data[0]='1'; /* assign protocol version number*/ v2gHeader.SessionInformation.ProtocolVersion.arraylen.data=1; /* array string length =1 of protocol version */ - v2gHeader.SessionInformation.isused.ProtocolVersion = 1; /* important: signalize, protocol version is used */ + v2gHeader.SessionInformation.isused.ProtocolVersion = 1; /* important: optional elements have to be set used (=1) or not used (=0) */ + v2gHeader.SessionInformation.isused.ServiceSessionID = 0; /* service session is not used */ v2gHeader.isused.Notification=0; /* no notification */ /* setup sessionSetup parameter */ - sessionSetup.isused.PEVID=0; /* no PEVID is transported */ - sessionSetup.PEVStatus.ChargerStandby=1; /* charger standby = true */ + sessionSetup.isused.PEVID=1; /* no PEVID is transported */ + sessionSetup.PEVID.arraylen.data=1; + sessionSetup.PEVID.data[0]=10; + sessionSetup.PEVStatus.ChargerStandby=0; /* charger standby = true */ sessionSetup.PEVStatus.ConnectorLocked=0; /* connector locked = false */ + printf("PEV: call EVSE sessionSetup\n"); /********************* @@ -110,24 +427,273 @@ int main_service(int argc, char *argv[]) } else { - /* show result of the answer message of EVSE sessionSetup*/ + /* show result of the answer message of EVSE sessionSetup */ printf("PEV: received response message from EVSE\n"); printf("\tResponseCode=%d\n",resultSessionSetup.ResponseCode); printf("\tEVSEID=%d\n", resultSessionSetup.EVSEID.data[0]); - printf("\tEVSEStatus:\n\t\tConnectorLocked=%d\n",resultSessionSetup.EVSEStatus.ConnectorLocked); - printf("\t\tEVSEStandby=%d\n",resultSessionSetup.EVSEStatus.EVSEStandby); - printf("\t\tFatalError=%d\n",resultSessionSetup.EVSEStatus.FatalError); - printf("\t\tPowerSwitchClosed=%d\n",resultSessionSetup.EVSEStatus.PowerSwitchClosed); - printf("\t\tRCD=%d\n",resultSessionSetup.EVSEStatus.RCD); - printf("\t\tShutDownTime=%d\n",resultSessionSetup.EVSEStatus.ShutDownTime); + printEVSEStatus(&resultSessionSetup.EVSEStatus); printf("\tTCurrent=%d\n",resultSessionSetup.TCurrent); } - printf("\n+++Terminate V2G Client / Service Example+++"); + + /******************************************* + * Setup data for chargeParameterDiscovery * + *******************************************/ + + powerDiscovery.PEVStatus = sessionSetup.PEVStatus; /* PEV status, taken from sessionSetup */ + powerDiscovery.EoC = 4321; + powerDiscovery.ChargingMode = DC_charging_chargingModeType; + + float_type.Multiplier = 2; + float_type.Unit = A_unitSymbolType; + float_type.Value = 700; + + float_type.Multiplier = 0; + float_type.Unit = J_unitSymbolType; + float_type.Value = 100; + + powerDiscovery.EAmount = float_type; + powerDiscovery.PEVMaxPhases = 3; + + float_type.Unit = W_unitSymbolType; + float_type.Value = 600; + powerDiscovery.PEVMaxPower = float_type; + + float_type.Unit = V_unitSymbolType; + float_type.Value = 1000; + powerDiscovery.PEVMaxVoltage = float_type; + float_type.Value = 200; + powerDiscovery.PEVMinVoltage = float_type; + + float_type.Unit = A_unitSymbolType; + float_type.Value = 800; + powerDiscovery.PEVMaxCurrent = float_type; + float_type.Value = 150; + powerDiscovery.PEVMinCurrent = float_type; + + + /********************************* + * Call chargeParameterDiscovery * + *********************************/ + printf("\nPEV: call EVSE chargeParameterDiscovery\n"); + + if(call_chargeParameterDiscovery(&service,&v2gHeader,&powerDiscovery,&resultPowerDiscovery)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPowerDiscovery.ResponseCode); + printEVSEStatus(&resultPowerDiscovery.EVSEStatus); + printf("\tEVSEMaxVoltage=%d\n",resultPowerDiscovery.EVSEMaxVoltage.Value); + printf("\tEVSEMaxCurrent=%d\n",resultPowerDiscovery.EVSEMaxCurrent.Value); + printf("\tEVSEMinCurrent=%d\n",resultPowerDiscovery.EVSEMinCurrent.Value); + printf("\tEVSEMaxPhases=%d\n",resultPowerDiscovery.EVSEMaxPhases); + + /*printf("\tEnergyProvider=%d\n",resultPowerDiscovery.EnergyProvider.data[0]);*/ + + } + + /*********************** + * Call cableCheck * + ***********************/ + printf("\nPEV: call EVSE cableCheck\n"); + + cableCheck.PEVStatus.ChargerStandby = 1; + cableCheck.PEVStatus.ConnectorLocked = 1; + cableCheck.PEVStatus.ReadyToCharge = 1; + + + if(call_cableCheck(&service,&v2gHeader,&cableCheck,&resultCableCheck)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE powerDiscovery*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultCableCheck.ResponseCode); + printEVSEStatus(&resultCableCheck.EVSEStatus); + } + + + /********************************* + * Setup data for powerDelivery * + *********************************/ + + powerDelivery.PEVStatus = cableCheck.PEVStatus; /* PEV status, taken from sessionSetup */ + powerDelivery.isused.Tariff = 0; + /*powerDelivery.Tariff = Green_charge_tariffIDType;*/ + + /*********************** + * Call powerDelivery * + ***********************/ + printf("\nPEV: call EVSE powerDelivery\n"); + + if(call_powerDelivery(&service,&v2gHeader,&powerDelivery,&resultPowerDelivery)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE sessionSetup*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPowerDelivery.ResponseCode); + printEVSEStatus(&resultPowerDelivery.EVSEStatus); + } + + + /*********************** + * Call preCharge * + ***********************/ + printf("\nPEV: call EVSE preCharge\n"); + + preCharge.PEVStatus = cableCheck.PEVStatus; + float_type.Unit = A_unitSymbolType; + float_type.Value = 400; + preCharge.PEVDemandCurrent = float_type; + + float_type.Unit = V_unitSymbolType; + float_type.Value = 700; + preCharge.PEVTargetVoltage = float_type; + float_type.Value = 300; + preCharge.VoltageDifferential = float_type; + + if(call_preCharge(&service,&v2gHeader,&preCharge,&resultPreCharge)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE powerDiscovery*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultPreCharge.ResponseCode); + printEVSEStatus(&resultPreCharge.EVSEStatus); + printf("\tEVSEPresentVoltage=%d\n",resultPreCharge.EVSEPresentVoltage.Value); + } + + /*********************** + * Call currentDemand * + ***********************/ + printf("\nPEV: call EVSE currentDemand\n"); + + currentDemand.PEVStatus = powerDelivery.PEVStatus; + + float_type.Unit = A_unitSymbolType; + float_type.Value = 44; + currentDemand.CurrentDifferential = float_type; + + float_type.Value = 40; + currentDemand.PEVDemandCurrent = float_type; + + float_type.Unit = V_unitSymbolType; + float_type.Value = 300; + currentDemand.VoltageDifferential = float_type; + + float_type.Value = 700; + preCharge.PEVTargetVoltage = float_type; + currentDemand.PEVTargetVoltage = float_type; + + if(call_currentDemand(&service,&v2gHeader,¤tDemand,&resultCurrentDemand)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE powerDiscovery*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultCurrentDemand.ResponseCode); + printEVSEStatus(&resultCurrentDemand.EVSEStatus); + printf("\tEVSEPresentVoltage.Value=%d\n",resultCurrentDemand.EVSEPresentVoltage.Value); + printf("\tEVSEPresentCurrent.Value=%d\n",resultCurrentDemand.EVSEPresentCurrent.Value); + + } + + + + /*********************** + * Call weldingDetection * + ***********************/ + printf("\nPEV: call EVSE weldingDetection\n"); + weldingDetection.PEVStatus = powerDelivery.PEVStatus; + + if(call_weldingDetection(&service,&v2gHeader,&weldingDetection,&resultWeldingDetection)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE powerDiscovery*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultWeldingDetection.ResponseCode); + printEVSEStatus(&resultWeldingDetection.EVSEStatus); + printf("\tEVSEPresentVoltage=%d\n",resultWeldingDetection.EVSEPresentVoltage.Value); + } + + /************************* + * Call terminateCharging* + *************************/ + printf("\nPEV: call EVSE terminateCharging\n"); + terminateCharging.PEVStatus = sessionSetup.PEVStatus; + + if(call_terminateCharging(&service,&v2gHeader,&terminateCharging,&resultTerminateCharging)) + { + printErrorMessage(&service); + } + else + { + + /* show result of the answer message of EVSE powerDiscovery*/ + printf("PEV: received response message from EVSE\n"); + printf("\tResponseCode=%d\n",resultTerminateCharging.ResponseCode); + printEVSEStatus(&resultWeldingDetection.EVSEStatus); + printf("\tEVSEPresentVoltage.Value=%d\n",resultTerminateCharging.EVSEPresentVoltage.Value); + } + return 0; } +int main_service() +{ + printf("+++ Start V2G client / service example for AC charging +++\n\n"); + + ac_charging(); + + printf("\n+++Terminate V2G Client / Service example for AC charging +++\n"); + printf("Please press enter for DC charging!\n"); + fflush(stdout); + getchar(); + + printf("+++ Start V2G client / service example for DC charging +++\n\n"); + + dc_charging(); + + printf("\n+++Terminate V2G client / service example for DC charging +++"); + + return 0; +} + +static void printEVSEStatus(struct EVSEStatusType* status) +{ + printf("\tEVSEStatus:\n\t\tConnectorLocked=%d\n",status->ConnectorLocked); + printf("\t\tEVSEStandby=%d\n",status->EVSEStandby); + printf("\t\tFatalError=%d\n",status->FatalError); + printf("\t\tPowerSwitchClosed=%d\n",status->PowerSwitchClosed); + printf("\t\tRCD=%d\n",status->RCD); + printf("\t\tChargerStandby=%d\n",status->ChargerStandby); + printf("\t\tEVSEMalfunction=%d\n",status->EVSEMalfunction); + printf("\t\tShutDownTime=%d\n",status->ShutDownTime); +} + static void printErrorMessage(struct EXIService* service) { if(service->errorCode==EXI_NON_VALID_MESSAGE) diff --git a/src/test/v2g_server.c b/src/test/v2g_server.c index e566eda..321950b 100644 --- a/src/test/v2g_server.c +++ b/src/test/v2g_server.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/test/v2g_server.h b/src/test/v2g_server.h index d1259b7..60ceca9 100644 --- a/src/test/v2g_server.h +++ b/src/test/v2g_server.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/test/v2g_serviceClientDataTransmitter.c b/src/test/v2g_serviceClientDataTransmitter.c index 5ad1b7d..8b90254 100644 --- a/src/test/v2g_serviceClientDataTransmitter.c +++ b/src/test/v2g_serviceClientDataTransmitter.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/test/v2g_serviceMethods.c b/src/test/v2g_serviceMethods.c index 17e0663..f5a17dc 100644 --- a/src/test/v2g_serviceMethods.c +++ b/src/test/v2g_serviceMethods.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -18,7 +18,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ @@ -31,26 +31,27 @@ int sessionSetup(struct SessionSetupReqType* param, struct SessionSetupResType* result) { - printf("EVSE: sessionSetup called\n" ); printf("\tReceived data:\n"); - printf("\t\t PEVStatus ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); - printf("\t\t PEVStatus ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); /* Prepare data for PEV */ result->ResponseCode = OK_SessionSetup_responseCode_SessionSetupType; - result->EVSEID.data[0]='E'; + result->EVSEID.data[0]=1; result->EVSEID.arraylen.data=1; result->EVSEStatus.ConnectorLocked=0; result->EVSEStatus.EVSEStandby=1; result->EVSEStatus.FatalError=0; result->EVSEStatus.PowerSwitchClosed=1; result->EVSEStatus.RCD=1; - result->EVSEStatus.ShutDownTime=12345678L; - result->TCurrent=12345678L; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.ChargerStandby = 1; + result->EVSEStatus.EVSEMalfunction = 0; + result->TCurrent=12345678; return 0; - } int serviceDiscovery(struct ServiceDiscoveryReqType* param, struct ServiceDiscoveryResType* result) @@ -68,28 +69,309 @@ int paymentDetails(struct PaymentDetailsReqType* param, struct PaymentDetailsRes return 0; } -int powerDiscovery(struct PowerDiscoveryReqType* param, struct PowerDiscoveryResType* result) +int chargeParameterDiscovery(struct ChargeParameterDiscoveryReqType* param, struct ChargeParameterDiscoveryResType* result) { + printf("EVSE: chargeParameterDiscovery called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + if(param->ChargingMode==AC_charging_chargingModeType) + printf("\t\t ChargingMode=AC_charging\n"); + else + printf("\t\t ChargingMode=DC_charging\n"); + + printf("\t\t Eoc=%d\n", param->EoC); + printf("\t\t EAmount=%d\n", param->EAmount.Value); + printf("\t\t PEVMaxPower=%d\n", param->PEVMaxPower.Value); + printf("\t\t PEVMaxPhases=%d\n", param->PEVMaxPhases); + printf("\t\t PEVMaxVoltage=%d\n", param->PEVMaxVoltage.Value); + printf("\t\t PEVMinVoltage=%d\n", param->PEVMinVoltage.Value); + + + if(param->ChargingMode==DC_charging_chargingModeType) + { + printf("\t\t PEVMaxCurrent=%d\n", param->PEVMaxCurrent.Value); + printf("\t\t PEVMinCurrent=%d\n", param->PEVMinCurrent.Value); + } + + result->ResponseCode = 0; + result->EVSEStatus.ConnectorLocked=0; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.PowerSwitchClosed=0; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345; + result->EVSEStatus.ChargerStandby = 1; + result->EVSEStatus.EVSEMalfunction = 0; + result->EVSEMaxVoltage.Multiplier = 0; + result->EVSEMaxVoltage.Unit = V_unitSymbolType; + result->EVSEMaxVoltage.Value = 950; + result->EVSEMaxPhases = 3; + + /* only for DC charging */ + result->EVSEMaxCurrent.Multiplier = 0; + result->EVSEMaxCurrent.Unit = A_unitSymbolType; + result->EVSEMaxCurrent.Value = 10; + result->EVSEMinCurrent.Multiplier = 0; + result->EVSEMinCurrent.Unit = A_unitSymbolType; + result->EVSEMinCurrent.Value = 2; + + + result->isused.EnergyProvider=0; + /*result->EnergyProvider.arraylen.data=1; + result->EnergyProvider.data[0]=11; */ + result->isused.TariffTable = 0; return 0; } int lineLock(struct LineLockReqType* param, struct LineLockResType* result) { + printf("EVSE: lineLock called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + printf("\t\t ReqLockStatus=%d\n", param->ReqLockStatus); + + result->ResponseCode = 0; + result->EVSEStatus.ConnectorLocked=0; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345; + result->EVSEStatus.ChargerStandby = 1; + result->EVSEStatus.EVSEMalfunction = 0; + return 0; } int powerDelivery(struct PowerDeliveryReqType* param, struct PowerDeliveryResType* result) { + printf("EVSE: powerDelivery called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + result->ResponseCode=0; + result->EVSEStatus.ConnectorLocked=0; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345; + result->EVSEStatus.ChargerStandby = 1; + result->EVSEStatus.EVSEMalfunction = 0; + return 0; } int meteringStatus(struct MeteringStatusReqType* param, struct MeteringStatusResType* result) { + printf("EVSE: meteringStatus called\n" ); + + result->ResponseCode=1; + result->EVSEID.data[0]=1; + result->EVSEID.arraylen.data=1; + result->EVSEStatus.ConnectorLocked=1; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.EVSEMalfunction = 0; + result->EVSEStatus.ChargerStandby = 1; + result->TCurrent=12345678; + result->EVSEMaxPower.Multiplier = 2; + result->EVSEMaxPower.Unit = A_unitSymbolType; + result->EVSEMaxPower.Value = 400; + + result->isused.MeterInfo=1; + result->MeterInfo.MeterID.arraylen.data=1; + result->MeterInfo.MeterID.data[0]=2; + result->MeterInfo.MeterReading.Multiplier = 0; + result->MeterInfo.MeterReading.Unit = A_unitSymbolType; + result->MeterInfo.MeterReading.Value = 500; + result->MeterInfo.MeterStatus = 4321; + result->MeterInfo.TMeter =123456789; + result->MeterInfo.isused.MeterID=1; + result->MeterInfo.isused.MeterReading = 1; + result->MeterInfo.isused.MeterStatus=1; + result->MeterInfo.isused.TMeter=1; + + result->isused.PCurrent=1; + result->PCurrent.Value=4321; + return 0; } int meteringReceipt(struct MeteringReceiptReqType* param, struct MeteringReceiptResType* result) { + + printf("EVSE: meteringReceipt called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + printf("\t\t TCurrent=%d\n", param->TCurrent); + printf("\t\t MeterInfo.MeterStatus=%d\n", param->MeterInfo.MeterStatus); + printf("\t\t MeterInfo.MeterID=%d\n", param->MeterInfo.MeterID.data[0]); + printf("\t\t MeterInfo.isused.MeterReading=%d\n", param->MeterInfo.isused.MeterReading); + printf("\t\t MeterReading.Value=%d\n", param->MeterInfo.MeterReading.Value); + printf("\t\t MeterInfo.TMeter=%d\n", param->MeterInfo.TMeter); + if(param->Tariff==Green_charge_tariffIDType) + printf("\t\t Tariff==Green_charge_tariffIDType\n"); + result->ResponseCode = 0; + return 0; } + +int cableCheck(struct CableCheckReqType* param, struct CableCheckResType* result) +{ + printf("EVSE: cableCheck called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + result->EVSEStatus.ConnectorLocked=1; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.EVSEMalfunction = 0; + result->EVSEStatus.ChargerStandby = 1; + + result->ResponseCode = OK_responseCode_CableCheckType; + + return 0; +} + + +int preCharge(struct PreChargeReqType* param, struct PreChargeResType* result) +{ + struct FloatingValueType float_type; + float_type.Multiplier = 0; + float_type.Unit = V_unitSymbolType; + + printf("EVSE: currentDemand called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + printf("\t\t PEVDemandCurrent=%d\n",param->PEVDemandCurrent.Value); + printf("\t\t PEVTargetVoltage=%d\n", param->PEVTargetVoltage.Value); + + result->ResponseCode=OK_responseCode_CurrentDemandType; + result->EVSEStatus.ConnectorLocked=1; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.ChargerStandby=1; + result->EVSEStatus.EVSEMalfunction=0; + result->EVSEStatus.StopCharging=0; + + float_type.Value = 800; + + result->EVSEPresentVoltage = float_type; + + + return 0; + + +} + +int currentDemand(struct CurrentDemandReqType* param, struct CurrentDemandResType* result) +{ + struct FloatingValueType float_type; + float_type.Multiplier = 0; + + printf("EVSE: currentDemand called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + printf("\t\t PEVDemandCurrent=%d\n",param->PEVDemandCurrent.Value); + printf("\t\t PEVTargetVoltage=%d\n", param->PEVTargetVoltage.Value); + + result->EVSEStatus.ConnectorLocked=1; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.ChargerStandby=1; + result->EVSEStatus.EVSEMalfunction=0; + result->EVSEStatus.StopCharging=0; + result->ResponseCode=OK_responseCode_CurrentDemandType; + + float_type.Unit = A_unitSymbolType; + float_type.Value = 40; + result->EVSEPresentCurrent = float_type; + + float_type.Unit = V_unitSymbolType; + float_type.Value = 700; + result->EVSEPresentVoltage = float_type; + + return 0; +} + +int weldingDetection(struct WeldingDetectionReqType* param, struct WeldingDetectionResType* result) +{ + struct FloatingValueType float_type; + float_type.Multiplier = 0; + float_type.Unit = V_unitSymbolType; + float_type.Value = 0; + + printf("EVSE: weldingDetection called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + result->ResponseCode = OK_responseCode_WeldingDetectionType; + + result->EVSEStatus.ConnectorLocked=1; + result->EVSEStatus.EVSEStandby=1; + result->EVSEStatus.FatalError=0; + result->EVSEStatus.PowerSwitchClosed=1; + result->EVSEStatus.RCD=1; + result->EVSEStatus.ShutDownTime=12345678; + result->EVSEStatus.ChargerStandby=1; + result->EVSEStatus.EVSEMalfunction=0; + result->EVSEStatus.StopCharging=0; + + result->EVSEPresentVoltage=float_type; + + return 0; +} + +int terminateCharging(struct TerminateChargingReqType* param, struct TerminateChargingResType* result) +{ + struct FloatingValueType float_type; + float_type.Multiplier = 0; + float_type.Unit = V_unitSymbolType; + float_type.Value =0; + + printf("EVSE: terminateCharging called\n" ); + printf("\tReceived data:\n"); + printf("\t\t PEVStatus:\n\t\t\t ChargerStandby=%d\n",param->PEVStatus.ChargerStandby); + printf("\t\t\t ConnectorLocked=%d\n", param->PEVStatus.ConnectorLocked); + printf("\t\t\t ReadyToCharge=%d\n", param->PEVStatus.ReadyToCharge); + + result->EVSEPresentVoltage = float_type; + result->ResponseCode = OK_responseCode_TerminateChargingType; + + + return 0; + +} diff --git a/src/transport/doIP.c b/src/transport/doIP.c index b977519..12ad8bf 100644 --- a/src/transport/doIP.c +++ b/src/transport/doIP.c @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/ diff --git a/src/transport/doIP.h b/src/transport/doIP.h index 59fb980..c226909 100644 --- a/src/transport/doIP.h +++ b/src/transport/doIP.h @@ -1,6 +1,6 @@ /* - * Copyright (C) 2007-2010 Siemens AG + * Copyright (C) 2007-2011 Siemens AG * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published @@ -19,7 +19,7 @@ /******************************************************************* * * @author Sebastian.Kaebisch.EXT@siemens.com - * @version 0.3.1 + * @version 0.4 * @contact Joerg.Heuer@siemens.com * ********************************************************************/