define.h 124 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944
  1. #ifndef DEFINE_H_
  2. #define DEFINE_H_
  3. /**************************************************************************************/
  4. /*********************************NAND Flash mapping *****************************/
  5. /**************************************************************************************/
  6. /*
  7. sector size 512 KiB
  8. Page size 4096 b
  9. OOB size 224 b
  10. Erase size 524288 b
  11. -------------------------------------------------------------------------------------------------------------------------------
  12. Segment Physical address Size
  13. -------------------------------------------------------------------------------------------------------------------------------
  14. MLO 0x00000000-0x0007FFFF 512 KB
  15. Primary u-boot 0x00080000-0x0017FFFF 1 MB
  16. Environment 0x00180000-0x001FFFFF 512 KB
  17. Secondary u-boot 0x00200000-0x002FFFFF 1 MB
  18. Primary dtb 0x00300000-0x0037FFFF 512 KB
  19. Secondary dtb 0x00380000-0x003FFFFF 512 KB
  20. Primary kernel 0x00400000-0x00DFFFFF 10 MB
  21. Secondary Kernel 0x00E00000-0x017FFFFF 10 MB
  22. Primary root file system 0x03000000-0x05FFFFFF 48 MB
  23. Secondary root file system 0x06000000-0x08FFFFFF 48 MB
  24. Primary user configuration 0x09000000-0x095FFFFF 6 MB
  25. Secondary user configuration 0x09600000-0x09BFFFFF 6 MB
  26. Factory default configuration 0x09C00000-0x0A1FFFFF 6 MB
  27. Storage 0x0A200000-0x7FFFFFFF 1886 MB
  28. */
  29. /**************************************************************************************/
  30. /*********************************System Limitation**********************************/
  31. /**************************************************************************************/
  32. /*Rating outout power and current*/
  33. #define RATED_POWER 25 //kW
  34. #define RATED_CURRENT 350 //Amp, it depend on the capacity of charging connector
  35. /*relevant to Quantity */
  36. #define MAX_PSU_QUANTITY 62
  37. #define CHAdeMO_QUANTITY 1
  38. #define CCS_QUANTITY 1
  39. #define GB_QUANTITY 0
  40. #define AC_QUANTITY 1
  41. #define PSU_QUANTITY 1
  42. #define ONE_CONNECTOR_USE 1
  43. /*SystemLog message*/
  44. #define SystemLogMessage //for engineer to do analysis
  45. /**************************************************************************************/
  46. /**************************share memory key information***************************/
  47. /**************************************************************************************/
  48. #define ShmSysConfigAndInfoKey 1001
  49. #define ShmPsuKey 1002
  50. #define ShmCHAdeMOCommKey 1003
  51. #define ShmCcsCommKey 1004
  52. #define ShmStatusCodeKey 1005
  53. #define ShmPrimaryMcuKey 1006
  54. #define ShmFanBdKey 1007
  55. #define ShmRelayBdKey 1008
  56. #define ShmOcppModuleKey 1009
  57. /**************************************************************************************/
  58. /****structure SysConfigData => shall store the data to NAND flash****************/
  59. /****structure SysInfoData => shall NOT store the data to NAND flash***************/
  60. /****according to System Configuration and Information Table.xlsx Rev.0.2 *******/
  61. /**************************************************************************************/
  62. struct EthConfigData
  63. {
  64. unsigned char EthDhcpClient; //0: enable,1: disable
  65. unsigned char EthMacAddress[18]; //default: Null
  66. unsigned char EthIpAddress[16]; //Eth0 default:192.168.0.10 ,Eth1 default:192.168.1.10
  67. unsigned char EthSubmaskAddress[16]; //Eth0 default:255.255.255.0 ,Eth1 default:255.255.255.0
  68. unsigned char EthGatewayAddress[16]; //Eth0 default:192.168.0.254 ,Eth1 default:192.168.1.254
  69. };
  70. struct WifiConfigData
  71. {
  72. unsigned char WifiMode; //0: disable, 1: Infrastructure client, 2: Infrastructure server, 3: Ad-Hoc
  73. unsigned char WifiSsid[256]; //default: Null
  74. unsigned char WifiPassword[256]; //default: Null
  75. int WifiRssi; //dbm
  76. unsigned char WifiDhcpServer; //0: enable, 1: disable
  77. unsigned char WifiDhcpClient; //0: enable, 1: disable
  78. unsigned char WifiMacAddress[18]; //default: Null
  79. unsigned char WifiIpAddress[16]; //default:192.168.2.10
  80. unsigned char WifiSubmaskAddress[16]; //default:255.255.255.0
  81. unsigned char WifiGatewayAddress[16]; //default:192.168.2.254
  82. unsigned char WifiNetworkConn; //0: disconnected, 1: connected
  83. };
  84. struct TeleConfigData
  85. {
  86. unsigned char TelcomModelName[64]; //default: Null
  87. unsigned char TelcomSoftwareVer[64]; //default: Null
  88. unsigned char TelcomApn[256]; //default: Null
  89. int TelcomRssi; //dbm
  90. unsigned char TelcomChapPapId[256]; //default: Null
  91. unsigned char TelcomChapPapPwd[256]; //default: Null
  92. unsigned char TelcomModemImei[16]; //default: Null
  93. unsigned char TelcomSimImsi[16]; //default: Null
  94. unsigned char TelcomSimIccid[20]; //default: Null
  95. unsigned char TelcomSimStatus; //0: no SIM card is found, 1: valid SIM card, 2: invalid SIM card
  96. unsigned char TelcomModemMode; //0: No services, 1: CDMA, 2: GSM/GPRS, 3: WCDMA, 4: GSM/WCDMA, 5: TD_SCDMA mode, 6: Unknow
  97. unsigned char TelcomIpAddress[16]; //default: Null
  98. unsigned char TelcomNetworkConn; //0: disconnected, 1: connected
  99. };
  100. struct BtConfigData
  101. {
  102. unsigned char LoginCentralID[64]; //default: Null
  103. unsigned char isLogin; //0: Central device non-login 1: Central device login
  104. unsigned char isRequestStart; //0: no action 1: request start charging
  105. unsigned char isRequestStop; //0: no action 1: request stop charging
  106. };
  107. struct SysConfigData
  108. {
  109. /**************System***************/
  110. unsigned char ModelName[64]; //charger model name
  111. unsigned char SerialNumber[64]; //charger system serial number
  112. unsigned char SystemId[128]; //charger system ID
  113. unsigned char SystemDateTime[32]; //charger system date and time
  114. unsigned char AcPhaseCount; //AC EVSE power phase quantity, 1: One phase 3: Three phase
  115. unsigned char AuthorisationMode; //0: Phihong RFID tag, 1: OCPP backend, 2: Phihong backend, 3: free mode
  116. unsigned char DefaultLanguage; //
  117. unsigned char RfidCardNumEndian; //0: little endian, 1: big endian
  118. unsigned short AcPlugInTimes; //0~65535
  119. unsigned short GbPlugInTimes; //0~65535
  120. unsigned short Ccs1PlugInTime; //0~65535
  121. unsigned short Ccs2PlugInTimes; //0~65535
  122. unsigned short ChademoPlugInTimes; //0~65535
  123. /**************Charging***************/
  124. unsigned short MaxChargingEnergy; //0: no limit, 1 ~ 65535 kWh
  125. unsigned short MaxChargingPower; //0: rating value, 1 ~ RATING_POWER kW"
  126. unsigned short MaxChargingCurrent; //0: rating value, 1 ~ RATING_CURRENT amp"
  127. unsigned short MaxChargingDuration; //0: no limit, 1 ~ 65535 minutes
  128. unsigned char PhaseLossPolicy; //0: charging, 1: stop charging
  129. unsigned char LocalWhiteCard[10][32]; //Max. card quantity is 10
  130. unsigned char UserId[32]; //the user use this ID to trigger charging event, it can be RFID card number, OCPP IdTag, etc.
  131. /**************Network***************/
  132. unsigned char FtpServer[32]; //the ftp server for Phihong server to do data transimission
  133. struct EthConfigData Eth0Interface;
  134. struct EthConfigData Eth1Interface;
  135. struct WifiConfigData AthInterface;
  136. struct TeleConfigData TelecomInterface;
  137. struct BtConfigData Bluetooth;
  138. /**************Backend***************/
  139. unsigned int BackendConnTimeout; //default : 300s
  140. unsigned char OfflinePolicy; //0: local list, 1: Phihong RFID tag, 2: free charging, 3: no charging
  141. unsigned short OfflineMaxChargeEnergy; //0: same as MaxChargingEnergy, 1 ~ 65535 kWh
  142. unsigned short OfflineMaxChargeDuration; //0: same as MaxChargeDuration, 1 ~ 65535 minutes
  143. unsigned char OcppServerURL[512]; //http: non-secure OCPP 1.5-S, https: secure OCPP 1.5-S, ws: non-secure OCPP 1.6-J, wss: secure OCPP 1.6-J"
  144. unsigned char ChargeBoxId[128];
  145. unsigned int Checksum; //4 bytes checksum
  146. };
  147. struct ChargingInfoData
  148. {
  149. unsigned char Index;
  150. unsigned char Type; // 0 : Chademo, 1 : CCS, 2: GB
  151. unsigned char type_index;
  152. unsigned char SystemStatus; //0: Booting, 1: idle, 2: authorizing, 3: preparing, 4: charging, 5: terminating, 6: alarm, 7: fault
  153. unsigned char PreviousSystemStatus; // 0: Booting, 1: idle, 2: authorizing, 3: preparing, 4: charging, 5: terminating, 6: alarm, 7: fault
  154. unsigned char CardNumber[32];
  155. float MaximumChargingVoltage; //0~6553.5 volt
  156. float AvailableChargingCurrent; //0~6553.5 amp
  157. float AvailableChargingPower; //0~6553.5 kW
  158. float PresentChargingVoltage; //0~6553.5 volt
  159. float PresentChargingCurrent; //0~6553.5 amp
  160. float PresentChargingPower; //0~6553.5 kW
  161. float PresentChargedEnergy; //0~6553.5 kWh
  162. float AcChargingVoltage[3]; // 0~6553.5 volt for AC EVSE
  163. float AcChargingCurrent[3]; // 0~6553.5 amp for EVSE
  164. int PresentChargedDuration; // second
  165. int RemainChargingDuration; // second
  166. float EvBatteryMaxVoltage; // 0~6553.5 volt
  167. float EvBatterytargetVoltage; // 0~6553.5 volt
  168. float EvBatterytargetCurrent; //102.3 0~200(A) (unit:1A)
  169. int EvBatterySoc; // 0~100%
  170. unsigned char ConnectorPlugIn; //0: unplug, 1: Plug-in
  171. unsigned char GunLocked; //0: unlocked 1: locked
  172. float PilotVoltage;
  173. unsigned char PilotState; //1:state A, 2:State B1, 3:State B2, 4:State C, 5:State D, 6:State E, 7:State F, 8: Pilot error
  174. unsigned char PilotDuty; // 0~100%
  175. unsigned char StartUserId[32]; // This ID is trigger start charging event user by RFID、back-end、BLE.
  176. unsigned char StartDateTime[32]; // Charging cycle start date time
  177. unsigned char StoptDateTime[32]; // Charging cycle stop date time
  178. unsigned char StartMethod; // 0:Manual, 1:RFID, 2:Back-end, 3:BLE
  179. // Connector Temp
  180. unsigned char ConnectorTemp; //0x00: -60¢XC ~ 0xFE: 194
  181. // Charging Status
  182. unsigned char ChargingStatus; // for gfd result => 0x00 : None, 0x01 : Can Start Charging, 0x02 : Stop Charging
  183. float OutputEnergy; // output energy by per charging
  184. unsigned char RelayK1K2Status; // 0x00 : open, 0x01 : close
  185. int TimeoutPid;
  186. unsigned char MaxChargeEnable;
  187. };
  188. struct SysInfoData
  189. {
  190. /**************System***************/
  191. unsigned char BootingStatus; // 0 : booting, 1 : Initializing Complete.
  192. unsigned char FactoryConfiguration; //0: normal, 1: trigger, charger will return the configuration to factory default if trigger
  193. float InputVoltageR; //0~655.35 volt
  194. float InputVoltageS; //0~655.35 volt
  195. float InputVoltageT; //0~655.35 volt
  196. unsigned int SystemFanRotaSpeed; //0 ~ 65535 RPM
  197. unsigned int PsuFanRotaSpeed; //0 ~ 65535 RPM
  198. unsigned char AuxPower5V; //0 ~ 255 volt
  199. unsigned char AuxPower12V; //0 ~ 255 volt
  200. unsigned char AuxPower24V; //0 ~ 255 volt
  201. unsigned char AuxPower48V; //0 ~ 255 volt
  202. unsigned char CsuHwRev[32]; //CSU board hardware version
  203. unsigned char CsuBootLoadFwRev[32]; //CSU board bootloader firmware version
  204. unsigned char CsuKernelFwRev[32]; //CSU board OS kernel firmware version
  205. unsigned char CsuRootFsFwRev[32]; //CSU board root file system firmware version
  206. unsigned char CsuPrimFwRev[32]; //CSU board root file system firmware version
  207. unsigned char LcmHwRev[32]; //LCM module hardware version
  208. unsigned char LcmFwRev[32]; //LCM module firmware version
  209. unsigned char PsuHwRev[32]; //PSU hardware version
  210. unsigned char PsuPrimFwRev[32]; //PSU primary firmware version
  211. unsigned char PsuSecFwRev[32]; //PSU secondary firmware version
  212. unsigned char AuxPwrHwRev[32]; //Aux. power module hardware version
  213. unsigned char AuxPwrFwRev[32]; //Aux. power module firmware version
  214. unsigned char FanModuleHwRev[32]; //Fan module hardware version
  215. unsigned char FanModuleFwRev[32]; //Fan module firmware version
  216. unsigned char RelayModuleHwRev[32]; //Relay control module hardware version
  217. unsigned char RelayModuleFwRev[32]; //Relay control module firmware version
  218. unsigned char TelcomModemFwRev[32]; //the 3G/4G modem firmware version
  219. int SystemAmbientTemp; // -40 ~ 215 degree C
  220. int SystemCriticalTemp; // -40 ~ 215 degree C
  221. int CcsConnectorTemp; // -40 ~ 215 degree C
  222. int PsuAmbientTemp; // -40 ~ 215 degree C
  223. /**************Charging***************/
  224. struct ChargingInfoData ChademoChargingData[CHAdeMO_QUANTITY];
  225. struct ChargingInfoData CcsChargingData[CCS_QUANTITY];
  226. struct ChargingInfoData GbChargingData[GB_QUANTITY];
  227. struct ChargingInfoData AcChargingData[AC_QUANTITY];
  228. unsigned char CurGunSelected;
  229. /**************Network***************/
  230. unsigned char InternetConn; //0: disconnected, 1: connected
  231. /**************Backend***************/
  232. unsigned char OcppConnStatus; //0: disconnected, 1: connected
  233. /**************Alston***************/
  234. unsigned char WaitForPlugit; //0: none scan, 1: scanning
  235. unsigned char PageIndex; //0 : Initialize
  236. //1 : idle
  237. //4 : Authorizing
  238. //5 : Authorizing complete
  239. //6 : Authorizing fail
  240. //7 : Wait for Plug
  241. //8 : Pre-charge
  242. //9 : Charging
  243. unsigned char AcContactorStatus; //0 : disconnected, 1 : connected
  244. unsigned char SelfTestSeq; //
  245. unsigned char ReAssignedFlag; // 0 : none, other : gun number.
  246. unsigned char FirmwareUpdate; // 0 : none, 1 : update.
  247. };
  248. struct WARNING_CODE_INFO
  249. {
  250. unsigned char WarningCount;
  251. unsigned char PageIndex;
  252. unsigned char WarningCode[10][7];
  253. };
  254. struct SysConfigAndInfo
  255. {
  256. struct SysConfigData SysConfig;
  257. struct SysInfoData SysInfo;
  258. struct WARNING_CODE_INFO SysWarningInfo;
  259. };
  260. /**************************************************************************************/
  261. /**************************Alarm Share memory**************************************/
  262. /***************************************************************************************
  263. Status Code A B C D E F
  264. 0: Issue 1: From EVSE 1: Fault (unrecoverable) 001 ~ 999 serial number
  265. e.g., hardware broken, system latch
  266. 1: Recovered 2: From EV 2: Alarm (recoverable)
  267. e.g., OTP, OVP
  268. 3: From Backend 3: Information
  269. e.g., swipe card to stop charging
  270. according to XXX.Revxx
  271. ***************************************************************************************/
  272. /**************************************************************************************/
  273. char FaultStatusCode[32][6]=
  274. {
  275. "011001", //CHAdeMO output fuse blew
  276. "011002", //CCS output fuse blew
  277. "011003", //GB output fuse blew
  278. "011004", //RCD/CCID self-test fail
  279. "011005", //AC input contactor 1 welding
  280. "011006", //AC input contactor 1 driving fault
  281. "011007", //AC input contactor 2 welding
  282. "011008", //AC input contactor 2 driving fault
  283. "011009", //AC output relay welding
  284. "011010", //AC output relay driving fault
  285. "011011", //CHAdeMO output relay welding
  286. "011012", //CHAdeMO output relay driving fault
  287. "011013", //CCS output relay welding
  288. "011014", //CCS output relay driving fault
  289. "011015", //GB output relay welding
  290. "011016", //GB output relay driving fault
  291. "011017", //AC connector temperature sensor broken
  292. "011018", //CHAdeMO connector temperature sensor broken
  293. "011019", //CCS connector temperature sensor broken
  294. "011020", //GB connector temperature sensor broken
  295. "011021", //WiFi module broken
  296. "011022", //3G/4G module broken
  297. "011023", //Aux. power module broken
  298. "011024", //Relay control module /smart box broken
  299. "011025", //CHAdeMO connector lock fail
  300. "011026", //GB connector lock fail
  301. "011027", //AC connector lock fail
  302. "011028", //CHAdeMO module broken
  303. "011029", //CCS module broken
  304. "011030", //GBT module broken
  305. "011031", //PSU module broken
  306. "011032" //Reserved
  307. };
  308. struct FaultCodeData
  309. {
  310. unsigned char PreviousFaultVal[4];
  311. union
  312. {
  313. unsigned char FaultVal[4];
  314. struct
  315. {
  316. //FaultVal[0]
  317. unsigned char ChademoOutputFuseBlew:1; //bit 0
  318. unsigned char CcsOutputFuseBlew:1; //bit 1
  319. unsigned char GbOutputFuseBlew:1; //bit 2
  320. unsigned char RcdSelfTestFail:1; //bit 3
  321. unsigned char AcInputContactor1Welding:1; //bit 4
  322. unsigned char AcInputContactor1DrivingFault:1; //bit 5
  323. unsigned char AcInputContactor2Welding:1; //bit 6
  324. unsigned char AcInputContactor2DrivingFault:1; //bit 7
  325. //FaultVal[1]
  326. unsigned char AcOutputRelayWelding:1; //bit 0
  327. unsigned char AcOutputRelayDrivingFault:1; //bit 1
  328. unsigned char ChademoOutputRelayWelding:1; //bit 2
  329. unsigned char ChademoOutputRelayDrivingFault:1; //bit 3
  330. unsigned char CcsOutputRelayWelding:1; //bit 4
  331. unsigned char CcsOutputRelayDrivingFault:1; //bit 5
  332. unsigned char GbOutputRelayWelding:1; //bit 6
  333. unsigned char GbOutputRelayDrivingFault:1; //bit 7
  334. //FaultVal[2]
  335. unsigned char AcConnectorTempSensorBroken:1; //bit 0
  336. unsigned char ChademoConnectorTempSensorBroken:1; //bit 1
  337. unsigned char CcsConnectorTempSensorBroken:1; //bit 2
  338. unsigned char GbConnectorTempSensorBroken:1; //bit 3
  339. unsigned char WiFiModuleBroken:1; //bit 4
  340. unsigned char Telecom4GModuleBroken:1; //bit 5
  341. unsigned char AuxPowerModuleBroken:1; //bit 6
  342. unsigned char RelayControlModuleBroken :1; //bit 7
  343. //FaultVal[3]
  344. unsigned char ChademoConnectorLockFail:1; //bit 0
  345. unsigned char GbConnectorLockFail:1; //bit 1
  346. unsigned char AcConnectorLockFail:1; //bit 2
  347. unsigned char ChademoModuleBroken:1; //bit 3
  348. unsigned char CcsModuleBroken:1; //bit 4
  349. unsigned char GbModuleBroken:1; //bit 5
  350. unsigned char PsuModuleBroken:1; //bit 6
  351. unsigned char :1; //bit 7 reserved
  352. }bits;
  353. }FaultEvents;
  354. };
  355. char AlarmStatusCode[64][6]=
  356. {
  357. "012200", //System L1 input OVP
  358. "012201", //System L2 input OVP
  359. "012202", //System L3 input OVP
  360. "012203", //System L1 input UVP
  361. "012204", //System L2 input UVP
  362. "012205", //System L3 input UVP
  363. "012206", //PSU L1 input OVP
  364. "012207", //PSU L2 input OVP
  365. "012208", //PSU L3 input OVP
  366. "012209", //PSU L1 input UVP
  367. "012210", //PSU L2 input UVP
  368. "012211", //PSU L3 input UVP
  369. "012212", //System L1 input drop
  370. "012213", //System L2 input drop
  371. "012214", //System L3 input drop
  372. "012215", //System AC output OVP
  373. "012216", //System AC output OCP
  374. "012217", //System CHAdeMO output OVP
  375. "012218", //System CHAdeMO output OCP
  376. "012219", //System CCS output OVP
  377. "012220", //System CCS output OCP
  378. "012221", //System GB output OVP
  379. "012222", //System GB output OCP
  380. "012223", //System ambient/inlet OTP
  381. "012224", //System critical point OTP
  382. "012225", //PSU ambient/inlet OTP
  383. "012226", //PSU critical point OTP
  384. "012227", //Aux. power module OTP
  385. "012228", //Relay board/smart box OTP
  386. "012229", //CHAdeMO connector OTP
  387. "012230", //CCS connector OTP
  388. "012231", //GB connector OTP
  389. "012232", //AC connector OTP
  390. "012233", //RCD/CCID trip
  391. "012234", //CHAdeMO GFD trip
  392. "012235", //CCS GFD trip
  393. "012236", //GB GFD trip
  394. "012237", //SPD trip
  395. "012238", //Main power breaker trip
  396. "012239", //Aux. power breaker trip
  397. "012240", //PSU communication fail
  398. "012241", //WiFi module communication fail
  399. "012242", //3G/4G module communication fail
  400. "012243", //RFID module communication fail
  401. "012244", //Bluetooth module communication fail
  402. "012245", //LCM module communication fail
  403. "012246", //Aux. power module communication fail
  404. "012247", //Relay control boaed/smart box communication fail
  405. "012248", //CCS module communication fail
  406. "012249", //CHAdeMO module communication fail
  407. "012250", //GBT module communication fail
  408. "012251", //Emergency stop
  409. "012252", //Door open
  410. "012253", //System fan decay
  411. "012254", //Fail to create share memory
  412. "012255", //CSU initialization failed
  413. "012256", //AC Ground Fault
  414. "012257", //MCU self-test Fault
  415. "012258", //Relay self-test Fault
  416. "012259", //CHAdeMO groundfault detection timeout (GFD)
  417. "012260", //CCS groundfault detection timeout (GFD)
  418. "012261", //GB groundfault detection timeout (GFD)
  419. "012262", //Reserved
  420. "012263" //Reserved
  421. };
  422. struct AlarmCodeData
  423. {
  424. unsigned char PreviousAlarmVal[8];
  425. union
  426. {
  427. unsigned char AlarmVal[8];
  428. struct
  429. {
  430. //AlarmVal[0]
  431. unsigned char SystemL1InputOVP:1; //bit 0
  432. unsigned char SystemL2InputOVP:1; //bit 1
  433. unsigned char SystemL3InputOVP:1; //bit 2
  434. unsigned char SystemL1InputUVP:1; //bit 3
  435. unsigned char SystemL2InputUVP:1; //bit 4
  436. unsigned char SystemL3InputUVP:1; //bit 5
  437. unsigned char PsuL1InputOVP:1; //bit 6
  438. unsigned char PsuL2InputOVP:1; //bit 7
  439. //AlarmVal[1]
  440. unsigned char PsuL3InputOVP:1; //bit 0
  441. unsigned char PsuL1InputUVP:1; //bit 1
  442. unsigned char PsuL2InputUVP:1; //bit 2
  443. unsigned char PsuL3InputUVP :1; //bit 3
  444. unsigned char SystemL1InputDrop:1; //bit 4
  445. unsigned char SystemL2InputDrop:1; //bit 5
  446. unsigned char SystemL3InputDrop:1; //bit 6
  447. unsigned char SystemAcOutputOVP:1; //bit 7
  448. //AlarmVal[2]
  449. unsigned char SystemAcOutputOCP:1; //bit 0
  450. unsigned char SystemChademoOutputOVP:1; //bit 1
  451. unsigned char SystemChademoOutputOCP:1; //bit 2
  452. unsigned char SystemCcsOutputOVP:1; //bit 3
  453. unsigned char SystemCcsOutputOCP:1; //bit 4
  454. unsigned char SystemGbOutputOVP:1; //bit 5
  455. unsigned char SystemGbOutputOCP:1; //bit 6
  456. unsigned char SystemAmbientOTP :1; //bit 7
  457. //AlarmVal[3]
  458. unsigned char SystemCriticalPointOTP:1; //bit 0
  459. unsigned char PsuAmbientOTP:1; //bit 1
  460. unsigned char PsuCriticalPointOTP:1; //bit 2
  461. unsigned char AuxPowerModuleOTP:1; //bit 3
  462. unsigned char RelayBoardOTP:1; //bit 4
  463. unsigned char ChademoConnectorOTP:1; //bit 5
  464. unsigned char CcsConnectorOTP:1; //bit 6
  465. unsigned char GbConnectorOTP:1; //bit 7
  466. //AlarmVal[4]
  467. unsigned char AcConnectorOTP:1; //bit 0
  468. unsigned char RcdTrip:1; //bit 1
  469. unsigned char ChademoGfdTrip:1; //bit 2
  470. unsigned char CcsGfdTrip:1; //bit 3
  471. unsigned char GbGfdTrip:1; //bit 4
  472. unsigned char SpdTrip:1; //bit 5
  473. unsigned char MainPowerBreakerTrip:1; //bit 6
  474. unsigned char AuxPowerBreakerTrip:1; //bit 7
  475. //AlarmVal[5]
  476. unsigned char PsuCommunicationFail:1; //bit 0
  477. unsigned char WiFiModuleCommFail:1; //bit 1
  478. unsigned char Telecom4GModuleCommFail:1; //bit 2
  479. unsigned char RfidModuleCommFail:1; //bit 3
  480. unsigned char BluetoothModuleCommFail:1; //bit 4
  481. unsigned char LcmModuleCommFail:1; //bit 5
  482. unsigned char AuxPowerModuleCommFail:1; //bit 6
  483. unsigned char RelayBoardCommFail:1; //bit 7
  484. //AlarmVal[6]
  485. unsigned char CcsModuleCommFail:1; //bit 0
  486. unsigned char ChademoModuleCommFail:1; //bit 1
  487. unsigned char GbModuleCommFail:1; //bit 2
  488. unsigned char EmergencyStopTrip:1; //bit 3
  489. unsigned char DoorOpen:1; //bit 4
  490. unsigned char SystemFanDecay:1; //bit 5
  491. unsigned char FailToCreateShareMemory:1; //bit 6
  492. unsigned char CsuInitFailed:1; //bit 7
  493. //AlarmVal[7]
  494. unsigned char AcGroundfaultFail:1; //bit 0
  495. unsigned char McuSelftestFail:1; //bit 1
  496. unsigned char RelaySelftestFail:1; //bit 2
  497. unsigned char ChademoGroundfaultTimeout:1; //bit 3
  498. unsigned char CcsGroundfaultTimeout:1; //bit 4
  499. unsigned char GbGroundfaultTimeout:1; //bit 5
  500. unsigned char :1; //bit 6
  501. unsigned char :1; //bit 7
  502. }bits;
  503. }AlarmEvents;
  504. };
  505. char InfoStatusCode[128][6]=
  506. {
  507. //Information comes from EVSE
  508. "013600", //Normal stop charging by user
  509. "013601", //Charging Time's up
  510. "013602", //Replace system air filter
  511. "013603", //Reach to CHAdeMO max. plugging times.
  512. "013604", //Reach to CCS max. plugging times.
  513. "013605", //Reach to GB max. plugging times.
  514. "013606", //Reach to AC max. plugging times.
  515. "013607", //CSU fimrware update fail
  516. "013608", //CHAdeMO Module fimrware update fail
  517. "013609", //CCS Module fimrware update fail
  518. "013610", //GB Module fimrware update fail
  519. "013611", //Aux. power module fimrware update fail
  520. "013612", //Relay control module fimrware update fail
  521. "013613", //LCM module fimrware update fail
  522. "013614", //Bluetooth module fimrware update fail
  523. "013615", //WiFi module fimrware update fail
  524. "013616", //3G/4G module fimrware update fail
  525. "013617", //SMR fimrware update fail
  526. "013618", //RFID module fimrware update fail
  527. "013619", //configured by USB flash drive
  528. "013620", //configured by backend
  529. "013621", //configured by webpage
  530. "013622", //disconnected from Internet through Ethernet
  531. "013623", //disconnected from Internet through WiFi
  532. "013624", //disconnected from Internet through 3G/4G
  533. "013625", //disconnected from AP through WiFi
  534. "013626", //disconnected from APN through 3G/4G
  535. "013627", //Reserved
  536. "013628", //Reserved
  537. "013629", //Reserved
  538. "013630", //Reserved
  539. "013631", //Reserved
  540. //Information comes from EV
  541. "023700", //CHAdeMO EV communication Fail
  542. "023701", //CCS EV communication Fail
  543. "023702", //GB EV communication Fail
  544. "023703", //AC: pilot fault
  545. "023704", //CHAdeMO: battery malfunction
  546. "023705", //CHAdeMO: no charging permission
  547. "023706", //CHAdeMO: battery incompatibility
  548. "023707", //CHAdeMO: battery OVP
  549. "023708", //CHAdeMO: battery UVP
  550. "023709", //CHAdeMO: battery OTP
  551. "023710", //CHAdeMO: battery current difference
  552. "023711", //CHAdeMO: battery voltage difference
  553. "023712", //CHAdeMO: shift position
  554. "023713", //CHAdeMO: battery other fault
  555. "023714", //CHAdeMO: charging system error
  556. "023715", //CHAdeMO: EV normal stop
  557. "023716", //CHAdeMO: connector temperature sensor broken
  558. "023717", //CHAdeMO: connector lock fail
  559. "023718", //CHAdeMO: D1 ON No Receive
  560. "023719", //CHAdeMO: BMS K to J Timeout
  561. "023720", //CHAdeMO: BMS Charge Allow Timeout
  562. "023721", //CHAdeMO: Wait GroundFault Timeout
  563. "023722", //CHAdeMO: BMS EV Relay Timeout
  564. "023723", //CHAdeMO: BMS Request Current Timeout
  565. "023724", //CHAdeMO: BMS K to J OFF Timeout
  566. "023725", //CHAdeMO: BMS EV Relay OFF Timeout
  567. "023726", //CHAdeMO: ADC More Than 10V
  568. "023727", //CHAdeMO: ADC More Than 20V
  569. "023728", //CHAdeMO: BMS Charge Before Stop
  570. "023729", //CHAdeMO: Charger Get Normal Stop
  571. "023730", //CHAdeMO: Charger Get Emergency Stop
  572. "023731", //CHAdeMO: Isolation Result Fail
  573. "023732", //CHAdeMO: Miss Link With MotherBoard
  574. "023733", //CHAdeMO: Output Voltage More Than Limit
  575. "023734", //CHAdeMO: Request Current More Than Limit
  576. "023735", //CHAdeMO: Re Cap BMS Eqr Current Exceed
  577. "023736", //CHAdeMO: Charge Remain Count Down
  578. //Information comes from Backend
  579. "033900", //disconnected from backend through Ethernet
  580. "033901", //disconnected from backend through WiFi
  581. "033902", //disconnected from backend through 3G/4G
  582. "033903", //Remote start charging by backend
  583. "033904", //Remote stop charging by backend
  584. "033905", //Remote reset by backend
  585. "033906", //Reserved
  586. "033907", //Reserved
  587. };
  588. struct InfoCodeData
  589. {
  590. unsigned char PreviousInfoVal[10];
  591. union
  592. {
  593. unsigned char InfoVal[10];
  594. struct
  595. {
  596. //InfoVal[0]
  597. unsigned char NormalStopChargingByUser:1; //bit 0
  598. unsigned char ChargingTimesUp:1; //bit 1
  599. unsigned char ReplaceSystemAirFilter:1; //bit 2
  600. unsigned char ReachChademoMaxPluggingTimes:1; //bit 3
  601. unsigned char ReachCcsMaxPluggingTimes:1; //bit 4
  602. unsigned char ReachGbMaxPluggingTimes:1; //bit 5
  603. unsigned char ReachAcMaxPluggingTimes:1; //bit 6
  604. unsigned char CsuFimrwareUpdateFail:1; //bit 7
  605. //InfoVal[1]
  606. unsigned char ChademoModuleFimrwareUpdateFail:1; //bit 0
  607. unsigned char CcsModuleFimrwareUpdateFail:1; //bit 1
  608. unsigned char GbModuleFimrwareUpdateFail:1; //bit 2
  609. unsigned char AuxPowerModuleFimrwareUpdateFail:1; //bit 3
  610. unsigned char RelayBoardFimrwareUpdateFail:1; //bit 4
  611. unsigned char LcmModuleFimrwareUpdateFail:1; //bit 5
  612. unsigned char BluetoothModuleFimrwareUpdateFail:1; //bit 6
  613. unsigned char WiFiModuleFimrwareUpdateFail:1; //bit 7
  614. //InfoVal[2]
  615. unsigned char Telocom4GModuleFimrwareUpdateFail:1; //bit 0
  616. unsigned char PsuFimrwareUpdateFail:1; //bit 1
  617. unsigned char RfidModuleFimrwareUpdateFail:1; //bit 2
  618. unsigned char ConfiguredByUsbFlashDrive:1; //bit 3
  619. unsigned char ConfiguredByBackend:1; //bit 4
  620. unsigned char ConfiguredByWebpage:1; //bit 5
  621. unsigned char InternetDisconnectViaEthernet:1; //bit 6
  622. unsigned char InternetDisconnectViaWiFi :1; //bit 7
  623. //InfoVal[3]
  624. unsigned char InternetDisconnectVia4Gi:1; //bit 0
  625. unsigned char ApDisconnectViaWiFi:1; //bit 1
  626. unsigned char ApnDisconnectVia4Gi:1; //bit 2
  627. unsigned char :5; //bit 3~7 reserved
  628. //InfoVal[4]
  629. unsigned char ChademoEvCommFail:1; //bit 0
  630. unsigned char CcsEvCommFail:1; //bit 1
  631. unsigned char GbEvCommFail:1; //bit 2
  632. unsigned char PilotFault:1; //bit 3
  633. unsigned char ChademoBatteryMalfun:1; //bit 4
  634. unsigned char ChademoNoPermission:1; //bit 5
  635. unsigned char ChademoBatteryIncompatibility:1; //bit 6
  636. unsigned char ChademoBatteryOVP:1; //bit 7
  637. //InfoVal[5]
  638. unsigned char ChademoBatteryUVP:1; //bit 0
  639. unsigned char ChademoBatteryOTP:1; //bit 1
  640. unsigned char ChademoBatteryCurrentDiff:1; //bit 2
  641. unsigned char ChademoBatteryVoltageDiff:1; //bit 3
  642. unsigned char ChademoShiftPosition:1; //bit 4
  643. unsigned char ChademoBatteryOtherFault:1; //bit 5
  644. unsigned char ChademoChargingSystemError:1; //bit 6
  645. unsigned char ChademoEvNormalStop:1; //bit 7
  646. //InfoVal[6]
  647. unsigned char ChademoTempSensorBroken:1; //bit 0
  648. unsigned char ChademoConnectorLockFail:1; //bit 1
  649. unsigned char ChademoD1OnNoReceive:1; //bit 2
  650. unsigned char ChademoBmsKtoJTimeout:1; //bit 3
  651. unsigned char ChademoBmsChargeAllowTimeout:1; //bit 4
  652. unsigned char ChademoWaitGfdTimeout:1; //bit 5
  653. unsigned char ChademoBmsEvRelayTimeout:1; //bit 6
  654. unsigned char ChademoBmsReqCurrentTimeout:1; //bit 7
  655. //InfoVal[7]
  656. unsigned char ChademoBmsKtoJOffTimeout :1; //bit 0
  657. unsigned char ChademoBmsEvRelayOffTimeout :1; //bit 1
  658. unsigned char ChademoAdcMoreThan10V :1; //bit 2
  659. unsigned char ChademoAdcMoreThan20V :1; //bit 3
  660. unsigned char ChademoBmsChargeBeforeStop :1; //bit 4
  661. unsigned char ChademoChargerGetNormalStop :1; //bit 5
  662. unsigned char ChademoChargerGetEmergencyStop :1; //bit 6
  663. unsigned char ChademoIsolationResultFail :1; //bit 7
  664. //InfoVal[8]
  665. unsigned char ChademoMissLinkWithMotherBoard :1; //bit 0
  666. unsigned char ChademoOutputVolMoreThanLimit :1; //bit 1
  667. unsigned char ChademoReqCurrentMoreThanLimit :1; //bit 2
  668. unsigned char ChademoReCapBmsEqrCurrentExceed :1; //bit 3
  669. unsigned char ChademoChargeRemainCountDown :1; //bit 4
  670. unsigned char :3; //bit 5 ~ 7 reserved
  671. //InfoVal[9]
  672. unsigned char BackendDisconnectedViaEthernet:1; //bit 0
  673. unsigned char BackendDisconnectViaWiFi:1; //bit 1
  674. unsigned char BackendDisconnectVia4G:1; //bit 2
  675. unsigned char BackendRemoteStart:1; //bit 3
  676. unsigned char BackendRemoteStop:1; //bit 4
  677. unsigned char BackendRemoteReset:1; //bit 5
  678. unsigned char :2; //bit 6~7 reserved
  679. }bits;
  680. }InfoEvents;
  681. };
  682. struct StatusCodeData
  683. {
  684. struct FaultCodeData FaultCode;
  685. struct AlarmCodeData AlarmCode;
  686. struct InfoCodeData InfoCode;
  687. };
  688. /**************************************************************************************/
  689. /**************************PSU Share memory***************************************/
  690. /**************************************************************************************/
  691. /*Following are the information for each PSU module*/
  692. struct PsuModuleData
  693. {
  694. unsigned char AssignID;
  695. unsigned char PhysicalID;
  696. unsigned char GroupID;
  697. unsigned char Address;
  698. unsigned char FireWireIndex;
  699. unsigned char FwVersion[12];
  700. unsigned char SerialNumber[32];
  701. unsigned char StateMachine; //0: Identification, 1:Operation, 2: Alarm, 3: Failure, s4:Upgrade
  702. unsigned char OutputPowerSwitch; //0: D.D normal OFF, 1: D.D emergency OFF, 2: D.D ON
  703. unsigned short FanSpeed_1; //RPM
  704. unsigned short FanSpeed_2; //RPM
  705. unsigned short FanSpeed_3; //RPM
  706. unsigned short FanSpeed_4; //RPM
  707. unsigned short InputVoltage_Type; //0x00 = Line to Line Vol, 0x01 = Line to Neutral Vol
  708. unsigned short InputVoltageL1; //abcd=abc.d volt
  709. unsigned short InputVoltageL2; //abcd=abc.d volt
  710. unsigned short InputVoltageL3; //abcd=abc.d volt
  711. unsigned short InputCurrentL1; //abcd=abc.d amp
  712. unsigned short InputCurrentL2; //abcd=abc.d amp
  713. unsigned short InputCurrentL3; //abcd=abc.d amp
  714. unsigned short PresentOutputVoltage; //abcd=abc.d volt
  715. unsigned short PresentOutputCurrent; //abcd=abc.d amp
  716. unsigned short AvailableCurrent; //abcd=abc.d amp
  717. unsigned int AvailablePower; //Watt
  718. unsigned char CriticalTemp1; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  719. unsigned char CriticalTemp2; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  720. unsigned char CriticalTemp3; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  721. unsigned char ExletTemp; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  722. unsigned char InletTemp_1; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  723. unsigned char InletTemp_2; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  724. unsigned char InletTemp; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  725. unsigned char OutletTemp; //0x00: -60¢XC ~ 0xFE: 194¢XC, resolution: 1¢XC, offset: -60¢XC, 0xFF: invalid
  726. unsigned int AlarmCode; //
  727. unsigned int FaultCode; //
  728. };
  729. /*Following are the information for each PSU Group*/
  730. struct PsuGroupData
  731. {
  732. unsigned char GroupPresentPsuQuantity;
  733. unsigned char GroupOutputPowerSwitch; //0: D.D normal OFF, 1: D.D emergency OFF, 2: D.D ON
  734. unsigned short GroupTargetOutputVoltage; //abcd=abc.d volt
  735. unsigned short GroupTargetOutputCurrent; //abcd=abc.d amp
  736. unsigned short GroupAvailableCurrent; //abcd=abc.d amp
  737. unsigned int GroupAvailablePower; //Watt
  738. unsigned short GroupPresentOutputVoltage; //abcd=abc.d volt
  739. unsigned short GroupPresentOutputCurrent; //abcd=abc.d Amps
  740. struct PsuModuleData PsuModule[MAX_PSU_QUANTITY];
  741. };
  742. /*Following is the information for system all PSU*/
  743. struct PsuData
  744. {
  745. unsigned char SystemPresentPsuQuantity;
  746. struct PsuGroupData PsuGroup[4];
  747. unsigned char GroupCount;
  748. unsigned char SelfTest_Comp; // 0 : none, other : complete
  749. };
  750. /************************************************************************************/
  751. /**************************CHAdeMO protocol Share memory*********************/
  752. /**************************************************************************************/
  753. struct CHAdeMOEvData
  754. {
  755. unsigned char SupportDynamicControl; //110.0
  756. // bit0=1:supported
  757. unsigned char SupportHighCurrent; //110.0
  758. // bit1=1:supported
  759. unsigned char MiniChargeCurrent; //100.0 0~200(A) (unit:1A)
  760. // 0x00: request for current equivalent to 1.5kW
  761. // 0x01: no request
  762. // 0x02: request of 1A and following are the same rule
  763. unsigned short MaxiBatteryVoltage; //100.5,100.4 0~600(V) (unit:1V)
  764. unsigned short MaxiChargingTime; //101.2,101.1 10(sec.)~255(min.) (Unit:sec)
  765. // Set 0xFF to 101.1 (Unit: 10sec) in case 101.2 (Unit: 1min) is used
  766. unsigned char EstimatChargingTime; //101.3 0~254(min.) (Unit:sec)
  767. // Display Only
  768. unsigned short TotalBatteryCapacity; //101.6,101.5 0.1~6553.5(kWh) (unit:0.1 kWh)
  769. unsigned char ProtocolVersion; //102.0 0~255
  770. // 0x02: CHAdeMO specification ver.1.2
  771. unsigned short TargetBatteryVoltage; //102.2,102.1 0~600(V) (unit:1V)
  772. unsigned short ChargingCurrentRequest; //102.3 0~200(A) (unit:1A)
  773. //110.2,110.1 0~1023(A) (unit:1A)
  774. unsigned char BatteryAlarm; //102.4 >0:alarm
  775. // bit0=1:Battery overvoltage
  776. // bit1=1:Battery undervoltage
  777. // bit2=1:Battery current deviation error
  778. // bit3=1:High battery temperature
  779. // bit4=1:Battery voltage deviation error
  780. unsigned char EvDetection; //102.5
  781. // bit0=0:Vehicle charging disabled, (stop charging)
  782. // bit0=1:Vehicle charging enabled,
  783. // bit1=0:¡§Parking¡¨ position
  784. // bit1=1:other position (stop charging)
  785. // bit2=0:Charging system normal
  786. // bit2=1:Charging system error (stop charging)
  787. // bit3=0:EV contactor close or during welding detection
  788. // bit3=1:EV contactor open or termination of welding detection (stop charging)
  789. // bit4=0:No stop request before charging
  790. // bit4=1:Normal stop request before charging (stop charging)
  791. unsigned char SOC; //102.6 0~100(%) (unit:%)
  792. // Display Only
  793. unsigned char Communicating; // it is true if receive EV CAN message within every 1500ms
  794. };
  795. struct CHAdeMOEvseData
  796. {
  797. unsigned char SelfTest_Comp;
  798. unsigned char version[16]; //Chademo firmware version
  799. unsigned char SupportDynamicControl; //118.0
  800. // bit0=1:supported
  801. unsigned char SupportHighCurrent; //118.0
  802. // bit1=1:supported
  803. unsigned short AvailableOutputVoltage; //108.2,108.1 0~600(V) (unit:1V)
  804. unsigned short AvailableOutputCurrent; //108.3 0~255(A) (unit:1A)
  805. //118.2,118.1 0~1023(A) (unit:1A)
  806. unsigned short ThresholdVoltage; //108.5,108.4 0~600(V) (unit:1V)
  807. unsigned char ConnectorTemperatureP; //108.6 -40~215(degC) (unit:degC) //value 0=-40 [NISSAN customized]
  808. unsigned char ConnectorTemperatureN; //108.7 -40~215(degC) (unit:degC) //value 0=-40 [NISSAN customized]
  809. unsigned char ProtocolVersion; //109.0 0~255
  810. // 0x00: CHAdeMO specification 0.9 and earlier
  811. // 0x01: CHAdeMO specification 0.9 and 0.9.1
  812. // 0x02: CHAdeMO specification 1.0.0, 1.0.1, 1.1 and 1.2
  813. unsigned short PresentOutputVoltage; //109.2,109.1 0~600(V) (unit:1V)
  814. unsigned short PresentOutputCurrent; //109.3 0~255(A) (unit:1A)
  815. //118.4,118.3 0~1023(A) (unit:1A)
  816. unsigned char EvseDetection; //109.5
  817. // bit0=0:not charging state now
  818. // bit0=1:charging state now
  819. // bit1=0:EVSE normal
  820. // bit1=1:EVSE error
  821. // bit2=0:Not Energizing state
  822. // bit2=1:Energizing state
  823. // bit3=0:No Battery incompatibility
  824. // bit3=1:Battery incompatibility
  825. // bit4=0:No Charging system error
  826. // bit4=1:Charging system error
  827. // bit5=0:No Charging stop control
  828. // bit5=1:Charging stop control
  829. unsigned short RemainChargingTime; //109.7,109.6 10(sec.)~255(min.) (Unit:sec)
  830. // Set 0xFF to 109.6 (Unit: 10sec) in case 109.7 (Unit: 1min) is used
  831. unsigned char HighPowerCondition; //118.5
  832. // bit0=0:Present charging current H¡¦118.3,H¡¦118.4¡¨ is less than or equal to rated current of a charging cable
  833. // bit0=1:Present charging current H¡¦118.3,H¡¦118.4¡¨ is exceeds to rated current of a charging cable
  834. // bit1=1:charging cable Cooling function Operating Installed
  835. // bit2=1:charging cable Current limiting function
  836. // bit3=1:charging connector Cooling function Operating
  837. // bit4=1:charging connector Current limiting function Installed
  838. // bit5=1:charging connector Over-temperature protection Installed
  839. // bit6=1:Functional safety Applied
  840. unsigned int MaxiGroupPower; // XXXXXXXX (Unit:Watt)depend on which group to be used
  841. unsigned int MaxiGroupCurrent; // XXXXXXXX (unit:1A)depend on which group to be used
  842. unsigned short ApplyOutputVoltage; // 0~600(V) (unit:1V)
  843. unsigned short ElapseChargingTime; // (Unit:sec)
  844. unsigned short ElapseEnergy; // (Unit:10xkWh)
  845. unsigned char EvboardStatus; // 0 : init
  846. };
  847. struct CHAdeMOData
  848. {
  849. struct CHAdeMOEvData ev[CHAdeMO_QUANTITY];
  850. struct CHAdeMOEvseData evse[CHAdeMO_QUANTITY];
  851. };
  852. /************************************************************************************/
  853. /**************************CCS protocol Share memory***************************/
  854. /**************************DIN70121: 201412***************************************/
  855. /**************************ISO15118_2014: 2014************************************/
  856. /**************************ISO15118_2018: 2018************************************/
  857. /************************************************************************************/
  858. typedef enum boolean { FALSE, TRUE } BOOL;
  859. enum ResponseCodeType_DIN70121 { OK_DIN70121 = 0, OK_NewSessionEstablished_DIN70121 = 1, OK_OldSessionJoined_DIN70121 = 2, OK_CertificateExpiresSoon_DIN70121 = 3,
  860. FAILED_DIN70121 = 4, FAILED_SequenceError_DIN70121 = 5, FAILED_ServiceIDInvalid_DIN70121 = 6, FAILED_UnknownSession_DIN70121 = 7,
  861. FAILED_ServiceSelectionInvalid_DIN70121 = 8, FAILED_PaymentSelectionInvalid_DIN70121 = 9, FAILED_CertificateExpired_DIN70121 = 10,
  862. FAILED_SignatureError_DIN70121 = 11, FAILED_NoCertificateAvailable_DIN70121 = 12, FAILED_CertChainError_DIN70121 = 13, FAILED_ChallengeInvalid_DIN70121 = 14,
  863. FAILED_ContractCanceled_DIN70121 = 15, FAILED_WrongChargeParameter_DIN70121 = 16, FAILED_PowerDeliveryNotApplied_DIN70121 = 17,
  864. FAILED_TariffSelectionInvalid_DIN70121 = 18, FAILED_ChargingProfileInvalid_DIN70121 = 19, FAILED_EVSEPresentVoltageToLow_DIN70121 = 20,
  865. FAILED_MeteringSignatureNotValid_DIN70121 = 21, FAILED_WrongEnergyTransferType_DIN70121 = 22};
  866. enum ResponseCodeType_ISO15118_2014 { OK_ISO15118_2014 = 0, OK_NewSessionEstablished_ISO15118_2014 = 1, OK_OldSessionJoined_ISO15118_2014 = 2, OK_CertificateExpiresSoon_ISO15118_2014 = 3,
  867. FAILED_ISO15118_2014 = 4, FAILED_SequenceError_ISO15118_2014 = 5, FAILED_ServiceIDInvalid_ISO15118_2014 = 6, FAILED_UnknownSession_ISO15118_2014 = 7,
  868. FAILED_ServiceSelectionInvalid_ISO15118_2014 = 8, FAILED_PaymentSelectionInvalid_ISO15118_2014 = 9, FAILED_CertificateExpired_ISO15118_2014 = 10,
  869. FAILED_SignatureError_ISO15118_2014 = 11, FAILED_NoCertificateAvailable_ISO15118_2014 = 12, FAILED_CertChainError_ISO15118_2014 = 13, FAILED_ChallengeInvalid_ISO15118_2014 = 14,
  870. FAILED_ContractCanceled_ISO15118_2014 = 15, FAILED_WrongChargeParameter_ISO15118_2014 = 16, FAILED_PowerDeliveryNotApplied_ISO15118_2014 = 17,
  871. FAILED_TariffSelectionInvalid_ISO15118_2014 = 18, FAILED_ChargingProfileInvalid_ISO15118_2014 = 19, FAILED_MeteringSignatureNotValid_ISO15118_2014 = 20,
  872. FAILED_NoChargeServiceSelected_ISO15118_2014 = 21, FAILED_WrongEnergyTransferMode_ISO15118_2014 = 22, FAILED_ContactorError_ISO15118_2014 = 23,
  873. FAILED_CertificateNotAllowedAtThisEVSE_ISO15118_2014 = 24, FAILED_CertificateRevoked_ISO15118_2014 = 25 };
  874. enum ResponseCodeType_ISO15118_2018 { OK_ISO15118_2018 = 0, OK_NewSessionEstablished_ISO15118_2018 = 1, OK_OldSessionJoined_ISO15118_2018 = 2, OK_CertificateExpiresSoon_ISO15118_2018 = 3,
  875. OK_IsolationValid_ISO15118_2018 = 4, OK_IsolationWarning_ISO15118_2018 = 5, WARNING_CertificateExpired_ISO15118_2018 = 6, WARNING_NoCertificateAvailable_ISO15118_2018 = 7,
  876. WARNING_CertValidationError_ISO15118_2018 = 8, WARNING_CertVerificationError_ISO15118_2018 = 9, WARNING_ContractCanceled_ISO15118_2018 = 10,
  877. FAILED_ISO15118_2018 = 11, FAILED_SequenceError_ISO15118_2018 = 12, FAILED_ServiceIDInvalid_ISO15118_2018 = 13, FAILED_UnknownSession_ISO15118_2018 = 14,
  878. FAILED_ServiceSelectionInvalid_ISO15118_2018 = 15, FAILED_SignatureError_ISO15118_2018 = 16, FAILED_IdentificationSelectionInvalid_ISO15118_2018 = 17,
  879. FAILED_ChallengeInvalid_ISO15118_2018 = 18, FAILED_WrongChargeParameter_ISO15118_2018 = 19, FAILED_IsolationFault_ISO15118_2018 = 20,
  880. FAILED_PowerDeliveryNotApplied_ISO15118_2018 = 21, FAILED_TariffSelectionInvalid_ISO15118_2018 = 22, FAILED_ChargingProfileInvalid_ISO15118_2018 = 23,
  881. FAILED_MeteringSignatureNotValid_ISO15118_2018 = 24, FAILED_NoChargeServiceSelected_ISO15118_2018 = 25, FAILED_WrongEnergyTransferMode_ISO15118_2018 = 26,
  882. FAILED_ContactorError_ISO15118_2018 = 27, FAILED_CertificateRevoked_ISO15118_2018 = 28, FAILED_CertificateNotYetValid_ISO15118_2018 = 29 };
  883. enum EVSENotificationType { None = 0, StopCharging = 1, ReNegotiation = 2};
  884. enum ServiceCategoryType { EVCharging = 0, Internet = 1, ContractCertificate = 2, OtherCustom = 3};
  885. enum PaymentOptionType { Contract = 0, ExternalPayment = 1};
  886. /*enum EVSESupportedEnergyTransferType { AC_single_phase_core = 0, AC_three_phase_core = 1, DC_core = 2, DC_extended = 3,
  887. DC_combo_core = 4, DC_dual = 5, AC_core1p_DC_extended = 6, AC_single_DC_core = 7,
  888. AC_single_phase_three_phase_core_DC_extended = 8, AC_core3p_DC_extended = 9};*/
  889. enum EnergyTransferModeType { AC_single_phase_core = 0, AC_three_phase_core = 1, DC_core = 2, DC_extended = 3,
  890. DC_combo_core = 4, DC_unique = 5};
  891. //enum identificationOptionType { Contract = 0, ExternalIdentification = 1};
  892. enum unitSymbolType_DIN70121 { h_DIN70121 = 0, m_DIN70121 = 1, s_DIN70121 = 2, A_DIN70121 = 3, Ah_DIN70121 = 4, V_DIN70121 = 5, VA_DIN70121 = 6, W_DIN70121 = 7, Ws_DIN70121 = 8, Wh_DIN70121 = 9};
  893. enum unitSymbolType_ISO15118_2014 { h_ISO15118_2014 = 0, m_ISO15118_2014 = 1, s_ISO15118_2014 = 2, A_ISO15118_2014 = 3, V_ISO15118_2014 = 4, W_ISO15118_2014 = 5, Wh_ISO15118_2014 = 6};
  894. enum ProcessingType { Finished = 0, Ongoing = 1, Ongoing_WaitingForCustomerInteraction = 2};
  895. enum EVSEProcessingType_DIN70121 { Finished_DIN70121 = 0, Ongoing_DIN70121 = 1};
  896. enum EVSEProcessingType_ISO15118_2014 { Finished_ISO15118_2014 = 0, Ongoing_ISO15118_2014 = 1, Ongoing_WaitingForCustomerInteraction_ISO15118_2014=2 };
  897. enum DC_EVErrorCodeType { NO_ERROR = 0, FAILED_RESSTemperatureInhibit = 1, FAILED_EVShiftPosition = 2, FAILED_ChargerConnectorLockFault = 3,
  898. FAILED_EVRESSMalfunction = 4, FAILED_ChargingCurrentdifferential = 5, FAILED_ChargingVoltageOutOfRange = 6,
  899. Reserved_A = 7, Reserved_B = 8, Reserved_C = 9, FAILED_ChargingSystemIncompatibility = 10, NoData = 11};
  900. enum IsolationLevelType_DIN70121 { Invalid_DIN70121 = 0, Valid_DIN70121 = 1, Warning_DIN70121 = 2, Fault_DIN70121 = 3};
  901. enum IsolationLevelType_ISO15118_2014 { Invalid_ISO15118_2014 = 0, Valid_ISO15118_2014 = 1, Warning_ISO15118_2014 = 2, Fault_ISO15118_2014 = 3, No_IMD_ISO15118_2014 = 4};
  902. enum DC_EVSEStatusCodeType { EVSE_NotReady = 0, EVSE_Ready = 1, EVSE_Shutdown = 2, EVSE_UtilityInterruptEvent = 3,
  903. EVSE_IsolationMonitoringActive = 4, EVSE_EmergencyShutdown = 5, EVSE_Malfunction = 6,
  904. Reserved_8 = 7, Reserved_9 = 8};
  905. enum ScheduleOriginType { EV = 0, SA = 1};
  906. enum ChargeProgressType_ISO15118_2014 {start_ISO15118_2014 = 0, Stop_ISO15118_2014 = 1, Renegotiate_ISO15118_2014 = 2};
  907. enum ChargeProgressType_ISO15118_2018 {start_ISO15118_2018 = 0, Renegotiate_ISO15118_2018 = 1, Standby_ISO15118_2018 = 2, Stop_ISO15118_2018 = 3};
  908. enum evOperationType {Charge = 0, Discharge = 1, Standby = 2};
  909. enum mechanicalChargingDeviceStatusType {Home = 0, Moving = 1, EndPosition = 2};
  910. enum EV_CP_StatusType {A = 0, B = 1, C = 2, D = 3, E = 4, F = 5};
  911. enum EV_Error_Status_CodeType { No_EV_Error = 0, EV_FAILED_EmergencyEvent = 1, EV_FAILED_Breaker = 2, EV_FAILED_RESSTemperatureInhibit = 3,
  912. EV_FAILED_RESS = 4, EV_FAILED_ChargingCurrentDifferential = 5, EV_FAILED_ChargingVoltageOutOfRange = 6,
  913. Reserved_by_ISO_1 = 7, Reserved_by_ISO_2 = 8, Reserved_by_ISO_3 = 9, OEM1 = 10,
  914. OEM2 = 11, OEM3 = 12, OEM4 = 13};
  915. enum IsolationStatusType { Invalid = 0, Safe = 1, Warning = 2, Fault = 3};
  916. enum ChargingSessionType { Terminate = 0, Pause = 1};
  917. enum CostKindType { relativePricePercentage = 0, RenewableGenerationPercentage = 1, CarbonDioxideEmission = 2};
  918. struct PhysicalValueType_DIN70121 //The final physical value is determined by: Value * 10 ^ Multiplier [Unit]
  919. {
  920. int Multiplier; //range: -3..+3
  921. enum unitSymbolType_DIN70121 Unit;
  922. short Value;
  923. };
  924. struct PhysicalValueType_ISO15118_2014 //The final physical value is determined by: Value * 10 ^ Multiplier [Unit]
  925. {
  926. int Multiplier; //range: -3..+3
  927. enum unitSymbolType_ISO15118_2014 Unit;
  928. short Value;
  929. };
  930. struct PhysicalValueType_ISO15118_2018 //The final physical value is determined by: Value * 10 ^ Exponent [Unit]
  931. {
  932. int Exponent; //range: -3..+3
  933. short Value;
  934. };
  935. struct AppProtocolType
  936. {
  937. unsigned char ProtocolNamespace[100];
  938. unsigned int VersionNumberMajor;
  939. unsigned int VersionNumberMinor;
  940. unsigned char SchemaID;
  941. unsigned char Priority; //range 1..20
  942. };
  943. struct ACD_SSEnergyTransferModeType
  944. {
  945. unsigned char EVID[20];
  946. };
  947. struct EVSEStatusType
  948. {
  949. unsigned short NotificationMaxDelay; //in seconds
  950. enum EVSENotificationType EVSENotification;
  951. };
  952. struct ServiceIDListType
  953. {
  954. unsigned short ServiceID[10]; //refer to chapter 8.6.2.1 Table 192
  955. };
  956. struct PaymentOptionListType
  957. {
  958. enum PaymentOptionType PaymentOption[2];
  959. };
  960. struct ServiceTagType
  961. {
  962. unsigned short ServiceID;
  963. unsigned char ServiceName[32];//Optional Element
  964. enum ServiceCategoryType ServiceCategory;
  965. unsigned char ServiceScope[32];//Optional Element
  966. };
  967. struct ServiceType_DIN70121
  968. {
  969. struct ServiceTagType ServiceTag;
  970. BOOL FreeService;
  971. };
  972. struct ServiceType_ISO15118_2014
  973. {
  974. unsigned short ServiceID;
  975. unsigned char ServiceName[32]; //Optional
  976. enum ServiceCategoryType ServiceCategory;
  977. unsigned char ServiceScope[64]; //Optional
  978. BOOL FreeService;
  979. };
  980. /*struct ServiceType_ISO15118_2018
  981. {
  982. unsigned short ServiceID;
  983. BOOL FreeService;
  984. }; */
  985. struct SupportedEnergyTransferModeType
  986. {
  987. enum EnergyTransferModeType EnergyTransferMode[6];
  988. };
  989. struct ServiceChargeType
  990. {
  991. struct ServiceType_DIN70121 Services;
  992. //enum EVSESupportedEnergyTransferType EnergyTransferType;
  993. enum EnergyTransferModeType EnergyTransferType;
  994. };
  995. struct ChargeServiceType
  996. {
  997. struct ServiceType_ISO15118_2014 Services;
  998. struct SupportedEnergyTransferModeType SupportedEnergyTransferMode;
  999. };
  1000. struct ServiceListType
  1001. {
  1002. struct ServiceType_ISO15118_2014 Service[8];
  1003. };
  1004. struct IdentificationOptionListType
  1005. {
  1006. enum PaymentOptionType IdentificationOption[2];
  1007. };
  1008. struct ParameterType
  1009. {
  1010. unsigned char Name[32];
  1011. struct PhysicalValueType_ISO15118_2014 PhysicalValue_ISO15118_2014;
  1012. struct PhysicalValueType_ISO15118_2018 PhysicalValue_ISO15118_2018;
  1013. };
  1014. struct ParameterSetType
  1015. {
  1016. short ParameterSetID;
  1017. struct ParameterType Parameter[16];
  1018. };
  1019. struct ServiceParameterListType
  1020. {
  1021. struct ParameterSetType ParameterSet[255];
  1022. };
  1023. struct WPT_SDlEnergyTransferModeType
  1024. {
  1025. struct ServiceParameterListType ServiceParameterList;
  1026. };
  1027. struct SelectedServiceType
  1028. {
  1029. unsigned short ServiceID;
  1030. short ParameterSetID;
  1031. };
  1032. struct SelectedServiceListType
  1033. {
  1034. struct SelectedServiceType SelectedService[16];
  1035. };
  1036. struct CertificateChainType
  1037. {
  1038. unsigned char Id[32]; //Optional
  1039. unsigned char Certificate[800]; //check size again
  1040. unsigned char SubCertificates[4][800]; //Optional, check size again
  1041. };
  1042. struct PNC_AReqIdentificationModeType
  1043. {
  1044. unsigned char GenChallenge[16]; //DIN70121=> None, ISO15118_2014=>None, ISO15118_2018=>Optional
  1045. unsigned char Id[32]; //DIN70121=> None, ISO15118_2014=>None, ISO15118_2018=>Optional
  1046. };
  1047. struct AC_EVChargeParameterType
  1048. {
  1049. unsigned int DepartureTime; //Optional
  1050. struct PhysicalValueType_ISO15118_2014 EAmount;
  1051. struct PhysicalValueType_ISO15118_2014 EVMaxVoltage;
  1052. struct PhysicalValueType_ISO15118_2014 EVMaxCurrent;
  1053. struct PhysicalValueType_ISO15118_2014 EVMinCurrent;
  1054. };
  1055. struct DC_EVStatusType_DIN70121
  1056. {
  1057. BOOL EVReady;
  1058. BOOL EVCabinConditioning;
  1059. BOOL EVRESSConiditioning;
  1060. enum DC_EVErrorCodeType EVErrorCode;
  1061. unsigned char EVRESSSOC; /*0-100 percentage*/
  1062. };
  1063. struct DC_EVChargeParameterType_DIN70121
  1064. {
  1065. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  1066. struct PhysicalValueType_DIN70121 EVMaximumCurrentLimit;
  1067. struct PhysicalValueType_DIN70121 EVMaximumPowerLimit; //Optional
  1068. struct PhysicalValueType_DIN70121 EVMaximumVoltageLimit;
  1069. struct PhysicalValueType_DIN70121 EVEnergyCapacity; //Optional
  1070. struct PhysicalValueType_DIN70121 EVEnergyRequest; //Optional
  1071. unsigned char FullSOC;/*0-100 percentage*/ //Optional
  1072. unsigned char BulkSOC;/*0-100 percentage*/ //Optional
  1073. };
  1074. struct DC_EVStatusType_ISO15118_2014
  1075. {
  1076. BOOL EVReady;
  1077. enum DC_EVErrorCodeType EVErrorCode;
  1078. unsigned char EVRESSSOC; /*0-100 percentage*/
  1079. };
  1080. struct DC_EVChargeParameterType_ISO15118_2014
  1081. {
  1082. unsigned int DepartureTime; //Optional
  1083. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  1084. struct PhysicalValueType_ISO15118_2014 EVMaximumCurrentLimit;
  1085. struct PhysicalValueType_ISO15118_2014 EVMaximumPowerLimit; //Optional
  1086. struct PhysicalValueType_ISO15118_2014 EVMaximumVoltageLimit;
  1087. struct PhysicalValueType_ISO15118_2014 EVEnergyCapacity; //Optional
  1088. struct PhysicalValueType_ISO15118_2014 EVEnergyRequest; //Optional
  1089. unsigned char FullSOC;/*0-100 percentage*/ //Optional
  1090. unsigned char BulkSOC;/*0-100 percentage*/ //Optional
  1091. };
  1092. struct Dynamic_CPDReqControlModeType
  1093. {
  1094. unsigned int DepartureTime;
  1095. };
  1096. struct RelativeTimeIntervalType
  1097. {
  1098. unsigned int duration; //Optional
  1099. unsigned int start;
  1100. };
  1101. struct PMaxScheduleEntryType
  1102. {
  1103. struct RelativeTimeIntervalType RelativeTimeInterval;
  1104. unsigned short PMax;
  1105. };
  1106. struct PMaxScheduleType
  1107. {
  1108. unsigned short PMaxScheduleID; //no this itme in ISO15118_2014
  1109. struct PMaxScheduleEntryType PMaxScheduleEntry[1024];
  1110. };
  1111. struct CostType
  1112. {
  1113. unsigned int amount;
  1114. enum CostKindType costKind;
  1115. int amountMultiplier; //Optional , range: -3..+3
  1116. };
  1117. struct ConsumptionCostType
  1118. {
  1119. struct CostType Cost[3];
  1120. struct PhysicalValueType_ISO15118_2014 startValue;
  1121. };
  1122. struct SalesTariffEntryType
  1123. {
  1124. struct RelativeTimeIntervalType RelativeTimeInterval;
  1125. unsigned char EPriceLevel; //Optional
  1126. struct ConsumptionCostType ConsumptionCost[3]; //Optional
  1127. };
  1128. struct SalesTariffType
  1129. {
  1130. unsigned char Id[32]; //Optional
  1131. short SalesTariffID;
  1132. unsigned char SalesTariffDescription[32]; //Optional
  1133. unsigned char NumEPriceLevels; //Optional
  1134. struct SalesTariffEntryType SalesTariffEntry[1024];
  1135. };
  1136. struct SAScheduleTupleType
  1137. {
  1138. short SAScheduleTupleID;
  1139. struct PMaxScheduleType PMaxSchedule;
  1140. struct SalesTariffType SalesTariff; //Optional
  1141. };
  1142. struct ScheduleListType
  1143. {
  1144. enum ScheduleOriginType ScheduleOrigin;
  1145. struct SAScheduleTupleType ScheduleTuple[3];
  1146. };
  1147. struct Scheduled_CPDReqControlModeType
  1148. {
  1149. enum ProcessingType EVProcessing;
  1150. unsigned int DepartureTime; //Optional
  1151. unsigned short MaxSupportingPoints;
  1152. struct ScheduleListType ScheduleList; //Optional
  1153. };
  1154. struct AC_CPDReqEnergyTransferModeType
  1155. {
  1156. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest; //Optional
  1157. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest; //Optional
  1158. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest; //Optional
  1159. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower;
  1160. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent;
  1161. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent;
  1162. struct PhysicalValueType_ISO15118_2018 EVMaximumVoltage;
  1163. };
  1164. struct DC_CPDReqEnergyTransferModeType
  1165. {
  1166. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower; //Optional
  1167. struct PhysicalValueType_ISO15118_2018 EVMinimumChargePower; //Optional
  1168. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent;
  1169. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent;
  1170. struct PhysicalValueType_ISO15118_2018 EVMaximumVoltage;
  1171. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest; //Optional
  1172. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest; //Optional
  1173. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest; //Optional
  1174. unsigned char TargetSOC; //Optional
  1175. unsigned char BulkSOC; //Optional
  1176. };
  1177. struct BPT_AC_CPDReqEnergyTransferModeType
  1178. {
  1179. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower;
  1180. struct PhysicalValueType_ISO15118_2018 EVMaximumDischargePower;
  1181. struct PhysicalValueType_ISO15118_2018 EVMinimumDischargePower;
  1182. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent;
  1183. struct PhysicalValueType_ISO15118_2018 EVMaximumDischargeCurrent;
  1184. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent;
  1185. struct PhysicalValueType_ISO15118_2018 EVMinimumDischargeCurrent;
  1186. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest; //Optional
  1187. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest; //Optional
  1188. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest; //Optional
  1189. struct PhysicalValueType_ISO15118_2018 EVMaximumVoltage;
  1190. };
  1191. struct BPT_DC_CPDReqEnergyTransferModeType
  1192. {
  1193. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower;
  1194. struct PhysicalValueType_ISO15118_2018 EVMinimumChargePower;
  1195. struct PhysicalValueType_ISO15118_2018 EVMaximumDischargePower;
  1196. struct PhysicalValueType_ISO15118_2018 EVMinimumDischargePower;
  1197. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent;
  1198. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent;
  1199. struct PhysicalValueType_ISO15118_2018 EVMaximumDischargeCurrent;
  1200. struct PhysicalValueType_ISO15118_2018 EVMinimumDischargeCurrent;
  1201. struct PhysicalValueType_ISO15118_2018 EVMaximumVoltage;
  1202. struct PhysicalValueType_ISO15118_2018 EVMinimumVoltage;
  1203. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest;
  1204. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest;
  1205. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest;
  1206. unsigned char TargetSOC; //Optional
  1207. unsigned char BulkSOC; //Optional
  1208. };
  1209. struct WPT_CPDReqEnergyTransferModeType
  1210. {
  1211. struct PhysicalValueType_ISO15118_2018 EVMaximumPower; //Optional
  1212. struct PhysicalValueType_ISO15118_2018 EVMinimumPower; //Optional
  1213. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest; //Optional
  1214. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest; //Optional
  1215. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest; //Optional
  1216. };
  1217. struct ACD_CPDReqEnergyTransferModeType
  1218. {
  1219. //cannot be found in standard
  1220. };
  1221. struct SAScheduleListType
  1222. {
  1223. struct SAScheduleTupleType SAScheduleTuple[3];
  1224. };
  1225. struct DC_EVSEStatusType_DIN70121
  1226. {
  1227. enum IsolationLevelType_DIN70121 EVSEIsolationStatus; //Optional
  1228. enum DC_EVSEStatusCodeType EVSEStatusCode;
  1229. unsigned int NotificationMaxDelay;
  1230. enum EVSENotificationType EVSENotification;
  1231. };
  1232. struct DC_EVSEChargeParameterType_DIN70121
  1233. {
  1234. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  1235. struct PhysicalValueType_DIN70121 EVSEMaximumCurrentLimit;
  1236. struct PhysicalValueType_DIN70121 EVSEMaximumPowerLimit; //Optional
  1237. struct PhysicalValueType_DIN70121 EVSEMaximumVoltageLimit;
  1238. struct PhysicalValueType_DIN70121 EVSEMinimumCurrentLimit;
  1239. struct PhysicalValueType_DIN70121 EVSEMinimumVoltageLimit;
  1240. struct PhysicalValueType_DIN70121 EVSECurrentRegulationTolerance; //Optional
  1241. struct PhysicalValueType_DIN70121 EVSEPeakCurrentRipple;
  1242. struct PhysicalValueType_DIN70121 EVSEEnergyToBeDelivered; //Optional
  1243. };
  1244. struct AC_EVSEStatusType
  1245. {
  1246. BOOL RCD;
  1247. unsigned short NotificationMaxDelay;
  1248. enum EVSENotificationType EVSENotification; //need to be confirmed
  1249. };
  1250. struct AC_EVSEChargeParameterType
  1251. {
  1252. struct AC_EVSEStatusType AC_EVSEStatus;
  1253. struct PhysicalValueType_ISO15118_2014 EVSENominalVoltage;
  1254. struct PhysicalValueType_ISO15118_2014 EVSEMaxCurrent;
  1255. };
  1256. struct DC_EVSEStatusType_ISO15118_2014
  1257. {
  1258. unsigned short NotificationMaxDelay;
  1259. enum EVSENotificationType EVSENotification;
  1260. enum IsolationLevelType_ISO15118_2014 EVSEIsolationStatus; //Optional
  1261. enum DC_EVSEStatusCodeType DC_EVSEStatusCode;
  1262. };
  1263. struct DC_EVSEChargeParameterType_ISO15118_2014
  1264. {
  1265. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  1266. struct PhysicalValueType_ISO15118_2014 EVSEMaximumCurrentLimit;
  1267. struct PhysicalValueType_ISO15118_2014 EVSEMaximumPowerLimit;
  1268. struct PhysicalValueType_ISO15118_2014 EVSEMaximumVoltageLimit;
  1269. struct PhysicalValueType_ISO15118_2014 EVSEMinimumCurrentLimit;
  1270. struct PhysicalValueType_ISO15118_2014 EVSEMinimumVoltageLimit;
  1271. struct PhysicalValueType_ISO15118_2014 EVSECurrentRegulationTolerance; //Optional
  1272. struct PhysicalValueType_ISO15118_2014 EVSEPeakCurrentRipple;
  1273. struct PhysicalValueType_ISO15118_2014 EVSEEnergyToBeDelivered; //Optional
  1274. };
  1275. struct Scheduled_CPDResControlModeType
  1276. {
  1277. struct ScheduleListType ScheduleList;
  1278. };
  1279. struct AC_CPDResEnergyTransferModeType
  1280. {
  1281. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent[3];
  1282. struct PhysicalValueType_ISO15118_2018 EVSENominalVoltage;
  1283. struct PhysicalValueType_ISO15118_2018 EVSENominalFrequency;
  1284. };
  1285. struct DC_CPDResEnergyTransferModeType
  1286. {
  1287. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargePower;
  1288. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent;
  1289. struct PhysicalValueType_ISO15118_2018 EVSEMinimumChargeCurrent;
  1290. struct PhysicalValueType_ISO15118_2018 EVSEMaximumVoltage;
  1291. struct PhysicalValueType_ISO15118_2018 EVSEMinimumVoltage;
  1292. };
  1293. struct BPT_AC_CPDResEnergyTransferModeType
  1294. {
  1295. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent[3];
  1296. struct PhysicalValueType_ISO15118_2018 EVSEMaximumDischargeCurrent[3];
  1297. struct PhysicalValueType_ISO15118_2018 EVSENominalVoltage;
  1298. struct PhysicalValueType_ISO15118_2018 EVSENominalFrequency;
  1299. };
  1300. struct BPT_DC_CPDResEnergyTransferModeType
  1301. {
  1302. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargePower;
  1303. struct PhysicalValueType_ISO15118_2018 EVSEMaximumDischargePower;
  1304. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent;
  1305. struct PhysicalValueType_ISO15118_2018 EVSEMaximumDischargeCurrent;
  1306. struct PhysicalValueType_ISO15118_2018 EVSEMinimumChargeCurrent;
  1307. struct PhysicalValueType_ISO15118_2018 EVSEMinimumDischargeCurrent;
  1308. struct PhysicalValueType_ISO15118_2018 EVSEMaximumVoltage;
  1309. struct PhysicalValueType_ISO15118_2018 EVSEMinimumVoltage;
  1310. };
  1311. struct WPT_CPDResEnergyTransferModeType
  1312. {
  1313. struct PhysicalValueType_ISO15118_2018 EVSEMaximumPower;
  1314. struct PhysicalValueType_ISO15118_2018 EVSEMinimumPower;
  1315. };
  1316. struct ACD_CPDResEnergyTransferModeType
  1317. {
  1318. //not found in ISO15118_2018
  1319. };
  1320. struct ProfileEntryType_DIN70121
  1321. {
  1322. unsigned int ChargingProfileEntryStart;
  1323. short ChargingProfileEntryMaxPower;
  1324. };
  1325. struct ChargingProfileType_DIN70121
  1326. {
  1327. short SAScheduleTupleID;
  1328. struct ProfileEntryType_DIN70121 ProfileEntry[24];
  1329. };
  1330. struct DC_EVPowerDeliveryParameterType_DIN70121
  1331. {
  1332. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  1333. BOOL BulkChargingComplete; //Optional
  1334. BOOL ChargingComplete;
  1335. };
  1336. struct ProfileEntryType_ISO15118_2014
  1337. {
  1338. unsigned int ChargingProfileEntryStart;
  1339. struct PhysicalValueType_ISO15118_2018 ChargingProfileEntryMaxPower;
  1340. unsigned char ChargingProfileEntryMaxNumberOfPhasesInUse; //Optional
  1341. };
  1342. struct ChargingProfileType_ISO15118_2014
  1343. {
  1344. struct ProfileEntryType_ISO15118_2014 ProfileEntry[24];
  1345. };
  1346. struct DC_EVPowerDeliveryParameterType_ISO15118_2014
  1347. {
  1348. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  1349. BOOL BulkChargingComplete; //Optional
  1350. BOOL ChargingComplete;
  1351. };
  1352. struct TimeInterval
  1353. {
  1354. unsigned int start;
  1355. unsigned int duration; //Optional
  1356. };
  1357. struct PowerScheduleEntryType
  1358. {
  1359. struct TimeInterval TimeInterval;
  1360. struct PhysicalValueType_ISO15118_2018 Power[3];
  1361. };
  1362. struct EVPowerProfileType
  1363. {
  1364. struct PowerScheduleEntryType EVPowerProfileEntry[2048];
  1365. };
  1366. struct Scheduled_PDReqControlModeType
  1367. {
  1368. unsigned char ScheduleTupleID;
  1369. struct EVPowerProfileType EVPowerProfile;
  1370. };
  1371. struct BPT_Scheduled_PDReqControlModeType
  1372. {
  1373. unsigned char ScheduleTupleID;
  1374. struct EVPowerProfileType EVPowerProfile; //Optional
  1375. enum evOperationType EVOperation;
  1376. };
  1377. struct ListOfRootCertificateIDsType
  1378. {
  1379. unsigned char RootCertificateID[20][40];
  1380. };
  1381. struct ContractSignatureEncryptedPrivateKeyType
  1382. {
  1383. unsigned char Id[32];
  1384. };
  1385. struct DiffieHellmanPublickeyType
  1386. {
  1387. unsigned char Id[32];
  1388. };
  1389. struct ContractCertificateEncryptedPrivateKeyType
  1390. {
  1391. unsigned char Id[32];
  1392. };
  1393. struct EVTechnicalStatusType
  1394. {
  1395. BOOL EV_Status_ReadyToCharge;
  1396. BOOL EV_Status_ImmobilizationRequest; //Optional
  1397. BOOL EV_Status_Immobilized;
  1398. struct PhysicalValueType_ISO15118_2018 EV_Status_WLAN_Strength;
  1399. enum EV_CP_StatusType EV_CP_Status;
  1400. unsigned char EV_Status_RESSSOC; //0~100%
  1401. enum EV_Error_Status_CodeType EV_Error_Status_Code;
  1402. BOOL EVSE_Timeout;
  1403. };
  1404. struct MeterInfoType_ISO15118_2014
  1405. {
  1406. unsigned char MeterID[32];
  1407. unsigned long MeterReading; //Optional
  1408. unsigned char SigMeterReading[64]; //Optional
  1409. short MeterStatus; //Optional
  1410. short TMeter; //Optional
  1411. };
  1412. struct Scheduled_MRReqControlModeType
  1413. {
  1414. unsigned char ScheduleTupleID;
  1415. };
  1416. struct MeterInfoType_ISO15118_2018
  1417. {
  1418. unsigned char MeterID[32];
  1419. unsigned long MeterReadingWhCharged; //Optional
  1420. unsigned long MeterReadingWhDischarged; //Optional
  1421. unsigned long MeterReadingVARhLeading; //Optional
  1422. unsigned long MeterReadingVARhLagging; //Optional
  1423. unsigned char SignatureMeterReading[64]; //Optional
  1424. short MeterStatus; //Optional
  1425. short TimeStampMeter; //Optional
  1426. BOOL ReceiptRequired; //Optional
  1427. };
  1428. struct PnC_CLReqIdentificationModeType
  1429. {
  1430. BOOL MeteringReceiptRequested;
  1431. };
  1432. struct Dynamic_CSReqControlModeType
  1433. {
  1434. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest;
  1435. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest;
  1436. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest;
  1437. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower;
  1438. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent;
  1439. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent;
  1440. };
  1441. struct Scheduled_CSReqControlModeType
  1442. {
  1443. struct PhysicalValueType_ISO15118_2018 EVTargetEnergyRequest; //Optional
  1444. struct PhysicalValueType_ISO15118_2018 EVMaximumEnergyRequest; //Optional
  1445. struct PhysicalValueType_ISO15118_2018 EVMinimumEnergyRequest; //Optional
  1446. BOOL Standby;
  1447. struct PhysicalValueType_ISO15118_2018 EVMaximumChargePower; //Optional
  1448. struct PhysicalValueType_ISO15118_2018 EVMaximumChargeCurrent; //Optional
  1449. struct PhysicalValueType_ISO15118_2018 EVMinimumChargeCurrent; //Optional
  1450. };
  1451. struct DisplayParametersType
  1452. {
  1453. unsigned short CurrentRange;
  1454. unsigned char CurrentSOC; //0~100%
  1455. unsigned char MinimumSOC; //0~100%
  1456. struct PhysicalValueType_ISO15118_2018 RemainingTimeToMaximumSOC;
  1457. struct PhysicalValueType_ISO15118_2018 RemainingTimeToTargetSOC;
  1458. struct PhysicalValueType_ISO15118_2018 RemainingTimeToBulkSOC;
  1459. struct PhysicalValueType_ISO15118_2018 RemainingTimeToMinimumSOC;
  1460. BOOL ChargingComplete;
  1461. BOOL BulkChargingComplete;
  1462. BOOL InletHot;
  1463. };
  1464. struct PnC_CLResIdentificationModeType
  1465. {
  1466. struct MeterInfoType_ISO15118_2018 MeterInfo;
  1467. };
  1468. struct Dynamic_CSResControlModeType
  1469. {
  1470. struct PhysicalValueType_ISO15118_2018 EVSETargetActivePower;
  1471. };
  1472. struct Scheduled_CDResControlModeType
  1473. {
  1474. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargePower; //Optional
  1475. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent; //Optional
  1476. struct PhysicalValueType_ISO15118_2018 EVSEMaximumVoltage; //Optional
  1477. };
  1478. struct LFA_EVFinePositioningSetupParametersType
  1479. {
  1480. unsigned char NumberOfSensors;
  1481. //NOT complete yet, to be continue.....
  1482. };
  1483. /****SupportedAppProtocolRequest****/
  1484. struct SupportedAppProtocolRequest_DIN70121
  1485. {
  1486. struct AppProtocolType AppProtocol[20];
  1487. };
  1488. struct SupportedAppProtocolRequest_ISO15118_2014
  1489. {
  1490. struct AppProtocolType AppProtocol[20];
  1491. };
  1492. struct SupportedAppProtocolRequest_ISO15118_2018
  1493. {
  1494. struct AppProtocolType AppProtocol[20];
  1495. };
  1496. /****SupportedAppProtocolResponse****/
  1497. struct SupportedAppProtocolResponse_DIN70121
  1498. {
  1499. enum ResponseCodeType_DIN70121 ResponseCode;
  1500. unsigned char SchemaID; //Optional
  1501. };
  1502. struct SupportedAppProtocolResponse_ISO15118_2014
  1503. {
  1504. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1505. unsigned char SchemaID; //Optional
  1506. };
  1507. struct SupportedAppProtocolResponse_ISO15118_2018
  1508. {
  1509. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1510. unsigned char SchemaID; //Optional
  1511. };
  1512. /****SessionSetupRequest****/
  1513. struct SessionSetupRequest_DIN70121
  1514. {
  1515. unsigned char EVCCID[8]; //the MAC address of the EVCC in Hex
  1516. };
  1517. struct SessionSetupRequest_ISO15118_2014
  1518. {
  1519. unsigned char EVCCID[8]; //the MAC address of the EVCC in Hex
  1520. };
  1521. struct SessionSetupRequest_ISO15118_2018
  1522. {
  1523. unsigned char EVCCID[8]; //the MAC address of the EVCC in Hex
  1524. struct ACD_SSEnergyTransferModeType ACD_SSEnergyTransferMode; //For ACD mandatory, optional for rest
  1525. };
  1526. /****SessionSetupResponse****/
  1527. struct SessionSetupResponse_DIN70121
  1528. {
  1529. enum ResponseCodeType_DIN70121 ResponseCode;
  1530. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  1531. unsigned int EVSETimeStamp; //EPOCH format, Optional
  1532. };
  1533. struct SessionSetupResponse_ISO15118_2014
  1534. {
  1535. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1536. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  1537. unsigned int EVSETimeStamp; //EPOCH format, Optional
  1538. };
  1539. struct SessionSetupResponse_ISO15118_2018
  1540. {
  1541. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1542. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  1543. struct EVSEStatusType EVSEStatus; //Optional
  1544. };
  1545. /****ServiceDiscoveryRequest****/
  1546. struct ServiceDiscoveryRequest_DIN70121
  1547. {
  1548. unsigned char ServiceScope[32]; //Optional
  1549. enum ServiceCategoryType ServiceCategory; //Optional
  1550. };
  1551. struct ServiceDiscoveryRequest_ISO15118_2014
  1552. {
  1553. unsigned char ServiceScope[32]; //Optional
  1554. enum ServiceCategoryType ServiceCategory; //Optional
  1555. };
  1556. struct ServiceDiscoveryRequest_ISO15118_2018
  1557. {
  1558. struct ServiceIDListType SupportedServiceIDs; //Optional
  1559. };
  1560. /****ServiceDiscoveryResponse****/
  1561. struct ServiceDiscoveryResponse_DIN70121
  1562. {
  1563. enum ResponseCodeType_DIN70121 ResponseCode;
  1564. struct PaymentOptionListType PaymentOptions;
  1565. struct ServiceChargeType ChargeService_DIN70121;
  1566. };
  1567. struct ServiceDiscoveryResponse_ISO15118_2014
  1568. {
  1569. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1570. struct PaymentOptionListType PaymentOptions;
  1571. struct ChargeServiceType ChargeService;
  1572. struct ServiceListType ServiceList; //Optional
  1573. };
  1574. struct ServiceDiscoveryResponse_ISO15118_2018
  1575. {
  1576. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1577. struct EVSEStatusType EVSEStatus; //Optional
  1578. struct IdentificationOptionListType IdentificationOptionList;
  1579. struct ServiceListType EnergyTransferServiceList;
  1580. struct ServiceListType VASList; //Optional
  1581. };
  1582. /****ServiceDetailRequest****/
  1583. //Only in ISO15118_2014 and ISO15118_2018
  1584. struct ServiceDetailRequest_ISO15118_2014
  1585. {
  1586. unsigned short ServiceID;
  1587. };
  1588. struct ServiceDetailRequest_ISO15118_2018
  1589. {
  1590. unsigned short ServiceID;
  1591. struct WPT_SDlEnergyTransferModeType WPT_SDlEnergyTransferMode;
  1592. };
  1593. /****ServiceDetailResponse****/
  1594. struct ServiceDetailResponse_ISO15118_2014
  1595. {
  1596. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1597. unsigned short ServiceID;
  1598. struct ServiceParameterListType ServiceParameterList;
  1599. };
  1600. struct ServiceDetailResponse_ISO15118_2018
  1601. {
  1602. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1603. unsigned short ServiceID;
  1604. struct ServiceParameterListType ServiceParameterList;
  1605. struct EVSEStatusType EVSEStatus; //Optional
  1606. };
  1607. /****ServiceAndPaymentSelectionRequest / ServiceSelectionRequest****/
  1608. struct ServiceAndPaymentSelectionRequest_DIN70121
  1609. {
  1610. enum PaymentOptionType SelectedPaymentOption;
  1611. struct SelectedServiceListType SelectedServiceList;
  1612. };
  1613. struct ServiceAndPaymentSelectionRequest_ISO15118_2014
  1614. {
  1615. enum PaymentOptionType SelectedPaymentOption;
  1616. struct SelectedServiceListType SelectedServiceList;
  1617. };
  1618. struct ServiceSelectionRequest_ISO15118_2018
  1619. {
  1620. enum PaymentOptionType SelectedPaymentOption;
  1621. struct SelectedServiceType SelectedEnergyTransferService;
  1622. struct SelectedServiceListType SelectedVASList;
  1623. enum ProcessingType EVProcessing;
  1624. };
  1625. /****ServiceAndPaymentSelectionResponse / ServiceSelectionResponse****/
  1626. struct ServiceAndPaymentSelectionResponse_DIN70121
  1627. {
  1628. enum ResponseCodeType_DIN70121 ResponseCode;
  1629. };
  1630. struct ServiceAndPaymentSelectionResponse_ISO15118_2014
  1631. {
  1632. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1633. };
  1634. struct ServiceSelectionResponse_ISO15118_2018
  1635. {
  1636. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1637. struct EVSEStatusType EVSEStatus; //Optional
  1638. };
  1639. /****PaymentDetailsRequest / IdentificationDetailsRequest****/
  1640. struct PaymentDetailsRequest_ISO15118_2014
  1641. {
  1642. unsigned char eMAID[16];
  1643. struct CertificateChainType ContractSignatureCertChain;
  1644. };
  1645. struct IdentificationDetailsRequest_ISO15118_2018
  1646. {
  1647. struct CertificateChainType ContractSignatureCertChain;
  1648. };
  1649. /****PaymentDetailsResponse / IdentificationDetailsResponse ****/
  1650. struct PaymentDetailsResponse_ISO15118_2014
  1651. {
  1652. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1653. unsigned char GenChallenge[16];
  1654. long EVSETimeStamp;
  1655. };
  1656. struct IdentificationDetailsResponse_ISO15118_2018
  1657. {
  1658. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1659. struct EVSEStatusType EVSEStatus; //Optional
  1660. unsigned char GenChallenge[16];
  1661. enum ProcessingType EVSEProcessing;
  1662. };
  1663. /****ContractAuthenticationRequest / AuthorizationRequest****/
  1664. struct ContractAuthenticationRequest_DIN70121
  1665. {
  1666. //None
  1667. };
  1668. struct AuthorizationRequest_ISO15118_2014
  1669. {
  1670. unsigned char GenChallenge[16]; //Optional
  1671. unsigned char Id[32]; //Optional
  1672. };
  1673. struct AuthorizationRequest_ISO15118_2018
  1674. {
  1675. struct PNC_AReqIdentificationModeType PNC_AReqIdentificationMode; //Optional
  1676. };
  1677. /****ContractAuthenticationResponse / AuthorizationResponse****/
  1678. struct ContractAuthenticationResponse_DIN70121
  1679. {
  1680. enum ResponseCodeType_DIN70121 ResponseCode;
  1681. enum EVSEProcessingType_DIN70121 EVSEProcessing;
  1682. };
  1683. struct AuthorizationResponse_ISO15118_2014
  1684. {
  1685. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1686. enum EVSEProcessingType_ISO15118_2014 EVSEProcessing;
  1687. };
  1688. struct AuthorizationResponse_ISO15118_2018
  1689. {
  1690. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1691. enum ProcessingType EVSEProcessing;
  1692. struct EVSEStatusType EVSEStatus; //Optional
  1693. };
  1694. /****ChargeParameterDiscoveryRequest****/
  1695. struct ChargeParameterDiscoveryRequest_DIN70121
  1696. {
  1697. enum EnergyTransferModeType EVRequestedEnergyTransferType;
  1698. struct DC_EVChargeParameterType_DIN70121 DC_EVChargeParameter;
  1699. };
  1700. struct ChargeParameterDiscoveryRequest_ISO15118_2014
  1701. {
  1702. unsigned short MaxEntriesSAScheduleTuple; //Optional
  1703. enum EnergyTransferModeType RequestedEnergyTransferMode;
  1704. struct AC_EVChargeParameterType AC_EVChargeParameter;
  1705. struct DC_EVChargeParameterType_ISO15118_2014 DC_EVChargeParameter;
  1706. };
  1707. struct ChargeParameterDiscoveryRequest_ISO15118_2018
  1708. {
  1709. struct Dynamic_CPDReqControlModeType Dynamic_CPDReqControlMode;
  1710. struct Scheduled_CPDReqControlModeType Scheduled_CPDReqControlMode;
  1711. struct AC_CPDReqEnergyTransferModeType AC_CPDReqEnergyTransferMode;
  1712. struct DC_CPDReqEnergyTransferModeType DC_CPDReqEnergyTransferMode;
  1713. struct BPT_AC_CPDReqEnergyTransferModeType BPT_AC_CPDReqEnergyTransferMode;
  1714. struct BPT_DC_CPDReqEnergyTransferModeType BPT_DC_CPDReqEnergyTransferMode;
  1715. struct WPT_CPDReqEnergyTransferModeType WPT_CPDReqEnergyTransferMode;
  1716. struct ACD_CPDReqEnergyTransferModeType ACD_CPDReqEnergyTransferMode;
  1717. };
  1718. /****ChargeParameterDiscoveryResponse****/
  1719. struct ChargeParameterDiscoveryResponse_DIN70121
  1720. {
  1721. enum ResponseCodeType_DIN70121 ResponseCode;
  1722. enum EVSEProcessingType_DIN70121 EVSEProcessing;
  1723. struct SAScheduleListType SAScheduleList;
  1724. struct DC_EVSEChargeParameterType_DIN70121 DC_EVSEChargeParameter;
  1725. };
  1726. struct ChargeParameterDiscoveryResponse_ISO15118_2014
  1727. {
  1728. enum EVSEProcessingType_ISO15118_2014 EVSEProcessing;
  1729. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1730. struct SAScheduleListType SAScheduleList;
  1731. struct AC_EVSEChargeParameterType AC_EVSEChargeParameter;
  1732. struct DC_EVSEChargeParameterType_ISO15118_2014 DC_EVSEChargeParameter;
  1733. };
  1734. struct ChargeParameterDiscoveryResponse_ISO15118_2018
  1735. {
  1736. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1737. struct EVSEStatusType EVSEStatus; //Optional
  1738. enum ProcessingType EVSEProcessing;
  1739. struct Scheduled_CPDResControlModeType Scheduled_CPDResControlMode; //Optional
  1740. struct AC_CPDResEnergyTransferModeType AC_CPDResEnergyTransferMode;
  1741. struct DC_CPDResEnergyTransferModeType DC_CPDResEnergyTransferMode;
  1742. struct BPT_AC_CPDResEnergyTransferModeType BPT_AC_CPDResEnergyTransferMode;
  1743. struct BPT_DC_CPDResEnergyTransferModeType BPT_DC_CPDResEnergyTransferMode;
  1744. struct WPT_CPDResEnergyTransferModeType WPT_CPDResEnergyTransferMode;
  1745. struct ACD_CPDResEnergyTransferModeType ACD_CPDResEnergyTransferMode;
  1746. };
  1747. /****PowerDeliveryRequest****/
  1748. struct PowerDeliveryRequest_DIN70121
  1749. {
  1750. BOOL ReadyToChargeState;
  1751. struct ChargingProfileType_DIN70121 ChargingProfile;
  1752. struct DC_EVPowerDeliveryParameterType_DIN70121 DC_EVPowerDeliveryParameter;
  1753. };
  1754. struct PowerDeliveryRequest_ISO15118_2014
  1755. {
  1756. enum ChargeProgressType_ISO15118_2014 ChargeProgress;
  1757. short SAScheduleTupleID;
  1758. struct ChargingProfileType_ISO15118_2014 ChargingProfile;
  1759. struct DC_EVPowerDeliveryParameterType_ISO15118_2014 DC_EVPowerDeliveryParameter;
  1760. };
  1761. struct PowerDeliveryRequest_ISO15118_2018
  1762. {
  1763. enum ChargeProgressType_ISO15118_2018 ChargeProgress;
  1764. struct Scheduled_PDReqControlModeType Scheduled_PDReqControlMode;
  1765. struct BPT_Scheduled_PDReqControlModeType BPT_Scheduled_PDReqControlMode;
  1766. };
  1767. /****PowerDeliveryResponse****/
  1768. struct PowerDeliveryResponse_DIN70121
  1769. {
  1770. enum ResponseCodeType_DIN70121 ResponseCode;
  1771. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  1772. };
  1773. struct PowerDeliveryResponse_ISO15118_2014
  1774. {
  1775. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1776. struct AC_EVSEStatusType AC_EVSEStatus;
  1777. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  1778. };
  1779. struct PowerDeliveryResponse_ISO15118_2018
  1780. {
  1781. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1782. struct EVSEStatusType EVSEStatus; //Optional
  1783. };
  1784. /****CertificateUpdateRequest****/
  1785. struct CertificateUpdateRequest_ISO15118_2014
  1786. {
  1787. unsigned char Id[32];
  1788. struct CertificateChainType ContractSignatureCertChain;
  1789. unsigned char eMAID[16];
  1790. struct ListOfRootCertificateIDsType ListOfRootCertificateIDs;
  1791. };
  1792. /****CertificateUpdateResponse****/
  1793. struct CertificateUpdateResponse_ISO15118_2014
  1794. {
  1795. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1796. struct CertificateChainType SAProvisioningCertificateChain;
  1797. struct CertificateChainType ContractSignatureCertChain;
  1798. struct ContractSignatureEncryptedPrivateKeyType ContractSignatureEncryptedPrivateKey;
  1799. struct DiffieHellmanPublickeyType DHpublickey;
  1800. unsigned char eMAID[16];
  1801. short RetryCounter; //Optional
  1802. };
  1803. /****CertificateInstallationRequest****/
  1804. struct CertificateInstallationRequest_ISO15118_2014
  1805. {
  1806. unsigned char Id[32];
  1807. unsigned char OEMProvisioningCert[800];
  1808. struct ListOfRootCertificateIDsType ListOfRootCertificateIDs;
  1809. };
  1810. struct CertificateInstallationRequest_ISO15118_2018
  1811. {
  1812. unsigned char Id[32];
  1813. struct CertificateChainType OEMProvisioningCertChain;
  1814. struct ListOfRootCertificateIDsType ListOfRootCertificateIDs;
  1815. unsigned short MaxSupportedCerts;
  1816. };
  1817. /****CertificateInstallationResponse****/
  1818. struct CertificateInstallationResponse_ISO15118_2014
  1819. {
  1820. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1821. struct CertificateChainType SAProvisioningCertificateChain;
  1822. struct CertificateChainType ContractSignatureCertChain;
  1823. struct ContractSignatureEncryptedPrivateKeyType ContractSignatureEncryptedPrivateKey;
  1824. struct DiffieHellmanPublickeyType DHpublickey;
  1825. unsigned char eMAID[16];
  1826. };
  1827. struct CertificateInstallationResponse_ISO15118_2018
  1828. {
  1829. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1830. struct EVSEStatusType EVSEStatus; //Optional
  1831. struct CertificateChainType SAProvisioningCertificateChain;
  1832. struct CertificateChainType ContractCertificateChain;
  1833. struct ContractCertificateEncryptedPrivateKeyType ContractEncryptedPrivateKey;
  1834. struct DiffieHellmanPublickeyType DHpublickey;
  1835. enum ProcessingType EVSEProcessing;
  1836. unsigned short RemainingContractCertificateChains;
  1837. };
  1838. /****SystemStatusRequest****/
  1839. struct SystemStatusRequest_ISO15118_2018
  1840. {
  1841. enum mechanicalChargingDeviceStatusType EVMechanicalChargingDeviceStatus;
  1842. struct EVTechnicalStatusType EVTechnicalStatus;
  1843. unsigned char EV_OEMStatus[800]; //Optional
  1844. };
  1845. /****SystemStatusResponse****/
  1846. struct SystemStatusResponse_ISO15118_2018
  1847. {
  1848. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1849. enum mechanicalChargingDeviceStatusType EVSEMechanicalChargingDeviceStatus;
  1850. BOOL EVSE_ReadyToCharge;
  1851. enum IsolationStatusType EVSE_IsolationStatus;
  1852. BOOL EVSE_Disabled;
  1853. BOOL EVSE_UtilityInterruptEvent;
  1854. BOOL EVSE_EmergencyShutdown;
  1855. BOOL EVSE_Malfunction;
  1856. BOOL EV_InChargePosition;
  1857. BOOL EV_AssociationStatus;
  1858. };
  1859. /****SessionStopRequest****/
  1860. struct SessionStopRequest_DIN70121
  1861. {
  1862. //No member in standard
  1863. };
  1864. struct SessionStopRequest_ISO15118_2014
  1865. {
  1866. enum ChargingSessionType ChargingSession;
  1867. };
  1868. struct SessionStopRequest_ISO15118_2018
  1869. {
  1870. enum ChargingSessionType ChargingSession;
  1871. };
  1872. /****SessionStopResponse****/
  1873. struct SessionStopResponse_DIN70121
  1874. {
  1875. enum ResponseCodeType_DIN70121 ResponseCode;
  1876. };
  1877. struct SessionStopResponse_ISO15118_2014
  1878. {
  1879. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1880. };
  1881. struct SessionStopResponse_ISO15118_2018
  1882. {
  1883. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1884. struct EVSEStatusType EVSEStatus; //Optional
  1885. };
  1886. /****MeteringReceiptRequest****/
  1887. struct MeteringReceiptRequest_ISO15118_2014
  1888. {
  1889. unsigned char Id[32]; //Optional
  1890. unsigned char SessionID[8];
  1891. short SAScheduleTupleID; //Optional
  1892. struct MeterInfoType_ISO15118_2014 MeterInfo;
  1893. };
  1894. struct MeteringReceiptRequest_ISO15118_2018
  1895. {
  1896. unsigned char Id[32]; //Optional
  1897. unsigned char SessionID[8];
  1898. struct Scheduled_MRReqControlModeType Schedule_MRReqControlMode;
  1899. struct MeterInfoType_ISO15118_2018 MeterInfo;
  1900. };
  1901. /****MeteringReceiptResponse****/
  1902. struct MeteringReceiptResponse_ISO15118_2014
  1903. {
  1904. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1905. struct AC_EVSEStatusType AC_EVSEStatus;
  1906. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  1907. };
  1908. struct MeteringReceiptResponse_ISO15118_2018
  1909. {
  1910. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1911. struct EVSEStatusType EVSEStatus; //Optional
  1912. };
  1913. /****ChargingStatusRequest (AC Only)****/
  1914. struct ChargingStatusRequest_ISO15118_2014
  1915. {
  1916. //No member in standard
  1917. };
  1918. struct ChargingStatusRequest_ISO15118_2018
  1919. {
  1920. struct PnC_CLReqIdentificationModeType PnC_CLReqIdentificationMode;
  1921. struct Dynamic_CSReqControlModeType Dynamic_CSReqControlMode;
  1922. struct Scheduled_CSReqControlModeType Scheduled_CSReqControlMode;
  1923. struct DisplayParametersType DisplayParameters;
  1924. };
  1925. /****ChargingStatusResponse (AC Only)****/
  1926. struct ChargingStatusResponse_ISO15118_2014
  1927. {
  1928. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1929. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  1930. short SAScheduleTupleID;
  1931. struct PhysicalValueType_ISO15118_2014 EVSEMaxCurrent; //Optional
  1932. struct MeterInfoType_ISO15118_2014 MeterInfo; //Optional
  1933. BOOL ReceiptRequired; //Optional
  1934. struct AC_EVSEStatusType AC_EVSEStatus;
  1935. };
  1936. struct ChargingStatusResponse_ISO15118_2018
  1937. {
  1938. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1939. struct EVSEStatusType EVSEStatus; //Optional
  1940. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  1941. struct PhysicalValueType_ISO15118_2018 EVSETargetFrequency; //Optional
  1942. struct PnC_CLResIdentificationModeType PnC_CLResIdentificationMode;
  1943. struct Dynamic_CSResControlModeType Dynamic_CSResControlMode;
  1944. struct Scheduled_CSReqControlModeType Scheduled_CSReqControlMode;
  1945. };
  1946. /****CableCheckRequest (DC Only)****/
  1947. struct CableCheckRequest_DIN70121
  1948. {
  1949. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  1950. };
  1951. struct CableCheckRequest_ISO15118_2014
  1952. {
  1953. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  1954. };
  1955. struct CableCheckRequest_ISO15118_2018
  1956. {
  1957. //No member in standard
  1958. };
  1959. /****CableCheckResponse (DC Only)****/
  1960. struct CableCheckResponse_DIN70121
  1961. {
  1962. enum ResponseCodeType_DIN70121 ResponseCode;
  1963. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  1964. enum EVSEProcessingType_DIN70121 EVSEProcessing;
  1965. };
  1966. struct CableCheckResponse_ISO15118_2014
  1967. {
  1968. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  1969. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  1970. enum EVSEProcessingType_ISO15118_2014 EVSEProcessing;
  1971. };
  1972. struct CableCheckResponse_ISO15118_2018
  1973. {
  1974. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  1975. struct EVSEStatusType EVSEStatus; //Optional
  1976. enum ProcessingType EVSEProcessing;
  1977. };
  1978. /****PreChargeRequest (DC Only)****/
  1979. struct PreChargeRequest_DIN70121
  1980. {
  1981. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  1982. struct PhysicalValueType_DIN70121 EVTargetVoltage;
  1983. struct PhysicalValueType_DIN70121 EVTargetCurrent;
  1984. };
  1985. struct PreChargeRequest_ISO15118_2014
  1986. {
  1987. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  1988. struct PhysicalValueType_ISO15118_2014 EVTargetVoltage;
  1989. struct PhysicalValueType_ISO15118_2014 EVTargetCurrent;
  1990. };
  1991. struct PreChargeRequest_ISO15118_2018
  1992. {
  1993. struct PhysicalValueType_ISO15118_2018 EVTargetVoltage;
  1994. struct PhysicalValueType_ISO15118_2018 EVTargetCurrent;
  1995. };
  1996. /****PreChargeResponse (DC Only)****/
  1997. struct PreChargeResponse_DIN70121
  1998. {
  1999. enum ResponseCodeType_DIN70121 ResponseCode;
  2000. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  2001. struct PhysicalValueType_DIN70121 EVSEPresentVoltage;
  2002. };
  2003. struct PreChargeResponse_ISO15118_2014
  2004. {
  2005. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  2006. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  2007. struct PhysicalValueType_ISO15118_2014 EVSEPresentVoltage;
  2008. };
  2009. struct PreChargeResponse_ISO15118_2018
  2010. {
  2011. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  2012. struct EVSEStatusType EVSEStatus; //Optional
  2013. struct PhysicalValueType_ISO15118_2018 EVSEPresentVoltage;
  2014. };
  2015. /****CurrentDemandRequest (DC Only)****/
  2016. struct CurrentDemandRequest_DIN70121
  2017. {
  2018. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  2019. struct PhysicalValueType_DIN70121 EVTargetCurrent;
  2020. struct PhysicalValueType_DIN70121 EVMaximumVoltageLimit; //Optional
  2021. struct PhysicalValueType_DIN70121 EVMaximumCurrentLimit; //Optional
  2022. struct PhysicalValueType_DIN70121 EVMaximumPowerLimit; //Optional
  2023. BOOL BulkChargingComplete; //Optional
  2024. BOOL ChargingComplete;
  2025. struct PhysicalValueType_DIN70121 RemainingTimeToFullSoC; //Optional
  2026. struct PhysicalValueType_DIN70121 RemainingTimeToBulkSoC; //Optional
  2027. struct PhysicalValueType_DIN70121 EVTargetVoltage;
  2028. };
  2029. struct CurrentDemandRequest_ISO15118_2014
  2030. {
  2031. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  2032. struct PhysicalValueType_ISO15118_2014 EVTargetCurrent;
  2033. struct PhysicalValueType_ISO15118_2014 EVMaximumVoltageLimit; //Optional
  2034. struct PhysicalValueType_ISO15118_2014 EVMaximumCurrentLimit; //Optional
  2035. struct PhysicalValueType_ISO15118_2014 EVMaximumPowerLimit; //Optional
  2036. BOOL BulkChargingComplete; //Optional
  2037. BOOL ChargingComplete;
  2038. struct PhysicalValueType_ISO15118_2014 RemainingTimeToFullSoC; //Optional
  2039. struct PhysicalValueType_ISO15118_2014 RemainingTimeToBulkSoC; //Optional
  2040. struct PhysicalValueType_ISO15118_2014 EVTargetVoltage;
  2041. };
  2042. struct CurrentDemandRequest_ISO15118_2018
  2043. {
  2044. struct DisplayParametersType DisplayParameters; //Optional
  2045. struct PnC_CLReqIdentificationModeType PnC_CLReqIdentificationMode;
  2046. struct Dynamic_CSReqControlModeType Dynamic_CDReqControlMode;
  2047. struct Scheduled_CSReqControlModeType Scheduled_CDReqControlMode;
  2048. };
  2049. /****CurrentDemandResponse (DC Only)****/
  2050. struct CurrentDemandResponse_DIN70121
  2051. {
  2052. enum ResponseCodeType_DIN70121 ResponseCode;
  2053. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  2054. struct PhysicalValueType_DIN70121 EVSEPresentVoltage;
  2055. struct PhysicalValueType_DIN70121 EVSEPresentCurrent;
  2056. BOOL EVSECurrentLimitAchieved;
  2057. BOOL EVSEVoltageLimitAchieved;
  2058. BOOL EVSEPowerLimitAchieved;
  2059. struct PhysicalValueType_DIN70121 EVSEMaximumVoltageLimit; //Optional
  2060. struct PhysicalValueType_DIN70121 EVSEMaximumCurrentLimit; //Optional
  2061. struct PhysicalValueType_DIN70121 EVSEMaximumPowerLimit; //Optional
  2062. };
  2063. struct CurrentDemandResponse_ISO15118_2014
  2064. {
  2065. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  2066. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  2067. struct PhysicalValueType_ISO15118_2014 EVSEPresentVoltage;
  2068. struct PhysicalValueType_ISO15118_2014 EVSEPresentCurrent;
  2069. BOOL EVSECurrentLimitAchieved;
  2070. BOOL EVSEVoltageLimitAchieved;
  2071. BOOL EVSEPowerLimitAchieved;
  2072. struct PhysicalValueType_ISO15118_2014 EVSEMaximumVoltageLimit; //Optional
  2073. struct PhysicalValueType_ISO15118_2014 EVSEMaximumCurrentLimit; //Optional
  2074. struct PhysicalValueType_ISO15118_2014 EVSEMaximumPowerLimit; //Optional
  2075. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  2076. short SAScheduleTupleID;
  2077. struct MeterInfoType_ISO15118_2014 MeterInfo; //Optional
  2078. BOOL ReceiptRequired; //Optional
  2079. };
  2080. struct CurrentDemandResponse_ISO15118_2018
  2081. {
  2082. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  2083. struct EVSEStatusType EVSEStatus; //Optional
  2084. struct PhysicalValueType_ISO15118_2018 EVSEPresentVoltage;
  2085. struct PhysicalValueType_ISO15118_2018 EVSEPresentCurrent;
  2086. BOOL EVSECurrentLimitAchieved;
  2087. BOOL EVSEVoltageLimitAchieved;
  2088. BOOL EVSEPowerLimitAchieved;
  2089. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeVoltage; //Optional
  2090. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargeCurrent; //Optional
  2091. struct PhysicalValueType_ISO15118_2018 EVSEMaximumChargePower; //Optional
  2092. unsigned char EVSEID[40]; //DIN70121=>Max length:32, ISO15118=>min length:7, max length:37
  2093. struct PnC_CLResIdentificationModeType PnC_CLResIdentificationMode;
  2094. struct Scheduled_CDResControlModeType Scheduled_CDResControlMode;
  2095. };
  2096. /****WeldingDetectionRequest (DC Only)*****/
  2097. struct WeldingDetectionRequest_DIN70121
  2098. {
  2099. struct DC_EVStatusType_DIN70121 DC_EVStatus;
  2100. };
  2101. struct WeldingDetectionRequest_ISO15118_2014
  2102. {
  2103. struct DC_EVStatusType_ISO15118_2014 DC_EVStatus;
  2104. };
  2105. struct WeldingDetectionRequest_ISO15118_2018
  2106. {
  2107. //No member in Standard
  2108. };
  2109. /****WeldingDetectionResponse (DC Only)****/
  2110. struct WeldingDetectionResponse_DIN70121
  2111. {
  2112. enum ResponseCodeType_DIN70121 ResponseCode;
  2113. struct DC_EVSEStatusType_DIN70121 DC_EVSEStatus;
  2114. struct PhysicalValueType_DIN70121 EVSEPresentVoltage;
  2115. };
  2116. struct WeldingDetectionResponse_ISO15118_2014
  2117. {
  2118. enum ResponseCodeType_ISO15118_2014 ResponseCode;
  2119. struct DC_EVSEStatusType_ISO15118_2014 DC_EVSEStatus;
  2120. struct PhysicalValueType_ISO15118_2014 EVSEPresentVoltage;
  2121. };
  2122. struct WeldingDetectionResponse_ISO15118_2018
  2123. {
  2124. enum ResponseCodeType_ISO15118_2018 ResponseCode;
  2125. struct EVSEStatusType EVSEStatus; //Optional
  2126. struct PhysicalValueType_ISO15118_2018 EVSEPresentVoltage;
  2127. };
  2128. /****FinePositioningSetupRequest (WPT Only)****/
  2129. struct FinePositioningSetupRequest_ISO15118_2018
  2130. {
  2131. struct LFA_EVFinePositioningSetupParametersType LFA_EVFinePositioningSetupParameters; //Optional
  2132. };
  2133. /****FinePositioningSetupResponse (WPT Only)****/
  2134. struct FinePositioningSetupResponse_ISO15118_2018
  2135. {
  2136. //NOT complete yet, to be continue.....
  2137. };
  2138. struct V2GMessageType_DIN70121
  2139. {
  2140. unsigned char PresentMsgFlowStatus;
  2141. /* 0: Idle(wait B2 state), 1: CM_SLAC_PARM.REQ, 2: CM_SLAC_PARM.CNF, 3: CM_START_ATTEN_CHAR.IND
  2142. 4: CM_MNBC_SOUND.IND, 5: CM_ATTEN_CHAR.IND, 6: CM_ATTEN_CHAR.RSP, 7: CM_VALIDATE.REQ
  2143. 8: CM_VALIDATE.CNF, 9: CM_SLAC_MATCH.REQ, 10: CM_SLAC_MATCH.CNF, 11: CM_AMP_MAP.REQ
  2144. 12: CM_AMP_MAP.CNF, 13: SLACC/SDP/TCP connection,
  2145. 16: SupportedAppProtocolRequest, 17: SupportedAppProtocolResponse, 18: SessionSetupRequest
  2146. 19: SessionSetupResponse, 20: ServiceDiscoveryRequest, 21: ServiceDiscoveryResponse
  2147. 22: ServiceDetailRequest, 23: ServiceDetailResponse
  2148. 24: ServiceAndPaymentSelectionRequest/ServiceSelectionRequest, 25: ServiceAndPaymentSelectionResponse/ServiceSelectionResponse
  2149. 26: PaymentDetailsRequest/IdentificationDetailsRequest;, 27: PaymentDetailsResponse/IdentificationDetailsResponse,
  2150. 28: AuthorizationRequest, 29: AuthorizationResponse,
  2151. 30: CertificateUpdateRequest, 31: CertificateUpdateResponse, 32:CertificateInstallationRequest, 33: CertificateInstallationResponse
  2152. 34: ChargeParameterDiscoveryRequest, 35: ChargeParameterDiscoveryResponse
  2153. 36: CableCheckRequest, 37: CableCheckResponse, 38: PreChargeRequest, 39: PreChargeResponse
  2154. 40: PowerDeliveryRequest start, 41: PowerDeliveryResponse start, 42: ChargingStatusRequest, 43: ChargingStatusResponse
  2155. 44: CurrentDemandRequest, 45: CurrentDemandResponse, 46: MeteringReceiptRequest, 47: MeteringReceiptResponse
  2156. 48: PowerDeliveryRequest end, 49: PowerDeliveryRequest end, 50: WeldingDetectionRequest, 51: WeldingDetectionResponse,
  2157. 52: SessionStopRequest, 53: SessionStopResponse
  2158. 253: Performance Timeout, 254: Sequence Timeout, 255: Fault
  2159. */
  2160. struct SupportedAppProtocolRequest_DIN70121 SupportedAppProtocolRequest;
  2161. struct SupportedAppProtocolResponse_DIN70121 SupportedAppProtocolResponse;
  2162. struct SessionSetupRequest_DIN70121 SessionSetupRequest;
  2163. struct SessionSetupResponse_DIN70121 SessionSetupResponse;
  2164. struct ServiceDiscoveryRequest_DIN70121 ServiceDiscoveryRequest;
  2165. struct ServiceDiscoveryResponse_DIN70121 ServiceDiscoveryResponse;
  2166. struct ServiceAndPaymentSelectionRequest_DIN70121 ServiceAndPaymentSelectionRequest;
  2167. struct ServiceAndPaymentSelectionResponse_DIN70121 ServiceAndPaymentSelectionResponse;
  2168. struct ContractAuthenticationRequest_DIN70121 ContractAuthenticationRequest;
  2169. struct ContractAuthenticationResponse_DIN70121 ContractAuthenticationResponse;
  2170. struct ChargeParameterDiscoveryRequest_DIN70121 ChargeParameterDiscoveryRequest;
  2171. struct ChargeParameterDiscoveryResponse_DIN70121 ChargeParameterDiscoveryResponse;
  2172. struct CableCheckRequest_DIN70121 CableCheckRequest;
  2173. struct CableCheckResponse_DIN70121 CableCheckResponse;
  2174. struct PreChargeRequest_DIN70121 PreChargeRequest;
  2175. struct PreChargeResponse_DIN70121 PreChargeResponse;
  2176. struct PowerDeliveryRequest_DIN70121 PowerDeliveryRequest;
  2177. struct PowerDeliveryResponse_DIN70121 PowerDeliveryResponse;
  2178. struct CurrentDemandRequest_DIN70121 CurrentDemandRequest;
  2179. struct CurrentDemandResponse_DIN70121 CurrentDemandResponse;
  2180. struct WeldingDetectionRequest_DIN70121 WeldingDetectionRequest;
  2181. struct WeldingDetectionResponse_DIN70121 WeldingDetectionResponse;
  2182. struct SessionStopRequest_DIN70121 SessionStopRequest;
  2183. struct SessionStopResponse_DIN70121 SessionStopResponse;
  2184. };
  2185. struct V2GMessageType_ISO15118_2014
  2186. {
  2187. unsigned char PresentMsgFlowStatus;
  2188. /* 0: Idle(wait B2 state), 1: CM_SLAC_PARM.REQ, 2: CM_SLAC_PARM.CNF, 3: CM_START_ATTEN_CHAR.IND
  2189. 4: CM_MNBC_SOUND.IND, 5: CM_ATTEN_CHAR.IND, 6: CM_ATTEN_CHAR.RSP, 7: CM_VALIDATE.REQ
  2190. 8: CM_VALIDATE.CNF, 9: CM_SLAC_MATCH.REQ, 10: CM_SLAC_MATCH.CNF, 11: CM_AMP_MAP.REQ
  2191. 12: CM_AMP_MAP.CNF, 13: SLACC/SDP/TCP connection,
  2192. 16: SupportedAppProtocolRequest, 17: SupportedAppProtocolResponse, 18: SessionSetupRequest
  2193. 19: SessionSetupResponse, 20: ServiceDiscoveryRequest, 21: ServiceDiscoveryResponse
  2194. 22: ServiceDetailRequest, 23: ServiceDetailResponse
  2195. 24: ServiceAndPaymentSelectionRequest/ServiceSelectionRequest, 25: ServiceAndPaymentSelectionResponse/ServiceSelectionResponse
  2196. 26: PaymentDetailsRequest/IdentificationDetailsRequest;, 27: PaymentDetailsResponse/IdentificationDetailsResponse,
  2197. 28: AuthorizationRequest, 29: AuthorizationResponse,
  2198. 30: CertificateUpdateRequest, 31: CertificateUpdateResponse, 32:CertificateInstallationRequest, 33: CertificateInstallationResponse
  2199. 34: ChargeParameterDiscoveryRequest, 35: ChargeParameterDiscoveryResponse
  2200. 36: CableCheckRequest, 37: CableCheckResponse, 38: PreChargeRequest, 39: PreChargeResponse
  2201. 40: PowerDeliveryRequest start, 41: PowerDeliveryResponse start, 42: ChargingStatusRequest, 43: ChargingStatusResponse
  2202. 44: CurrentDemandRequest, 45: CurrentDemandResponse, 46: MeteringReceiptRequest, 47: MeteringReceiptResponse
  2203. 48: PowerDeliveryRequest end, 49: PowerDeliveryRequest end, 50: WeldingDetectionRequest, 51: WeldingDetectionResponse,
  2204. 52: SessionStopRequest, 53: SessionStopResponse
  2205. 253: Performance Timeout, 254: Sequence Timeout, 255: Fault
  2206. */
  2207. struct SupportedAppProtocolRequest_ISO15118_2014 SupportedAppProtocolRequest;
  2208. struct SupportedAppProtocolResponse_ISO15118_2014 SupportedAppProtocolResponse;
  2209. struct SessionSetupRequest_ISO15118_2014 SessionSetupRequest;
  2210. struct SessionSetupResponse_ISO15118_2014 SessionSetupResponse;
  2211. struct ServiceDiscoveryRequest_ISO15118_2014 ServiceDiscoveryRequest;
  2212. struct ServiceDiscoveryResponse_ISO15118_2014 ServiceDiscoveryResponse;
  2213. struct ServiceDetailRequest_ISO15118_2014 ServiceDetailRequest;
  2214. struct ServiceDetailResponse_ISO15118_2014 ServiceDetailResponse;
  2215. struct ServiceAndPaymentSelectionRequest_ISO15118_2014 ServiceAndPaymentSelectionRequest;
  2216. struct ServiceAndPaymentSelectionResponse_ISO15118_2014 ServiceAndPaymentSelectionResponse;
  2217. struct PaymentDetailsRequest_ISO15118_2014 PaymentDetailsRequest;
  2218. struct PaymentDetailsResponse_ISO15118_2014 PaymentDetailsResponse;
  2219. struct AuthorizationRequest_ISO15118_2014 AuthorizationRequest;
  2220. struct AuthorizationResponse_ISO15118_2014 AuthorizationResponse;
  2221. struct CertificateUpdateRequest_ISO15118_2014 CertificateUpdateRequest;
  2222. struct CertificateUpdateResponse_ISO15118_2014 CertificateUpdateResponse;
  2223. struct CertificateInstallationRequest_ISO15118_2014 CertificateInstallationRequest;
  2224. struct CertificateInstallationResponse_ISO15118_2014 CertificateInstallationResponse;
  2225. struct ChargeParameterDiscoveryRequest_ISO15118_2014 ChargeParameterDiscoveryRequest;
  2226. struct ChargeParameterDiscoveryResponse_ISO15118_2014 ChargeParameterDiscoveryResponse;
  2227. struct CableCheckRequest_ISO15118_2014 CableCheckRequest;
  2228. struct CableCheckResponse_ISO15118_2014 CableCheckResponse;
  2229. struct PreChargeRequest_ISO15118_2014 PreChargeRequest;
  2230. struct PreChargeResponse_ISO15118_2014 PreChargeResponse;
  2231. struct PowerDeliveryRequest_ISO15118_2014 PowerDeliveryRequest;
  2232. struct PowerDeliveryResponse_ISO15118_2014 PowerDeliveryResponse;
  2233. struct ChargingStatusRequest_ISO15118_2014 ChargingStatusRequest;
  2234. struct ChargingStatusResponse_ISO15118_2014 ChargingStatusResponse;
  2235. struct CurrentDemandRequest_ISO15118_2014 CurrentDemandRequest;
  2236. struct CurrentDemandResponse_ISO15118_2014 CurrentDemandResponse;
  2237. struct MeteringReceiptRequest_ISO15118_2014 MeteringReceiptRequest;
  2238. struct MeteringReceiptResponse_ISO15118_2014 MeteringReceiptResponse;
  2239. struct WeldingDetectionRequest_ISO15118_2014 WeldingDetectionRequest;
  2240. struct WeldingDetectionResponse_ISO15118_2014 WeldingDetectionResponse;
  2241. struct SessionStopRequest_ISO15118_2014 SessionStopRequest;
  2242. struct SessionStopResponse_ISO15118_2014 SessionStopResponse;
  2243. };
  2244. struct V2GMessageType_ISO15118_2018
  2245. {
  2246. unsigned char PresentMsgFlowStatus;
  2247. /* 0: Idle(wait B2 state), 1: CM_SLAC_PARM.REQ, 2: CM_SLAC_PARM.CNF, 3: CM_START_ATTEN_CHAR.IND
  2248. 4: CM_MNBC_SOUND.IND, 5: CM_ATTEN_CHAR.IND, 6: CM_ATTEN_CHAR.RSP, 7: CM_VALIDATE.REQ
  2249. 8: CM_VALIDATE.CNF, 9: CM_SLAC_MATCH.REQ, 10: CM_SLAC_MATCH.CNF, 11: CM_AMP_MAP.REQ
  2250. 12: CM_AMP_MAP.CNF, 13: SLACC/SDP/TCP connection,
  2251. 16: SupportedAppProtocolRequest, 17: SupportedAppProtocolResponse, 18: SessionSetupRequest
  2252. 19: SessionSetupResponse, 20: ServiceDiscoveryRequest, 21: ServiceDiscoveryResponse
  2253. 22: ServiceDetailRequest, 23: ServiceDetailResponse
  2254. 24: ServiceAndPaymentSelectionRequest/ServiceSelectionRequest, 25: ServiceAndPaymentSelectionResponse/ServiceSelectionResponse
  2255. 26: PaymentDetailsRequest/IdentificationDetailsRequest;, 27: PaymentDetailsResponse/IdentificationDetailsResponse,
  2256. 28: AuthorizationRequest, 29: AuthorizationResponse,
  2257. 30: CertificateUpdateRequest, 31: CertificateUpdateResponse, 32:CertificateInstallationRequest, 33: CertificateInstallationResponse
  2258. 34: ChargeParameterDiscoveryRequest, 35: ChargeParameterDiscoveryResponse
  2259. 36: CableCheckRequest, 37: CableCheckResponse, 38: PreChargeRequest, 39: PreChargeResponse
  2260. 40: PowerDeliveryRequest start, 41: PowerDeliveryResponse start, 42: ChargingStatusRequest, 43: ChargingStatusResponse
  2261. 44: CurrentDemandRequest, 45: CurrentDemandResponse, 46: MeteringReceiptRequest, 47: MeteringReceiptResponse
  2262. 48: PowerDeliveryRequest end, 49: PowerDeliveryRequest end, 50: WeldingDetectionRequest, 51: WeldingDetectionResponse,
  2263. 52: SessionStopRequest, 53: SessionStopResponse
  2264. 253: Performance Timeout, 254: Sequence Timeout, 255: Fault
  2265. */
  2266. struct SupportedAppProtocolRequest_ISO15118_2018 SupportedAppProtocolRequest;
  2267. struct SupportedAppProtocolResponse_ISO15118_2018 SupportedAppProtocolResponse;
  2268. struct SessionSetupRequest_ISO15118_2018 SessionSetupRequest;
  2269. struct SessionSetupResponse_ISO15118_2018 SessionSetupResponse;
  2270. struct ServiceDiscoveryRequest_ISO15118_2018 ServiceDiscoveryRequest;
  2271. struct ServiceDiscoveryResponse_ISO15118_2018 ServiceDiscoveryResponse;
  2272. struct ServiceDetailRequest_ISO15118_2018 ServiceDetailRequest;
  2273. struct ServiceDetailResponse_ISO15118_2018 ServiceDetailResponse;
  2274. struct ServiceSelectionRequest_ISO15118_2018 ServiceSelectionRequest;
  2275. struct ServiceSelectionResponse_ISO15118_2018 ServiceSelectionResponse;
  2276. struct IdentificationDetailsRequest_ISO15118_2018 IdentificationDetailsRequest;
  2277. struct IdentificationDetailsResponse_ISO15118_2018 IdentificationDetailsResponse;
  2278. struct AuthorizationRequest_ISO15118_2018 AuthorizationRequest;
  2279. struct AuthorizationResponse_ISO15118_2018 AuthorizationResponse;
  2280. struct CertificateInstallationRequest_ISO15118_2018 CertificateInstallationRequest;
  2281. struct CertificateInstallationResponse_ISO15118_2018 CertificateInstallationResponse;
  2282. struct ChargeParameterDiscoveryRequest_ISO15118_2018 ChargeParameterDiscoveryRequest;
  2283. struct ChargeParameterDiscoveryResponse_ISO15118_2018 ChargeParameterDiscoveryResponse;
  2284. struct CableCheckRequest_ISO15118_2018 CableCheckRequest;
  2285. struct CableCheckResponse_ISO15118_2018 CableCheckResponse;
  2286. struct PreChargeRequest_ISO15118_2018 PreChargeRequest;
  2287. struct PreChargeResponse_ISO15118_2018 PreChargeResponse;
  2288. struct PowerDeliveryRequest_ISO15118_2018 PowerDeliveryRequest;
  2289. struct PowerDeliveryResponse_ISO15118_2018 PowerDeliveryResponse;
  2290. struct ChargingStatusRequest_ISO15118_2018 ChargingStatusRequest;
  2291. struct ChargingStatusResponse_ISO15118_2018 ChargingStatusResponse;
  2292. struct CurrentDemandRequest_ISO15118_2018 CurrentDemandRequest;
  2293. struct CurrentDemandResponse_ISO15118_2018 CurrentDemandResponse;
  2294. struct MeteringReceiptRequest_ISO15118_2018 MeteringReceiptRequest;
  2295. struct MeteringReceiptResponse_ISO15118_2018 MeteringReceiptResponse;
  2296. struct WeldingDetectionRequest_ISO15118_2018 WeldingDetectionRequest;
  2297. struct WeldingDetectionResponse_ISO15118_2018 WeldingDetectionResponse;
  2298. struct SessionStopRequest_ISO15118_2018 SessionStopRequest;
  2299. struct SessionStopResponse_ISO15118_2018 SessionStopResponse;
  2300. };
  2301. struct CcsData
  2302. {
  2303. unsigned char CommProtocol; // 1: V2GMessage_DIN70121, 2:V2GMessage_ISO15118_2014, 3:V2GMessage_ISO15118_2018
  2304. struct V2GMessageType_DIN70121 V2GMessage_DIN70121[CCS_QUANTITY];
  2305. struct V2GMessageType_ISO15118_2014 V2GMessage_ISO15118_2014[CCS_QUANTITY];
  2306. struct V2GMessageType_ISO15118_2018 V2GMessage_ISO15118_2018[CCS_QUANTITY];
  2307. };
  2308. /**************************************************************************************/
  2309. /***************STM32F407 Communication Share memory**************************/
  2310. /**************************************************************************************/
  2311. struct PrimaryMcuData
  2312. {
  2313. unsigned char SelfTest_Comp;
  2314. unsigned char version[16]; //STM32F407 firmware version
  2315. unsigned int InputVoltage; //value comes from external meter
  2316. unsigned int InputCurrent; //value comes from external meter
  2317. union
  2318. {
  2319. unsigned char OutputDrvValue[1];
  2320. struct
  2321. {
  2322. //OutputDrvValue[0]
  2323. unsigned char AcContactorDrv:1; //bit 0, H: ON, L:OFF
  2324. unsigned char Button1LedDrv:1; //bit 1, H: ON, L:OFF
  2325. unsigned char Button2LedDrv:1; //bit 2, H: ON, L:OFF
  2326. unsigned char SystemLed1Drv:1; //bit 3, H: ON, L:OFF
  2327. unsigned char SystemLed2Drv:1; //bit 4, H: ON, L:OFF
  2328. unsigned char SystemLed3Drv:1; //bit 5, H: ON, L:OFF
  2329. unsigned char SystemLed4Drv:1; //bit 6, H: ON, L:OFF
  2330. unsigned char:1; //bit 7 reserved
  2331. }bits;
  2332. }OutputDrv;
  2333. union
  2334. {
  2335. unsigned char InputDetValue[2];
  2336. struct
  2337. {
  2338. //InputDetValue[0]
  2339. unsigned char AcContactorDetec:1; //bit 0, H: ON, L:OFF
  2340. unsigned char AcMainBreakerDetec:1; //bit 1, H: ON, L:OFF
  2341. unsigned char SpdDetec:1; //bit 2, H: ON, L:OFF
  2342. unsigned char DoorOpen:1; //bit 3, H: Open, L:Close
  2343. unsigned char Gfd1:1; //bit 4, H: Trigger, L:Normal
  2344. unsigned char Gfd2:1; //bit 5, H: Trigger, L:Normal
  2345. unsigned char Button1:1; //bit 6 , H: Push, L:Release
  2346. unsigned char Button2:1; //bit 7, H: Push, L:Release
  2347. //InputDetValue[1]
  2348. unsigned char EmergencyButton:1; //bit 0, H: Push, L:Release
  2349. unsigned char :7; //bit 1~7, Reserved
  2350. }bits;
  2351. }InputDet;
  2352. };
  2353. /**************************************************************************************/
  2354. /*************Fan power module Communication Share memory******************/
  2355. /**************************************************************************************/
  2356. struct FanModuleData
  2357. {
  2358. unsigned char version[16]; //fan power module firmware version
  2359. unsigned short PresentFan1Speed; //RPM
  2360. unsigned short PresentFan2Speed; //RPM
  2361. unsigned short PresentFan3Speed; //RPM
  2362. unsigned short PresentFan4Speed; //RPM
  2363. unsigned short SetFan1Speed; //RPM
  2364. unsigned short SetFan2Speed; //RPM
  2365. unsigned short SetFan3Speed; //RPM
  2366. unsigned short SetFan4Speed; //RPM
  2367. unsigned char DiffOfAirPressure; //pa
  2368. unsigned char UpdateFW; //1:do update
  2369. };
  2370. /**************************************************************************************/
  2371. /***********Relay control module Communication Share memory******************/
  2372. /**************************************************************************************/
  2373. struct RelayModuleData
  2374. {
  2375. unsigned char version[16]; //fan power module firmware version
  2376. unsigned short InputL1Volt; //XXXXX.x volt
  2377. unsigned short InputL2Volt; //XXXXX.x volt
  2378. unsigned short InputL3Volt; //XXXXX.x volt
  2379. unsigned short Gun1FuseOutputVolt; //XXXXX.x volt
  2380. unsigned short Gun2FuseOutputVolt; //XXXXX.x volt
  2381. unsigned short Gun1RelayOutputVolt; //XXXXX.x volt
  2382. unsigned short Gun2RelayOutputVolt; //XXXXX.x volt
  2383. unsigned short Gun1OutputCurrent; //XXXXX.x amp
  2384. unsigned short Gun2OutputCurrent; //XXXXX.x amp
  2385. unsigned char UpdateFW; //1:do update
  2386. };
  2387. /**************************************************************************************/
  2388. /************************OCPP Share memory***************************************/
  2389. /**************************************************************************************/
  2390. struct StructIdTagInfo
  2391. {
  2392. unsigned char ExpiryDate[28];
  2393. unsigned char ParentIdTag[20];
  2394. unsigned char Status[16]; //Accepted, Blocked, Expired, Invalid, ConcurrentTx
  2395. };
  2396. struct StructLocalAuthorizationList
  2397. {
  2398. unsigned char IdTag[20];
  2399. struct StructIdTagInfo IdTagInfo;
  2400. };
  2401. struct StructSampledValue
  2402. {
  2403. unsigned char Value[128];
  2404. unsigned char Context[20];//Interruption.Begin, Interruption.End, Sample.Clock, Sample.Periodic, Transaction.Begin, Transaction.End, Trigger, Other
  2405. unsigned char Format[12];//Raw,SignedData
  2406. unsigned char Measurand[32];/* "Energy.Active.Export.Register",
  2407. "Energy.Active.Import.Register",
  2408. "Energy.Reactive.Export.Register",
  2409. "Energy.Reactive.Import.Register",
  2410. "Energy.Active.Export.Interval",
  2411. "Energy.Active.Import.Interval",
  2412. "Energy.Reactive.Export.Interval",
  2413. "Energy.Reactive.Import.Interval",
  2414. "Power.Active.Export",
  2415. "Power.Active.Import",
  2416. "Power.Offered",
  2417. "Power.Reactive.Export",
  2418. "Power.Reactive.Import",
  2419. "Power.Factor",
  2420. "Current.Import",
  2421. "Current.Export",
  2422. "Current.Offered",
  2423. "Voltage",
  2424. "Frequency",
  2425. "Temperature",
  2426. "SoC",
  2427. "RPM"
  2428. */
  2429. unsigned char Phase[8]; /* "L1",
  2430. "L2",
  2431. "L3",
  2432. "N",
  2433. "L1-N",
  2434. "L2-N",
  2435. "L3-N",
  2436. "L1-L2",
  2437. "L2-L3",
  2438. "L3-L1"
  2439. */
  2440. unsigned char Location[8]; //Cable,EV,Inlet,Outlet,Body
  2441. unsigned char Unit[12]; /* "Wh",
  2442. "kWh",
  2443. "varh",
  2444. "kvarh",
  2445. "W",
  2446. "kW",
  2447. "VA",
  2448. "kVA",
  2449. "var",
  2450. "kvar",
  2451. "A",
  2452. "V",
  2453. "K",
  2454. "Celcius",
  2455. "Fahrenheit",
  2456. "Percent"
  2457. */
  2458. };
  2459. struct StructMeterValue
  2460. {
  2461. unsigned char TimeStamp[28];
  2462. struct StructSampledValue *SampledValue;
  2463. };
  2464. struct StructConfigurationKeyItems
  2465. {
  2466. unsigned char Item[50];
  2467. };
  2468. struct StructConfigurationKey
  2469. {
  2470. unsigned char Key[50];
  2471. unsigned char ReadOnly[8]; //boolean
  2472. unsigned char Value[500];
  2473. };
  2474. struct StructChargingSchedulePeriod
  2475. {
  2476. int StartPeriod;
  2477. float Limit;//0.1;
  2478. int NumberPhases;
  2479. };
  2480. struct StructChargingSchedule
  2481. {
  2482. int Duration;
  2483. unsigned char StartSchedule[28];
  2484. unsigned char ChargingRateUnit[4]; //A, W
  2485. struct StructChargingSchedulePeriod *ChargingSchedulePeriod;
  2486. float MinChargingRate; //0.1;
  2487. };
  2488. struct StructChargingProfile
  2489. {
  2490. int ChargingProfileId;
  2491. int TransactionId;
  2492. int StackLevel;
  2493. unsigned char ChargingProfilePurpose[24]; //ChargePointMaxProfile, TxDefaultProfile, TxProfile
  2494. unsigned char ChargingProfileKind[12]; //Absolute, Recurring, Relative
  2495. unsigned char RecurrencyKind[8]; //Daily, Weekly
  2496. unsigned char ValidFrom[28];
  2497. unsigned char ValidTo[28];
  2498. struct StructChargingSchedule ChargingSchedule;
  2499. };
  2500. struct StructBootNotification
  2501. {
  2502. unsigned char CpVendor[20]; //chargePointVendor //mandatory
  2503. unsigned char CpModel[20]; //chargePointModel //mandatory
  2504. unsigned char CpSN[25]; //chargePointSerialNumber
  2505. unsigned char CbSN[25]; //chargeBoxSerialNumber
  2506. unsigned char CpFwVersion[50]; //firmwareVersion
  2507. unsigned char CpIccid[20]; //iccid
  2508. unsigned char CpImsi[20]; //imsi
  2509. unsigned char CpMeterType[25]; //meterType
  2510. unsigned char CpMeterSerialNumber[25]; //meterSerialNumber
  2511. unsigned char ResponseStatus[16]; //Accepted, Pending, Rejected
  2512. unsigned char ResponseCurrentTime[28]; //currentTime //mandatory
  2513. int ResponseHeartbeatInterval; //interval //mandatory
  2514. };
  2515. struct StructHeartbeat
  2516. {
  2517. unsigned char ResponseCurrentTime[28];
  2518. };
  2519. struct StructAuthorize
  2520. {
  2521. unsigned char IdTag[20];
  2522. struct StructIdTagInfo ResponseIdTagInfo;
  2523. };
  2524. struct StructStartTransaction
  2525. {
  2526. int ConnectorId;
  2527. unsigned char IdTag[20];
  2528. int MeterStart;
  2529. int ReservationId;
  2530. unsigned char Timestamp[28];
  2531. struct StructIdTagInfo ResponseIdTagInfo;
  2532. int ResponseTransactionId;
  2533. };
  2534. struct StructStopTransaction
  2535. {
  2536. unsigned char IdTag[20];
  2537. int MeterStop;
  2538. unsigned char Timestamp[28];
  2539. int TransactionId;
  2540. unsigned char StopReason; /* "EmergencyStop",
  2541. "EVDisconnected",
  2542. "HardReset",
  2543. "Local",
  2544. "Other",
  2545. "PowerLoss",
  2546. "Reboot",
  2547. "Remote",
  2548. "SoftReset",
  2549. "UnlockCommand",
  2550. "DeAuthorized"
  2551. */
  2552. struct StructMeterValue *TransactionData;
  2553. struct StructIdTagInfo ResponseIdTagInfo;
  2554. };
  2555. struct StructStatusNotification
  2556. {
  2557. int ConnectorId;
  2558. unsigned char ErrorCode; /* "ConnectorLockFailure",
  2559. "EVCommunicationError",
  2560. "GroundFailure",
  2561. "HighTemperature",
  2562. "InternalError",
  2563. "LocalListConflict",
  2564. "NoError",
  2565. "OtherError",
  2566. "OverCurrentFailure",
  2567. "PowerMeterFailure",
  2568. "PowerSwitchFailure",
  2569. "ReaderFailure",
  2570. "ResetFailure",
  2571. "UnderVoltage",
  2572. "OverVoltage",
  2573. "WeakSignal"
  2574. */
  2575. unsigned char Info[50];
  2576. unsigned char Status; /* "Available",
  2577. "Preparing",
  2578. "Charging",
  2579. "SuspendedEVSE",
  2580. "SuspendedEV",
  2581. "Finishing",
  2582. "Reserved",
  2583. "Unavailable",
  2584. "Faulted"
  2585. */
  2586. unsigned char Timestamp[28];
  2587. unsigned char VendorId[256];
  2588. unsigned char VendorErrorCode[50];
  2589. };
  2590. struct StructCancelReservation
  2591. {
  2592. int ReservationId;
  2593. unsigned char ResponseStatus[16]; //Accepted, Rejected
  2594. };
  2595. struct StructChangeAvailability
  2596. {
  2597. int ConnectorId;
  2598. unsigned char Type[16]; //Inoperative, Operative
  2599. unsigned char ResponseStatus[16]; //Accepted, Rejected, Scheduled
  2600. };
  2601. struct StructChangeConfiguration
  2602. {
  2603. unsigned char Key[50];
  2604. unsigned char Value[500];
  2605. unsigned char ResponseStatus[16]; //Accepted, Rejected, RebootRequired, NotSupported
  2606. };
  2607. struct StructClearCache
  2608. {
  2609. unsigned char ResponseStatus[16]; //Accepted, Rejected
  2610. };
  2611. struct StructClearChargingProfile
  2612. {
  2613. int Id;
  2614. int ConnectorId;
  2615. unsigned char ChargingProfilePurpose[24]; //ChargePointMaxProfile, TxDefaultProfile, TxProfile
  2616. int StackLevel;
  2617. unsigned char ResponseStatus[16]; //Accepted, Unknown
  2618. };
  2619. struct StructDataTransfer
  2620. {
  2621. unsigned char VendorId[256];
  2622. unsigned char MessageId[52];
  2623. unsigned char Data[512];
  2624. unsigned char ResponseStatus[18]; //Accepted, Rejected,UnknownMessageId,UnknownVendorId
  2625. unsigned char ResponseData[256];
  2626. };
  2627. struct StructDiagnosticsStatusNotification
  2628. {
  2629. unsigned char Status[16]; //Idle,Uploaded,UploadFailed,Uploading
  2630. };
  2631. struct StructFirmwareStatusNotification
  2632. {
  2633. unsigned char Status[20]; //Downloaded,DownloadFailed,Downloading,Idle,InstallationFailed,Installing,Installed
  2634. };
  2635. struct StructGetCompositeSchedule
  2636. {
  2637. int ConnectorId;
  2638. int Duration;
  2639. unsigned char ChargingRateUnit[4]; //A,W
  2640. unsigned char ResponseStatus[12]; //Accepted,Rejected
  2641. int ResponseConnectorId;
  2642. unsigned char ResponseScheduleStart[28];
  2643. struct StructChargingSchedule ResponseChargingSchedule;
  2644. };
  2645. struct StructGetConfiguration
  2646. {
  2647. struct StructConfigurationKeyItems *Key;
  2648. struct StructConfigurationKey *ResponseConfigurationKey;
  2649. struct StructConfigurationKeyItems *ResponseUnknownKey;
  2650. };
  2651. struct StructGetDiagnostics
  2652. {
  2653. unsigned char Location[256];
  2654. int Retries;
  2655. int RetryInterval;
  2656. unsigned char StartTime[28];
  2657. unsigned char StopTime[28];
  2658. unsigned char ResponseFileName[256];
  2659. };
  2660. struct StructGetLocalListVersion
  2661. {
  2662. int ResponseListVersion;
  2663. };
  2664. struct StructMeterValues
  2665. {
  2666. int ConnectorId;
  2667. int TransactionId;
  2668. struct StructMeterValue *MeterValue;
  2669. };
  2670. struct StructRemoteStartTransaction
  2671. {
  2672. int ConnectorId;
  2673. unsigned char IdTag[20];
  2674. struct StructChargingProfile ChargingProfile;
  2675. unsigned char ResponseStatus[10]; //Accepted, Rejected
  2676. };
  2677. struct StructRemoteStopTransaction
  2678. {
  2679. int TransactionId;
  2680. unsigned char ResponseStatus[10]; //Accepted, Rejected
  2681. };
  2682. struct StructReserveNow
  2683. {
  2684. int ConnectorId;
  2685. unsigned char ExpiryDate[28];
  2686. unsigned char IdTag[20];
  2687. unsigned char ParentIdTag[20];
  2688. int ReservationId;
  2689. unsigned char ResponseStatus[12]; //Accepted, Faulted, Occupied, Rejected, Unavailable
  2690. };
  2691. struct StructReset
  2692. {
  2693. unsigned char Type[8]; //Hard, Soft
  2694. unsigned char ResponseStatus[10]; //Accepted, Rejected
  2695. };
  2696. struct StructSendLocalList
  2697. {
  2698. int ListVersion;
  2699. unsigned char UpdateType[16]; //Differential, Full
  2700. struct StructLocalAuthorizationList *LocalAuthorizationList;
  2701. unsigned char ResponseStatus[16]; //Accepted, Failed, NotSupported, VersionMismatch
  2702. };
  2703. struct StructSetChargingProfile
  2704. {
  2705. int ConnectorId;
  2706. struct StructChargingProfile ChargingProfile;
  2707. unsigned char ResponseStatus[16]; //Accepted, Rejected, NotSupported
  2708. };
  2709. struct StructTriggerMessage
  2710. {
  2711. unsigned char RequestedMessage[32]; /*
  2712. "BootNotification",
  2713. "DiagnosticsStatusNotification",
  2714. "FirmwareStatusNotification",
  2715. "Heartbeat",
  2716. "MeterValues",
  2717. "StatusNotification"
  2718. */
  2719. int ConnectorId;
  2720. unsigned char ResponseStatus[16]; //Accepted, Rejected, NotImplemented
  2721. };
  2722. struct StructUnlockConnector
  2723. {
  2724. int ConnectorId;
  2725. unsigned char ResponseStatus[16]; //Unlocked, UnlockFailed, NotSupported
  2726. };
  2727. struct StructUpdateFirmware
  2728. {
  2729. unsigned char Location[256];
  2730. int Retries;
  2731. unsigned char RetrieveDate[28];
  2732. int RetryInterval;
  2733. };
  2734. struct OCPP16ConfigurationItem
  2735. {
  2736. unsigned char ItemName[64];
  2737. unsigned char ItemAccessibility;//0:RO, 1:RW
  2738. unsigned char ItemData[128];
  2739. };
  2740. struct OCPP16ConfigurationTable
  2741. {
  2742. //please refer to OCPP 1.6 chapter 9
  2743. struct OCPP16ConfigurationItem CoreProfile[28];
  2744. struct OCPP16ConfigurationItem LocalAuthListManagementProfile[3];
  2745. struct OCPP16ConfigurationItem ReservationProfile[1];
  2746. struct OCPP16ConfigurationItem SmartChargingProfile[5];
  2747. };
  2748. struct OCPP16Data
  2749. {
  2750. unsigned char OcppServerURL[512]; //http: non-secure OCPP 1.5-S, https: secure OCPP 1.5-S, ws: non-secure OCPP 1.6-J, wss: secure OCPP 1.6-J"
  2751. unsigned char ChargeBoxId[128];
  2752. unsigned char OcppConnStatus; //0: disconnected, 1: connected
  2753. union
  2754. {
  2755. //Operations Initiated by Charge Point
  2756. unsigned char CpMsgValue[CHAdeMO_QUANTITY + CCS_QUANTITY + GB_QUANTITY];
  2757. struct
  2758. {
  2759. //CpMsgValue[0]
  2760. unsigned char DataTransferReq:1; //bit 0,
  2761. unsigned char DataTransferConf:1; //bit 1,
  2762. unsigned char StartTransactionReq:1; //bit 2,
  2763. unsigned char StartTransactionConf:1; //bit 3,
  2764. unsigned char StopTransactionReq:1; //bit 4,
  2765. unsigned char StopTransactionConf:1; //bit 5,
  2766. unsigned char :2; //bit 6,7 , reserved
  2767. } bits[CHAdeMO_QUANTITY + CCS_QUANTITY + GB_QUANTITY];
  2768. }CpMsg;
  2769. union
  2770. {
  2771. //Operations Initiated by Sequence Point
  2772. unsigned char SpMsgValue[1];
  2773. struct
  2774. {
  2775. //SpMsgValue[0]
  2776. unsigned char BootNotificationReq :1; //bit 0,
  2777. unsigned char BootNotificationConf :1; //bit 1,
  2778. unsigned char AuthorizeReq :1; //bit 2,
  2779. unsigned char AuthorizeConf :1; //bit 3,
  2780. unsigned char DiagnosticsStatusNotificationReq :1; //bit 4,
  2781. unsigned char DiagnosticsStatusNotificationConf :1; //bit 5,
  2782. unsigned char FirmwareStatusNotificationReq :1; //bit 6,
  2783. unsigned char FirmwareStatusNotificationConf :1; //bit 7,
  2784. } bits;
  2785. } SpMsg;
  2786. union
  2787. {
  2788. //Operations Initiated by Central System
  2789. unsigned char CsMsgValue[3 * (CHAdeMO_QUANTITY + CCS_QUANTITY + GB_QUANTITY)];
  2790. struct
  2791. {
  2792. //CsMsgValue[0]
  2793. unsigned char CancelReservationReq :1; //bit 0,
  2794. unsigned char CancelReservationConf :1; //bit 1,
  2795. unsigned char ChangeAvailabilityReq :1; //bit 2,
  2796. unsigned char ChangeAvailabilityConf :1; //bit 3,
  2797. unsigned char ReserveNowReq :1; //bit 4,
  2798. unsigned char ReserveNowConf :1; //bit 5,
  2799. unsigned char SetChargingProfileReq :1; //bit 6,
  2800. unsigned char SetChargingProfileConf :1; //bit 7,
  2801. //CsMsgValue[1]
  2802. unsigned char TriggerMessageReq :1; //bit 0,
  2803. unsigned char TriggerMessageConf :1; //bit 1,
  2804. unsigned char UnlockConnectorReq :1; //bit 2,
  2805. unsigned char UnlockConnectorConf :1; //bit 3,
  2806. unsigned char RemoteStartTransactionReq :1; //bit 4,
  2807. unsigned char RemoteStartTransactionConf :1; //bit 5,
  2808. unsigned char RemoteStopTransactionReq :1; //bit 6,
  2809. unsigned char RemoteStopTransactionConf :1; //bit 7,
  2810. //CsMsgValue[2]
  2811. unsigned char ClearChargingProfileReq :1; //bit 0,
  2812. unsigned char ClearChargingProfileConf :1; //bit 1,
  2813. unsigned char DataTransferReq :1; //bit 2,
  2814. unsigned char DataTransferConf :1; //bit 3,
  2815. unsigned char GetCompositeScheduleReq :1; //bit 4,
  2816. unsigned char GetCompositeScheduleConf :1; //bit 5,
  2817. unsigned char :2; //bit 6,7
  2818. } bits[CHAdeMO_QUANTITY + CCS_QUANTITY + GB_QUANTITY];
  2819. }CsMsg;
  2820. union
  2821. {
  2822. //Operations Initiated by Main System
  2823. unsigned char MsMsgValue[2];
  2824. struct
  2825. {
  2826. //CsMsgValue[0]
  2827. unsigned char ChangeConfigurationReq :1; //bit 0,
  2828. unsigned char ChangeConfigurationConf :1; //bit 1,
  2829. unsigned char ClearCacheReq :1; //bit 2,
  2830. unsigned char ClearCacheConf :1; //bit 3,
  2831. unsigned char GetConfigurationReq :1; //bit 4,
  2832. unsigned char GetConfigurationConf :1; //bit 5,
  2833. unsigned char UpdateFirmwareReq :1; //bit 6,
  2834. unsigned char UpdateFirmwareConf :1; //bit 7,
  2835. //CsMsgValue[1]
  2836. unsigned char GetDiagnosticsReq :1; //bit 0,
  2837. unsigned char GetDiagnosticsConf :1; //bit 1,
  2838. unsigned char GetLocalListVersionReq :1; //bit 2,
  2839. unsigned char GetLocalListVersionConf :1; //bit 3,
  2840. unsigned char ResetReq :1; //bit 4,
  2841. unsigned char ResetConf :1; //bit 5,
  2842. unsigned char SendLocalListReq :1; //bit 6,
  2843. unsigned char SendLocalListConf :1; //bit 7,
  2844. } bits;
  2845. } MsMsg;
  2846. struct StructBootNotification BootNotification;
  2847. struct StructHeartbeat Heartbeat;
  2848. struct StructAuthorize Authorize;
  2849. struct StructStartTransaction StartTransaction[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2850. struct StructStopTransaction StopTransaction[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2851. struct StructStatusNotification StatusNotification[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2852. struct StructCancelReservation CancelReservation[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2853. struct StructChangeAvailability ChangeAvailability[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2854. struct StructChangeConfiguration ChangeConfiguration;
  2855. struct StructClearCache ClearCache;
  2856. struct StructClearChargingProfile ClearChargingProfile[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2857. struct StructDataTransfer DataTransfer[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2858. struct StructDiagnosticsStatusNotification DiagnosticsStatusNotification;
  2859. struct StructFirmwareStatusNotification FirmwareStatusNotification;
  2860. struct StructGetCompositeSchedule GetCompositeSchedule[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2861. struct StructGetConfiguration GetConfiguration;
  2862. struct StructGetDiagnostics GetDiagnostics;
  2863. struct StructGetLocalListVersion GetLocalListVersion;
  2864. struct StructMeterValues MeterValues[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2865. struct StructRemoteStartTransaction RemoteStartTransaction[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2866. struct StructRemoteStopTransaction RemoteStopTransaction[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2867. struct StructReserveNow ReserveNow[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2868. struct StructReset Reset;
  2869. struct StructSendLocalList SendLocalList;
  2870. struct StructSetChargingProfile SetChargingProfile[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2871. struct StructTriggerMessage TriggerMessage[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2872. struct StructUnlockConnector UnlockConnector[CHAdeMO_QUANTITY+ CCS_QUANTITY + GB_QUANTITY];
  2873. struct StructUpdateFirmware UpdateFirmware;
  2874. struct OCPP16ConfigurationTable ConfigurationTable;
  2875. struct StructChargingProfile CHAdeMOChargingProfile[CHAdeMO_QUANTITY];
  2876. struct StructChargingProfile CcsChargingProfile[CCS_QUANTITY];
  2877. };
  2878. #endif // DEFINE_H_