schemas: legacy: extract NuvotonFan

This allows to remove some properties from 'Aggregate' schema which are
no longer needed, since there is now a more specific schema to use.

Tested: Schema Validator Pass

Change-Id: I13f8c368b23596b81aa883674764f58aba8c8e10
Signed-off-by: Alexander Hansen <alexander.hansen@9elements.com>
diff --git a/schemas/global.json b/schemas/global.json
index 612b8b5..3ed2ed5 100644
--- a/schemas/global.json
+++ b/schemas/global.json
@@ -61,6 +61,9 @@
                             "$ref": "legacy.json#/$defs/I2CFan"
                         },
                         {
+                            "$ref": "legacy.json#/$defs/NuvotonFan"
+                        },
+                        {
                             "$ref": "virtual_sensor.json#/$defs/VirtualSensor"
                         },
                         {
diff --git a/schemas/legacy.json b/schemas/legacy.json
index 048064d..ef9114b 100644
--- a/schemas/legacy.json
+++ b/schemas/legacy.json
@@ -230,6 +230,41 @@
             "required": ["Name", "Type"],
             "type": "object"
         },
+        "NuvotonFan": {
+            "additionalProperties": false,
+            "properties": {
+                "EntityId": {
+                    "$ref": "#/$defs/Types/EntityId"
+                },
+                "EntityInstance": {
+                    "$ref": "#/$defs/Types/EntityInstance"
+                },
+                "Index": {
+                    "$ref": "#/$defs/Types/Index"
+                },
+                "PowerState": {
+                    "$ref": "#/$defs/Types/PowerState"
+                },
+                "MaxReading": {
+                    "$ref": "#/$defs/Types/MaxReading"
+                },
+                "Connector": {
+                    "$ref": "#/$defs/Types/Connector"
+                },
+                "Thresholds": {
+                    "$ref": "#/$defs/Types/Thresholds"
+                },
+                "Name": {
+                    "$ref": "#/$defs/Types/Name"
+                },
+                "Type": {
+                    "type": "string",
+                    "const": "NuvotonFan"
+                }
+            },
+            "required": ["Name", "Type", "Connector"],
+            "type": "object"
+        },
         "Aggregate": {
             "description": "Don't add additional properties to this schema. Consult README.schema for instructions on adding new Exposes element sub-schema.",
             "additionalProperties": false,
@@ -272,9 +307,6 @@
                 "Address": {
                     "$ref": "#/$defs/Types/Address"
                 },
-                "BindConnector": {
-                    "$ref": "#/$defs/Types/BindConnector"
-                },
                 "BridgeGpio": {
                     "$ref": "#/$defs/Types/BridgeGpio"
                 },
@@ -290,9 +322,6 @@
                 "Class": {
                     "$ref": "#/$defs/Types/Class"
                 },
-                "Connector": {
-                    "$ref": "#/$defs/Types/Connector"
-                },
                 "ConnectsToType": {
                     "$ref": "#/$defs/Types/ConnectsToType"
                 },
@@ -679,7 +708,6 @@
                     "TMP421",
                     "TMP432",
                     "TMP464",
-                    "NuvotonFan",
                     "ADC",
                     "NCT7802",
                     "NCT6779",