| amperageLimitationOcppKey | | undefined | string | charging stations OCPP parameter key used to set the amperage limit, per phase for each connector on AC and global for DC |
| amperageLimitationUnit | A/cA/dA/mA | A | string | charging stations amperage limit unit |
| enableStatistics | true/false | false | boolean | enable charging stations statistics |
-| mustAuthorizeAtRemoteStart | true/false | true | boolean | always send authorize at remote start transaction when AuthorizeRemoteTxRequests is enabled |
+| remoteAuthorization | true/false | true | boolean | enable RFID tags remote authorization |
| beginEndMeterValues | true/false | false | boolean | enable Transaction.{Begin,End} MeterValues |
| outOfOrderEndMeterValues | true/false | false | boolean | send Transaction.End MeterValues out of order. Need to relax OCPP specifications strict compliance ('ocppStrictCompliance' parameter) |
| meteringPerTransaction | true/false | true | boolean | enable metering history on a per transaction basis |
return this.stationInfo.enableStatistics ?? false;
}
- public getMustAuthorizeAtRemoteStart(): boolean {
- return this.stationInfo.mustAuthorizeAtRemoteStart ?? true;
+ public getRemoteAuthorization(): boolean {
+ return this.stationInfo.remoteAuthorization ?? true;
}
public getNumberOfPhases(stationInfo?: ChargingStationInfo): number {
{ deprecatedKey: 'supervisionUrl', key: 'supervisionUrls' },
{ deprecatedKey: 'authorizationFile', key: 'idTagsFile' },
{ deprecatedKey: 'payloadSchemaValidation', key: 'ocppStrictCompliance' },
+ { deprecatedKey: 'mustAuthorizeAtRemoteStart', key: 'remoteAuthorization' },
];
for (const templateKey of templateKeys) {
warnDeprecatedTemplateKey(
OCPP16ChargePointStatus.Preparing,
);
const connectorStatus = chargingStation.getConnectorStatus(transactionConnectorId)!;
- if (
- chargingStation.getAuthorizeRemoteTxRequests() &&
- !chargingStation.getLocalAuthListEnabled() &&
- !chargingStation.getMustAuthorizeAtRemoteStart()
- ) {
- logger.warn(
- `${chargingStation.logPrefix()} The charging station configuration expects authorize at remote start transaction
- but local authorization or must authorize at remote start isn't enabled`,
- );
- }
// Authorization check required
if (
chargingStation.getAuthorizeRemoteTxRequests() === true &&
chargingStation.getConnectorStatus(transactionConnectorId)?.transactionRemoteStarted ===
true &&
chargingStation.getAuthorizeRemoteTxRequests() === true &&
- chargingStation.getMustAuthorizeAtRemoteStart() === true &&
+ chargingStation.getRemoteAuthorization() === true &&
chargingStation.getConnectorStatus(transactionConnectorId)?.idTagLocalAuthorized === false &&
chargingStation.getConnectorStatus(transactionConnectorId)?.idTagAuthorized === false
) {
connectorId: number,
idTag: string,
): Promise<boolean> {
+ if (!chargingStation.getLocalAuthListEnabled() && !chargingStation.getRemoteAuthorization()) {
+ logger.warn(
+ `${chargingStation.logPrefix()} The charging station expects to authorize RFID tags but nor local authorization nor remote authorization are enabled. Misbehavior may occur`,
+ );
+ }
let authorized = false;
- if (OCPPServiceUtils.isIdTagLocalAuthorized(chargingStation, idTag)) {
+ if (
+ chargingStation.getLocalAuthListEnabled() === true &&
+ OCPPServiceUtils.isIdTagLocalAuthorized(chargingStation, idTag)
+ ) {
const connectorStatus: ConnectorStatus = chargingStation.getConnectorStatus(connectorId)!;
connectorStatus.localAuthorizeIdTag = idTag;
connectorStatus.idTagLocalAuthorized = true;
authorized = true;
- } else if (chargingStation.getMustAuthorizeAtRemoteStart()) {
+ } else if (chargingStation.getRemoteAuthorization()) {
authorized = await OCPPServiceUtils.isIdTagRemoteAuthorized(
chargingStation,
connectorId,
private static isIdTagLocalAuthorized(chargingStation: ChargingStation, idTag: string): boolean {
return (
- chargingStation.getLocalAuthListEnabled() === true &&
chargingStation.hasIdTags() === true &&
isNotEmptyString(
chargingStation.idTagsCache
reconnectExponentialDelay?: boolean;
registrationMaxRetries?: number;
enableStatistics?: boolean;
+ remoteAuthorization?: boolean;
+ /** @deprecated Replaced by remoteAuthorization */
mustAuthorizeAtRemoteStart?: boolean;
/** @deprecated Replaced by ocppStrictCompliance */
payloadSchemaValidation?: boolean;
reconnectExponentialDelay?: boolean;
registrationMaxRetries?: number;
enableStatistics?: boolean;
- mustAuthorizeAtRemoteStart?: boolean;
+ remoteAuthorization?: boolean;
amperageLimitationOcppKey?: string;
amperageLimitationUnit?: AmpereUnits;
beginEndMeterValues?: boolean;