{
    "settings": {
        "general": [
            {
                "id": "emergencystop",
                "type": "text",
                "label": "P15",
                "value": "M112",
                "help": "S97"
            }
        ],
        "panels": [
            {
                "id": "fixedpanels",
                "type": "boolean",
                "label": "S203",
                "value": false
            },
            {
                "id": "panelsorder",
                "depend": [
                    {
                        "id": "fixedpanels",
                        "value": true
                    }
                ],
                "fixed": true,
                "sorted": true,
                "type": "list",
                "label": "S202",
                "value": [
                    { "id": "Files", "name": "files" },
                    { "id": "Terminal", "name": "terminal" },
                    { "id": "Jog", "name": "jog", "value": "jog" },
                    { "id": "Extruders", "name": "extruders" },
                    { "id": "Temperatures", "name": "temperatures" },
                    { "id": "Charts", "name": "charts" },
                    { "id": "Status", "name": "status" },
                    { "id": "Controls", "name": "controls" },
                    { "id": "Notifications", "name": "notification" },
                    { "id": "Macros", "name": "macros" },
                    { "id": "Extracontents", "name": "extracontents" }
                ]
            }
        ],
        "polling": [
            {
                "id": "pollingcmds",
                "depend": [
                    {
                        "id": "enablepolling",
                        "value": true
                    }
                ],
                "type": "list",
                "sorted": false,
                "label": "S115",
                "value": [
                    {
                        "id": "samplepolling",
                        "name": "3s",
                        "cmds": "M105",
                        "refreshtime": "3000"
                    }
                ]
            }
        ],
        "files": [
            {
                "id": "sdgroup",
                "type": "group",
                "label": "S190",
                "depend": [
                    {
                        "id": "showfilespanel",
                        "value": true
                    }
                ],
                "value": [
                    {
                        "id": "sd",
                        "type": "boolean",
                        "label": "S63",
                        "value": false,
                        "depend": [{ "id": "showfilespanel", "value": true }]
                    },
                    {
                        "id": "sdlistcmd",
                        "type": "text",
                        "label": "P95",
                        "value": "M21;M20",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sd",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "=='none'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sdplaycmd",
                        "type": "text",
                        "label": "P119",
                        "value": "M21;M23 #;M24",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sd",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "!='direct'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sddeletecmd",
                        "type": "text",
                        "label": "P122",
                        "value": "M21;M30 #",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sd",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "!='direct'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            },
                            { 
                                "connection_id": "SerialProtocol", 
                                "value": "!='MKS'" 
                            }
                        ]
                    },
                    {
                        "id": "sort_sd_files",
                        "type": "boolean",
                        "label": "S224",
                        "value": true,
                        "depend": [{ "id": "sd", "value": true },{
                            "connection_id": "SDConnection",
                            "value": "=='none'"
                        } ]
                    },
                    {
                        "id": "sort_directsd_files",
                        "type": "boolean",
                        "label": "S224",
                        "value": true,
                        "depend": [{ "id": "sd", "value": true },{
                            "connection_id": "SDConnection",
                            "value": "!='none'"
                        } ]
                    }
                ]
            },
            {
                "id": "sdextgroup",
                "type": "group",
                "label": "S191",
                "depend": [
                    {
                        "id": "showfilespanel",
                        "value": true
                    },
                    {
                        "connection_id": "SDConnection",
                        "value": "=='direct'"
                    }
                ],
                "value": [
                    {
                        "id": "sdext",
                        "type": "boolean",
                        "label": "S63",
                        "value": false,
                        "depend": [
                            {
                                "connection_id": "SDConnection",
                                "value": "!='none'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sdextlistcmd",
                        "type": "text",
                        "label": "P95",
                        "value": "M21;M20",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sdext",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "!='none'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sdextplaycmd",
                        "type": "text",
                        "label": "P119",
                        "value": "M21;M23 #;M24",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sdext",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "!='none'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sdextdeletecmd",
                        "type": "text",
                        "label": "P122",
                        "value": "M21;M30 #",
                        "help": "S97",
                        "depend": [
                            {
                                "id": "sdext",
                                "value": true
                            },
                            {
                                "connection_id": "SDConnection",
                                "value": "!='none'"
                            },
                            {
                                "id": "showfilespanel",
                                "value": true
                            }
                        ]
                    },
                    {
                        "id": "sort_sdext_files",
                        "type": "boolean",
                        "label": "S224",
                        "value": true,
                        "depend": [{ "id": "sdext", "value": true }]
                    }
                ]
            },
            {
                "id": "default_filesystem",
                "type": "select",
                "label": "S223",
                "value": "FLASH",
                "depend": [
                    {
                        "id": "showfilespanel",
                        "value": true
                    },
                    {
                        "orGroups": [
                            [{
                                "id": "sd",
                                "value": true
                            }],
                            [{
                                "id": "flashfs",
                                "value": true
                            }],
                            [{ "id": "sdext", "value": true }],
                            [{"id": "tftfs", "notvalue": "none"},{ "id": "tftsd", "value": true }],
                            [{"id": "tftfs", "notvalue": "none"},{ "id": "tftusb", "value": true }]
                        ]
                    }
                ],
                "options": [
                    { "value": "FLASH", "label": "S137", "depend": [{ "id": "flashfs", "value": true }] },
                    {
                        "value": "SD",
                        "label": "S190",
                        "depend": [
                            { "id": "sd", "value": true },
                            { "connection_id": "SDConnection", "value": "=='none'" }
                        ]
                    },
                    { "value": "SDEXT", "label": "S191", "depend": [{ "id": "sdext", "value": true }] },
                    { "value": "TFTSD", "label": "S188", "depend": [{ "id": "tftsd", "value": true },{"id": "tftfs", "notvalue": "none"}] },
                    { "value": "TFTUSB", "label": "S189", "depend": [{ "id": "tftusb", "value": true },{"id": "tftfs", "notvalue": "none"}] },  
                    {
                        "value": "DIRECTSD",
                        "label": "S190",
                        "depend": [
                            { "id": "sd", "value": true },
                            { "connection_id": "SDConnection", "value": "!='none'" }
                        ]
                    }
                ]
            }
        ],
        "extruders": [
            {
                "id": "ismixedextruder",
                "type": "boolean",
                "label": "P49",
                "value": false,
                "depend": [{ "id": "showextruderspanel", "value": true }]
            },
            {
                "id": "enumber",
                "type": "select",
                "label": "P52",
                "value": "1",
                "options": [
                    { "label": "1", "value": "1" },
                    { "label": "2", "value": "2" },
                    { "label": "3", "value": "3" },
                    { "label": "4", "value": "4" },
                    { "label": "5", "value": "5" },
                    { "label": "6", "value": "6" }
                ],
                "depend": [
                    {
                        "id": "ismixedextruder",
                        "value": true
                    },
                    { "id": "showextruderspanel", "value": true }
                ]
            },
            {
                "id": "ecolors",
                "type": "text",
                "label": "P51",
                "help": "S97",
                "value": "blue;red;green;#FF00FF;cyan;black",
                "depend": [
                    {
                        "id": "ismixedextruder",
                        "value": true
                    },
                    { "id": "showextruderspanel", "value": true }
                ]
            }
        ],
        "status": [
            {
                "id": "sdcommands",
                "type": "group",
                "label": "P101",
                "depend": [
                    {
                        "orGroups": [
                                        [
                                            {
                                            "id": "sdext",
                                            "value": true
                                            },
                                            {
                                                "connection_id": "SDConnection",
                                                "value": "=='direct'"
                                            }
                                        ],
                                        [
                                            {
                                            "id": "sd",
                                            "value": true
                                            },
                                            {
                                                "connection_id": "SDConnection",
                                                "value": "!='direct'"
                                            }
                                        ]
                                    ]
                                    
                    },
                    { "id": "showstatuspanel", "value": true }
                ],
                "value": [
                    {
                        "id": "sdpausecmd",
                        "type": "text",
                        "label": "P98",
                        "value": "M25",
                        "help": "S97"
                    },
                    {
                        "id": "sdresumecmd",
                        "type": "text",
                        "label": "P99",
                        "value": "M24",
                        "help": "S97"
                    },
                    {
                        "id": "sdstopcmd",
                        "type": "text",
                        "label": "P100",
                        "value": "M524",
                        "help": "S97"
                    }
                ]
            },
            {
                "id": "tftsdcommands",
                "type": "group",
                "label": "P102",
                "depend": [
                    {
                        "id": "tftfs",
                        "notvalue": "none"
                    },
                    {
                        "id": "tftsd",
                        "value": true
                    },
                    { "id": "showstatuspanel", "value": true }
                ],
                "value": [
                    {
                        "id": "tftsdpausecmd",
                        "type": "text",
                        "label": "P98",
                        "value": "M25",
                        "help": "S97"
                    },
                    {
                        "id": "tftsdresumecmd",
                        "type": "text",
                        "label": "P99",
                        "value": "M24",
                        "help": "S97"
                    },
                    {
                        "id": "tftsdstopcmd",
                        "type": "text",
                        "label": "P100",
                        "value": "M524",
                        "help": "S97"
                    }
                ]
            },
            {
                "id": "tftusbcommands",
                "type": "group",
                "label": "P103",
                "depend": [
                    { "id": "tftfs", "notvalue": "none" },
                    { "id": "tftusb", "value": true },
                    { "id": "showstatuspanel", "value": true }
                ],
                "value": [
                    {
                        "id": "tftusbpausecmd",
                        "type": "text",
                        "label": "P98",
                        "value": "M25",
                        "help": "S97"
                    },
                    {
                        "id": "tftusbresumecmd",
                        "type": "text",
                        "label": "P99",
                        "value": "M24",
                        "help": "S97"
                    },
                    {
                        "id": "tftusbstopcmd",
                        "type": "text",
                        "label": "P100",
                        "value": "M524",
                        "help": "S97"
                    }
                ]
            }
        ]
    }
}
