From f113b0df639b6712bd7f8b508665d69a8a5a76ab Mon Sep 17 00:00:00 2001 From: Neil Dorin Date: Wed, 22 Jan 2020 12:16:04 -0700 Subject: [PATCH] Adds PD.Core schema files from submodule build --- .../Schema/ControlPropertiesConfigSchema.json | 181 ++++++++++++++++++ .../Schema/TcpSshPropertiesConfigSchema.json | 81 ++++++++ .../PepperDash_Essentials_Core.csproj | 6 + .../{ => Chassis}/Config/DMChassisConfig.cs | 0 .../{ => Chassis}/Config/DmpsRoutingConfig.cs | 0 ...assisControllerPropertiesConfigSchema.json | 0 .../Essentials_DM/Essentials_DM.csproj | 6 +- .../SamsungMDCPropertiesConfigSchema.json | 4 +- essentials-framework/pepperdashcore-builds | 2 +- 9 files changed, 275 insertions(+), 5 deletions(-) create mode 100644 essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/ControlPropertiesConfigSchema.json create mode 100644 essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/TcpSshPropertiesConfigSchema.json rename essentials-framework/Essentials DM/Essentials_DM/{ => Chassis}/Config/DMChassisConfig.cs (100%) rename essentials-framework/Essentials DM/Essentials_DM/{ => Chassis}/Config/DmpsRoutingConfig.cs (100%) rename essentials-framework/Essentials DM/Essentials_DM/{ => Chassis}/Config/Schema/DmChassisControllerPropertiesConfigSchema.json (100%) diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/ControlPropertiesConfigSchema.json b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/ControlPropertiesConfigSchema.json new file mode 100644 index 00000000..fcb6c87a --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/ControlPropertiesConfigSchema.json @@ -0,0 +1,181 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "type": "object", + "title": "Control Properties", + "$ref": "#/definitions/ControlPropertiesConfig", + "definitions": { + "ControlPropertiesConfig": { + "description": "The method of communicating with the device", + "properties": { + "method": { + "type": "string", + "title": "Communication Method", + "enum": [ + "none", + "com", + "ipid", + "ipidtcp", + "ir", + "ssh", + "tcpip", + "telnet", + "cresnet", + "cec", + "udp" + ] + }, + "tcpSshProperties": { + "$ref":"TcpSshPropertiesConfigSchema.json#definitions/TcpSshPropertiesConfig", + "title": "Properties for IP based communication", + "default": null + }, + "comParams": { + "title":"Com Port parameters", + "description": "The parameters to configure the COM port", + "type":"object", + "protocol":{ + "title":"Protocol", + "type":"string", + "enum":[ + "RS232", + "RS422", + "RS485" + ] + }, + "baudRate":{ + "title":"Baud Rate", + "type":"integer", + "enum":[ + 300, + 600, + 1200, + 1800, + 2400, + 3600, + 4800, + 7200, + 9600, + 14400, + 19200, + 28800, + 38400, + 57600, + 115200 + ] + }, + "dataBits":{ + "title":"Data Bits", + "type":"integer", + "enum":[ + 7, + 8 + ] + }, + "stopBits":{ + "title":"Stop Bits", + "type":"integer", + "enum":[ + 1, + 2 + ] + }, + "parity":{ + "title":"Parity", + "type":"string", + "enum":[ + "None", + "Even", + "One" + ] + }, + "softwareHandshake":{ + "title":"Software Handshake", + "type":"string", + "enum":[ + "None", + "RTS", + "CTS", + "RTSCTS" + ] + }, + "hardwareHandshake":{ + "title":"Hardware Handshake", + "type":"string", + "enum":[ + "None", + "XON", + "XONT", + "XONR" + ] + }, + "pacing":{ + "title":"Pacing", + "type":"integer" + } + }, + "cresnetId":{ + "type": "string", + "title":"Cresnet ID", + "description": "Cresnet ID of the device", + "default": "", + "examples": [ + "13", + "03", + "0A", + "F1" + ], + "pattern": "^(?!00|01|02|FF)[0-9,A-F,a-f][0-9,A-F,a-f]$" + }, + "controlPortDevKey": { + "type": "string", + "title":"Port Device", + "description": "Key of the device where the control port is found", + "examples": [ + "processor" + ] + }, + "controlPortNumber": { + "type": "integer", + "title": "Port Number", + "description": "Control Port Number on the device referenced by controlPortDevKey", + "examples": [ + 1 + ] + }, + "controlPortName": { + "type": "string", + "title": "Port Name", + "description": "Control Port Name on the device referenced by controlPortDevKey", + "examples": [ + "hdmi1" + ] + }, + "irFile": { + "type": "string", + "title": "IR File", + "description": "IR Filename", + "default": "", + "examples": [ + "Comcast Motorola DVR.ir" + ], + "pattern": "^(.*).ir$" + }, + "ipid": { + "type": "string", + "title": "IPID", + "default": "", + "examples": [ + "13", + "03", + "0A", + "F1" + ], + "pattern": "^(?!00|01|02|FF)[0-9,A-F,a-f][0-9,A-F,a-f]$" + } + }, + "required": [ + "method" + ] + } + } +} \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/TcpSshPropertiesConfigSchema.json b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/TcpSshPropertiesConfigSchema.json new file mode 100644 index 00000000..118e4ba2 --- /dev/null +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/Config/Schema/TcpSshPropertiesConfigSchema.json @@ -0,0 +1,81 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "type": "object", + "title": "TcpSshPropertiesConfig", + "$ref": "#/definitions/TcpSshPropertiesConfig", + "definitions": { + "TcpSshPropertiesConfig": { + "properties": { + "username": { + "type": "string", + "title": "Username", + "default":"", + "examples": [ + "admin" + ], + "pattern": "^(.*)$" + }, + "port": { + "type": "integer", + "title": "Port Number", + "minimum": 1, + "maximum": 65535, + "examples": [ + 22, + 23, + 1515 + ] + }, + "address": { + "type": "string", + "title": "IP Address or Hostname", + "examples": [ + "192.168.99.100", + "myDeviceHostname" + ], + "pattern": "^(.*)$" + }, + "password": { + "type": "string", + "title": "Password", + "default":"", + "examples": [ + "password" + ], + "pattern": "^(.*)$" + }, + "autoReconnect": { + "type": "boolean", + "title": "Auto Reconnect", + "description": "Indicates if automatic attemtps to reconnect should be made if communication is lost with the device", + "default": true, + "examples": [ + true + ] + }, + "autoReconnectIntervalMs": { + "type": "integer", + "title": "Auto Reconnect Interval (Milliseconds)", + "description": "If Auto Reconnect is enabled, how often should reconnect attempts be made", + "default": 5000, + "examples": [ + 2000 + ] + }, + "bufferSize": { + "type": "integer", + "title": "Buffer Size", + "description": "The size of the receive buffer to use", + "default": 32768, + "examples": [ + 32768 + ] + } + }, + "required": [ + "port", + "address" + ] + } + } +} \ No newline at end of file diff --git a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj index dadc2255..261f0402 100644 --- a/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj +++ b/essentials-framework/Essentials Core/PepperDashEssentialsBase/PepperDash_Essentials_Core.csproj @@ -270,6 +270,12 @@ Always + + Always + + + Always + diff --git a/essentials-framework/Essentials DM/Essentials_DM/Config/DMChassisConfig.cs b/essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/DMChassisConfig.cs similarity index 100% rename from essentials-framework/Essentials DM/Essentials_DM/Config/DMChassisConfig.cs rename to essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/DMChassisConfig.cs diff --git a/essentials-framework/Essentials DM/Essentials_DM/Config/DmpsRoutingConfig.cs b/essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/DmpsRoutingConfig.cs similarity index 100% rename from essentials-framework/Essentials DM/Essentials_DM/Config/DmpsRoutingConfig.cs rename to essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/DmpsRoutingConfig.cs diff --git a/essentials-framework/Essentials DM/Essentials_DM/Config/Schema/DmChassisControllerPropertiesConfigSchema.json b/essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/Schema/DmChassisControllerPropertiesConfigSchema.json similarity index 100% rename from essentials-framework/Essentials DM/Essentials_DM/Config/Schema/DmChassisControllerPropertiesConfigSchema.json rename to essentials-framework/Essentials DM/Essentials_DM/Chassis/Config/Schema/DmChassisControllerPropertiesConfigSchema.json diff --git a/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj b/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj index 654159e6..f5411476 100644 --- a/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj +++ b/essentials-framework/Essentials DM/Essentials_DM/Essentials_DM.csproj @@ -103,10 +103,10 @@ - + - + @@ -148,7 +148,7 @@ - + Always diff --git a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Display/Schema/SamsungMDCPropertiesConfigSchema.json b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Display/Schema/SamsungMDCPropertiesConfigSchema.json index 7b32dd19..b3a5da2c 100644 --- a/essentials-framework/Essentials Devices Common/Essentials Devices Common/Display/Schema/SamsungMDCPropertiesConfigSchema.json +++ b/essentials-framework/Essentials Devices Common/Essentials Devices Common/Display/Schema/SamsungMDCPropertiesConfigSchema.json @@ -18,8 +18,10 @@ "$ref":"ControlPropertiesConfigSchema.json#definitions/ControlPropertiesConfig" }, "id":{ + "title":"Display ID", + "description": "This must match the ID set in the display's on screen menu", "type":"string", - "pattern": "^([0-9]|0[1-9]|[1-9][0-9])$" + "pattern": "^(?!FF)[0-9,A-F,a-f][0-9,A-F,a-f]$" } } } diff --git a/essentials-framework/pepperdashcore-builds b/essentials-framework/pepperdashcore-builds index b7daa148..860dc8a1 160000 --- a/essentials-framework/pepperdashcore-builds +++ b/essentials-framework/pepperdashcore-builds @@ -1 +1 @@ -Subproject commit b7daa148176ce7e1838303dffee6f9a6c36b7a7b +Subproject commit 860dc8a1a4c34f935f43530012a8153957fb9a57