+ // See https://semver.org/#is-there-a-suggested-regular-expression-regex-to-check-a-semver-string
+ private static readonly SEMVER_PATTERN =
+ '^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$'
+
+ private static readonly DEFAULT_CHARGING_STATION_RESET_TIME = 30000 // Ms
+
+ static readonly DEFAULT_STATION_INFO: Partial<ChargingStationInfo> = Object.freeze({
+ enableStatistics: false,
+ autoStart: true,
+ remoteAuthorization: true,
+ currentOutType: CurrentType.AC,
+ mainVoltageMeterValues: true,
+ phaseLineToLineVoltageMeterValues: false,
+ customValueLimitationMeterValues: true,
+ ocppStrictCompliance: true,
+ outOfOrderEndMeterValues: false,
+ beginEndMeterValues: false,
+ meteringPerTransaction: true,
+ transactionDataMeterValues: false,
+ supervisionUrlOcppConfiguration: false,
+ supervisionUrlOcppKey: VendorParametersKey.ConnectionUrl,
+ useConnectorId0: true,
+ ocppVersion: OCPPVersion.VERSION_16,
+ firmwareVersionPattern: Constants.SEMVER_PATTERN,
+ firmwareUpgrade: {
+ versionUpgrade: {
+ step: 1
+ },
+ reset: true
+ },
+ ocppPersistentConfiguration: true,
+ stationInfoPersistentConfiguration: true,
+ automaticTransactionGeneratorPersistentConfiguration: true,
+ resetTime: Constants.DEFAULT_CHARGING_STATION_RESET_TIME,
+ autoReconnectMaxRetries: -1,
+ registrationMaxRetries: -1,
+ reconnectExponentialDelay: false,
+ stopTransactionsOnStopped: true
+ })
+
+ static readonly DEFAULT_BOOT_NOTIFICATION_INTERVAL = 60000 // Ms
+ static readonly DEFAULT_HEARTBEAT_INTERVAL = 60000 // Ms
+ static readonly DEFAULT_METER_VALUES_INTERVAL = 60000 // Ms
+
+ static readonly DEFAULT_ATG_WAIT_TIME = 1000 // Ms