|
@@ -139,23 +139,7 @@ namespace EVCB_OCPP.WSServer
|
|
|
|
|
|
Task serverHealthTask = new Task(HealthCheckTrigger, _ct);
|
|
|
serverHealthTask.Start();
|
|
|
-
|
|
|
- var ocpp20NetworkSetting = new EVCB_OCPP20.Packet.Messages.SetNetworkProfileRequest()
|
|
|
- {
|
|
|
- ConfigurationSlot = 0,
|
|
|
- ConnectionData = new EVCB_OCPP20.Packet.DataTypes.NetworkConnectionProfileType()
|
|
|
- {
|
|
|
- OcppVersion = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPVersionEnumType.OCPP20,
|
|
|
- OcppTransport = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPTransportEnumType.JSON,
|
|
|
- MessageTimeout = 30,
|
|
|
- OcppCsmsUrl = "ws://ocpp.phihong.com.tw:5004",
|
|
|
- OcppInterface = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPInterfaceEnumType.Wired0
|
|
|
- }
|
|
|
-
|
|
|
- };
|
|
|
-
|
|
|
- _ocpp20NetworkSetting = JsonConvert.SerializeObject(ocpp20NetworkSetting, Formatting.None);
|
|
|
-
|
|
|
+
|
|
|
while (true)
|
|
|
{
|
|
|
var input = Console.ReadLine();
|
|
@@ -564,7 +548,7 @@ namespace EVCB_OCPP.WSServer
|
|
|
OcppVersion = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPVersionEnumType.OCPP20,
|
|
|
OcppTransport = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPTransportEnumType.JSON,
|
|
|
MessageTimeout = 30,
|
|
|
- OcppCsmsUrl = "ws://ocpp.phihong.com.tw:5004",
|
|
|
+ OcppCsmsUrl = session.UriScheme == "ws" ? GlobalConfig.OCPP20_WSUrl : GlobalConfig.OCPP20_WSSUrl,
|
|
|
OcppInterface = EVCB_OCPP20.Packet.DataTypes.EnumTypes.OCPPInterfaceEnumType.Wired0
|
|
|
}
|
|
|
|
|
@@ -735,7 +719,7 @@ namespace EVCB_OCPP.WSServer
|
|
|
session.IsCheckIn = true;
|
|
|
if (((BootNotificationConfirmation)replyResult.Message).status == Packet.Messages.SubTypes.RegistrationStatus.Accepted)
|
|
|
{
|
|
|
-
|
|
|
+
|
|
|
|
|
|
|
|
|
CheckVersion(session.ChargeBoxId);
|