| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653 |
- <!DOCTYPE html>
- <html>
- <!-- HEAD -->
- <head>
- <meta charset="UTF-8">
- <title>MOD Settings</title>
- <link rel="apple-touch-icon" sizes="57x57" href="img/favicon/apple-icon-57x57.png">
- <link rel="apple-touch-icon" sizes="60x60" href="img/favicon/apple-icon-60x60.png">
- <link rel="apple-touch-icon" sizes="72x72" href="img/favicon/apple-icon-72x72.png">
- <link rel="apple-touch-icon" sizes="76x76" href="img/favicon/apple-icon-76x76.png">
- <link rel="apple-touch-icon" sizes="114x114" href="img/favicon/apple-icon-114x114.png">
- <link rel="apple-touch-icon" sizes="120x120" href="img/favicon/apple-icon-120x120.png">
- <link rel="apple-touch-icon" sizes="144x144" href="img/favicon/apple-icon-144x144.png">
- <link rel="apple-touch-icon" sizes="152x152" href="img/favicon/apple-icon-152x152.png">
- <link rel="apple-touch-icon" sizes="180x180" href="img/favicon/apple-icon-180x180.png">
- <link rel="icon" type="image/png" sizes="192x192" href="img/favicon/android-icon-192x192.png">
- <link rel="icon" type="image/png" sizes="32x32" href="img/favicon/favicon-32x32.png">
- <link rel="icon" type="image/png" sizes="96x96" href="img/favicon/favicon-96x96.png">
- <link rel="icon" type="image/png" sizes="16x16" href="img/favicon/favicon-16x16.png">
- <link rel="manifest" href="img/favicon/manifest.json">
- <meta name="msapplication-TileColor" content="#111111">
- <meta name="msapplication-TileImage" content="img/favicon/ms-icon-144x144.png">
- <meta name="theme-color" content="#111111">
- <link rel="stylesheet" type="text/css" href="css/fontello/css/fontello.css?v={{version}}"/>
- <link rel="stylesheet" type="text/css" href="css/main.css?v={{version}}"/>
- <link rel="stylesheet" type="text/css" href="css/dashboard.css?v={{version}}"/>
- <link rel="stylesheet" type="text/css" href="css/fonts.css?v={{version}}"/>
- <style type="text/css" media="screen">
- .settings-page-content {
- background: #111;
- left: 245px;
- height: calc(100% - 50px);
- margin: 0;
- padding: 0;
- position: fixed;
- text-align: left;
- top: 45px;
- width: calc(100% - 290px);
- overflow-y: auto;
- }
- .settings-page {
- max-width: 900px;
- padding-bottom: 2em;
- }
- .settings-page-content h1 {
- font-size: 2.2em;
- padding: 0em;
- max-height: 2em;
- display: block;
- margin: 0.5em 0.8em 0 0.8em;
- padding-bottom: 0.2em;
- color: white;
- white-space: nowrap;
- overflow: hidden;
- }
- .settings-page-content h2 {
- color: #BBB;
- font-size: 1.5em;
- margin: 1em 0 0.4em 0;
- }
- .settings-page-content form {
- margin: 0 2em;
- color: #666;
- }
- .settings-page-content form label,
- .settings-page-content form p {
- color: #999;
- font-size: 1.1em;
- }
- .settings-page-content form label input {
- color: #555;
- }
- #settings-reboot-needed {
- background: #f29446;
- color: white;
- font-size: 1.1em;
- padding: 0.8em 2em;
- position: sticky;
- top: 0;
- z-index: 1;
- }
- #settings-reboot-needed input {
- color: #555;
- float: left;
- margin: 0.4em 2em 0 0;
- }
- #bank-library {
- bottom: 0px;
- }
- #bank-library #bank-list {
- bottom: 5px;
- left: 5px;
- width: 200px;
- }
- #bank-library #bank-list div.add-bank {
- padding-left: 5px;
- padding-right: 5px;
- text-align: center;
- }
- </style>
- <script type="text/javascript" src="js/lib/jquery-1.9.1.min.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/jquery-ui-1.10.1.custom.min.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/jquery.ui.touch-punch.min.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/jquery.ba-resize.min.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/mustache.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/jquery.svg.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/sprintf-0.6.js?v={{version}}"></script>
- <script type="text/javascript" src="js/lib/jquery.mousewheel.min.js?v={{version}}"></script>
- <script type="text/javascript">
- {% autoescape None %}
- SITEURL = '{{cloud_url}}'
- CONTROLCHAIN_URL = '{{controlchain_url}}'
- VERSION = '{{version}}'
- var TEMPLATES = {}
- var NOTIFICATIONS_ENABLED = true
- var HMI_EEPROM = {{hmi_eeprom}}
- var PREFERENCES = {{preferences}}
- var PLATFORM = '{{platform}}'
- var INFO = {
- "hwname": "",
- "sysdate": "",
- "python": {},
- "uname": {}
- }
- // Settings that are only read when the unit boots, by their name in /system/prefs
- var REBOOT_PREFS = {
- "jack_mono_copy" : "#prefs-audio-mono-copy",
- "separate_spdif_outs": "#prefs-audio-separate-spdif-outs",
- "autorestart_hmi" : "#prefs-workarounds-autorestart-hmi",
- }
- var REBOOT_STORAGE_KEY = "mod-settings-reboot-needed"
- var SYSPREFS = null
- var bootPrefs = null
- var savedNotification = null
- function bool2str(ok) {
- return ok ? "true" : "false"
- }
- function report_saved(ok) {
- if (savedNotification) {
- clearTimeout(savedNotification.closeTimeout)
- savedNotification.close()
- }
- if (ok) {
- savedNotification = new Notification("info", "Saved", 2000)
- } else {
- savedNotification = new Notification("error", "Could not save this setting")
- // show what is really set on the unit
- refresh_sysprefs()
- }
- }
- // The values the unit booted with are the ones found when this page loads, unless a change was made
- // earlier and the unit has not been rebooted since. The browser remembers that case.
- function load_boot_prefs() {
- if (bootPrefs != null || SYSPREFS == null || INFO.uptime === undefined) {
- return
- }
- var stored = null
- try {
- stored = JSON.parse(localStorage.getItem(REBOOT_STORAGE_KEY))
- } catch (e) {}
- if (stored && stored.prefs && INFO.uptime != null && stored.time > Date.now() - INFO.uptime * 1000) {
- bootPrefs = stored.prefs
- } else {
- bootPrefs = {}
- for (var label in REBOOT_PREFS) {
- bootPrefs[label] = SYSPREFS[label]
- }
- }
- }
- function refresh_reboot_needed() {
- load_boot_prefs()
- if (bootPrefs == null) {
- return
- }
- var needed = false
- for (var label in REBOOT_PREFS) {
- if (label in bootPrefs && $(REBOOT_PREFS[label]).prop("checked") != bootPrefs[label]) {
- needed = true
- }
- }
- try {
- if (needed) {
- localStorage.setItem(REBOOT_STORAGE_KEY, JSON.stringify({ time: Date.now(), prefs: bootPrefs }))
- } else {
- localStorage.removeItem(REBOOT_STORAGE_KEY)
- }
- } catch (e) {}
- if (needed) {
- $("#settings-reboot-needed").show()
- } else {
- $("#settings-reboot-needed").hide()
- }
- }
- function refresh_sysinfo() {
- $.ajax({
- url: '/system/info',
- method: 'GET',
- success: function (info) {
- INFO = info
- $("#info-system-unit").text(INFO.hwname)
- $("#info-system-date").text(INFO.sysdate)
- $("#info-kernel-machine").text(INFO.uname.machine)
- $("#info-kernel-release").text(INFO.uname.release)
- $("#info-kernel-version").text(INFO.uname.version)
- if (info.platform != "duox" || info.model == "duox:aarch64-a53") {
- $("#prefs-audio-separate-spdif-outs_div").hide()
- }
- if (INFO.uptime === undefined) {
- INFO.uptime = null
- }
- refresh_reboot_needed()
- },
- error: function () {
- INFO.uptime = null
- refresh_reboot_needed()
- },
- cache: false,
- global: false,
- dataType: 'json'
- })
- }
- // the buffer size radio always shows the size JACK is running at (the server keeps the saved one equal to it)
- function set_buffer_size_radio(size) {
- $("input[name=prefs-audio-buffer-size][value='" + size + "']").prop("checked", true)
- }
- function refresh_sysprefs() {
- $.ajax({
- url: '/system/prefs',
- method: 'GET',
- success: function (resp) {
- if (resp.bluetooth_name != null)
- {
- $("#prefs-bluetooth-custom").prop("checked", true)
- $("#prefs-bluetooth-name").prop("disabled", false).val(resp.bluetooth_name)
- }
- else
- {
- $("#prefs-bluetooth-custom").prop("checked", false)
- $("#prefs-bluetooth-name").prop("disabled", true)
- }
- $("#prefs-audio-mono-copy").prop("checked", resp.jack_mono_copy)
- $("#prefs-audio-separate-spdif-outs").prop("checked", resp.separate_spdif_outs)
- $("#prefs-service-netmanager").prop("checked", resp.service_netmanager)
- $("#prefs-workarounds-autorestart-hmi").prop("checked", resp.autorestart_hmi)
- SYSPREFS = resp
- refresh_reboot_needed()
- },
- cache: false,
- global: false,
- dataType: 'json'
- })
- }
- function report_device_updates_failed() {
- $("#settings-cc-firmware-status").html(
- "<b>The Control Chain firmware server did not answer.</b><br/>"
- + "The list of devices comes from the internet, through the computer or phone showing this page. "
- + "Check its connection and reload this page to try again.")
- }
- function refresh_device_updates(respDev, respVer) {
- if (!respDev || !respVer) {
- return
- }
- if (respDev.api_version != 1 || respVer.api_version != 1) {
- $("#settings-cc-firmware-status").html(
- "<b>The Control Chain firmware server gave an answer this MOD version does not understand.</b><br/>"
- + "Update the MOD and try again.")
- return
- }
- var elem = $('#settings-cc-firmware')
- $("#settings-cc-firmware-status").hide()
- for (var i in respDev.devices) {
- var dev = respDev.devices[i],
- text = "",
- note = ""
- if (dev.label) {
- var dev2 = respVer.devices[dev.uri]
- if (dev2) {
- dev.version = dev2.latest
- } else {
- dev.label = ""
- }
- }
- if (! dev.label) {
- note = "<br/>Note: Updates for this device need to be done manually."
- }
- text += "<h2>" + dev.name + "</h2>"
- text += "<p>" + dev.description.replace(/\n/g,"<br/>") + note + "</p>"
- if (dev.label) {
- var labelcl = 'button-action-update-firmware'
- var labelid = 'button-action-update-firmware-'+i
- text += "<label>"
- text += "<input type='button' class='" + labelcl + "' id='" + labelid + "' value='Update firmware'></input>"
- text += " Latest version: v" + dev.version
- text += "</label>"
- }
- elem.append(text)
- }
- $(".button-action-update-firmware").click(function () {
- var self = $(this)
- if (self.hasClass("disabled")) {
- return
- }
- var dev_id = parseInt(this.id.replace("button-action-update-firmware-","")),
- dev = respDev.devices[dev_id]
- if (!dev || !dev.label) {
- new Bug("Couldn't download firmware, wrong Id")
- return
- }
- self.addClass("disabled")
- var url = CONTROLCHAIN_URL + "/file/" + dev.label + dev.version + ".bin"
- var transfer = new SimpleTransference(url, '/controlchain/download/')
- transfer.reportFinished = function () {
- self.removeClass("disabled")
- $('#cc-device-update-window').show()
- }
- transfer.reportError = function (error) {
- self.removeClass("disabled")
- new Bug("Couldn't download firmware, reason:<br/>" + error)
- }
- transfer.start()
- })
- }
- function show_blocker (action) {
- var block = $('<div class="screen-disconnected blocker">');
- var text;
- if (action == "delete") {
- text = 'Deleting data, please wait...';
- } else if (action == "reflash") {
- text = 'Flashing controller, please wait...';
- } else if (action == "export") {
- text = 'Exporting data, please wait...';
- } else if (action == "import") {
- text = 'Restoring data, please wait...<br/>This might take a few minutes.';
- } else if (action == "info") {
- text = 'Reading the USB stick, please wait...';
- } else {
- text = 'Please wait..'
- }
- block.html('<p>' + text + '</p>')
- block.css('overflow', 'hidden')
- $('body').append(block)
- return block
- }
- function config_set(key, value) {
- $.ajax({
- url: '/config/set',
- method: 'POST',
- data: {
- key: key,
- value: value,
- },
- success: function (resp) {
- console.log("success", resp)
- report_saved(resp === true)
- },
- error: function (resp) {
- console.log("error", resp)
- report_saved(false)
- },
- cache: false,
- dataType: 'json'
- })
- }
- function system_cleanup(favorites, hmiSettings, licenseKeys, banks, pedalboards, plugins, callback) {
- $.ajax({
- url: '/system/cleanup',
- method: 'POST',
- data: {
- favorites: favorites ? 1 : 0,
- hmiSettings: hmiSettings ? 1 : 0,
- licenseKeys: licenseKeys ? 1 : 0,
- banks: banks ? 1 : 0,
- pedalboards: pedalboards ? 1 : 0,
- plugins: plugins ? 1 : 0,
- },
- success: function (resp) {
- if (callback) {
- callback(resp)
- }
- },
- error: function (resp) {
- console.log("error", resp)
- alert("An error occurred: " + resp)
- },
- cache: false,
- dataType: 'json'
- })
- }
- function system_exechange(data, callback, errback) {
- $.ajax({
- url: '/system/exechange',
- method: 'POST',
- data: data,
- success: function (resp) {
- console.log("success", resp)
- if (callback) {
- callback(resp)
- }
- },
- error: function (resp) {
- console.log("error", resp)
- if (errback) {
- errback(resp)
- }
- },
- cache: false,
- dataType: 'json'
- })
- }
- // system_exechange for a setting: tells the user if it was saved
- function system_exechange_setting(data) {
- system_exechange(data, function (resp) {
- report_saved(resp === true)
- refresh_reboot_needed()
- }, function () {
- report_saved(false)
- })
- }
- function enable_service(name, enable, inverted, persistent) {
- var data = {
- 'type' : 'service',
- 'name' : name,
- 'enable' : enable ? 1 : 0,
- 'inverted' : inverted ? 1 : 0,
- 'persistent': persistent ? 1 : 0,
- }
- if (persistent) {
- system_exechange_setting(data)
- } else {
- system_exechange(data)
- }
- }
- function run_custom_command(cmd, callback, errback) {
- system_exechange({
- 'type': 'command',
- 'cmd' : cmd,
- }, callback, errback)
- }
- function write_file_contents(path, content) {
- system_exechange_setting({
- 'type' : 'filewrite',
- 'path' : path,
- 'content': content,
- })
- }
- function create_or_delete_file(path, create) {
- system_exechange_setting({
- 'type' : 'filecreate',
- 'path' : path,
- 'create': create ? 1 : 0,
- })
- }
- $('document').ready(function() {
- var self = this
- var cached_cpuLoad
- var ws = new WebSocket("ws://" + window.location.host + "/websocket")
- ws.onclose = function (evt) {
- if ($('body').find('.screen-disconnected').length != 0) {
- return
- }
- var block = $('<div class="screen-disconnected blocker">')
- block.html('<p>Disconnected</p>')
- var re = $("<div class='button icon'>Reload</div>").appendTo(block);
- re.css("background-image", "url(img/icons/25/reload.png)");
- re.click(function () { location.reload(); });
- $('body').append(block).css('overflow', 'hidden')
- $('#wrapper').css('z-index', -1)
- $('#bank-library').css('z-index', -1)
- }
- ws.onmessage = function (evt) {
- var data = evt.data
- var cmd = data.split(" ",1)
- if (!cmd.length) {
- return
- }
- var cmd = cmd[0]
- if (cmd == "stats") {
- var cpuLoad = parseFloat(data.substr(cmd.length+1).split(" ",2)[0])
- if (cpuLoad != cached_cpuLoad) {
- cached_cpuLoad = cpuLoad
- $("#info-dsp-load").text(""+cpuLoad.toString()+"%")
- }
- return
- }
- if (cmd == "ping") {
- ws.send("pong")
- return
- }
- if (cmd == "stop") {
- ws.close()
- return
- }
- if (cmd == "bufsize") {
- var bufsize = data.substr(cmd.length+1)
- $("#info-dsp-buffer-size").html(bufsize)
- set_buffer_size_radio(bufsize)
- return
- }
- if (cmd == "cc-device-updated") {
- $('#cc-device-update-window').hide()
- new Notification("info", "Control Chain device firmware update complete!")
- return
- }
- }
- // ----------------------------------------------------------------------------------------------------------------
- // tab "tab-xyz" shows page "settings-page-xyz"
- $(".add-bank").click(function () {
- // hide all
- $(".add-bank").removeClass("selected")
- $(".settings-page").hide()
- // show the one that was clicked
- $(this).addClass("selected")
- $("#settings-page-" + this.id.replace("tab-", "")).show()
- $(".settings-page-content").scrollTop(0)
- })
- // ----------------------------------------------------------------------------------------------------------------
- $('#cc-device-update-window').find('.js-cancel').click(function () {
- $.ajax({
- url: '/controlchain/cancel/',
- type: 'POST',
- success: function () {
- $('#cc-device-update-window').hide()
- },
- error: function () {
- $('#cc-device-update-window').hide()
- },
- cache: false,
- dataType: 'json'
- })
- return false
- })
- // ----------------------------------------------------------------------------------------------------------------
- refresh_sysinfo()
- refresh_sysprefs()
- // User Interface tools: each one on its own. One never set on its own follows its data-fallback key if
- // that was set (Install All / Update All were one switch), then the old Developer Mode switch.
- $(".prefs-ui-tool").each(function () {
- var value = PREFERENCES[$(this).data("key")]
- if (value !== "on" && value !== "off" && $(this).data("fallback")) {
- value = PREFERENCES[$(this).data("fallback")]
- }
- if (value !== "on" && value !== "off") {
- value = PREFERENCES['dev-mode']
- }
- $(this).prop("checked", value == "on")
- })
- // CPU speed and temperature are not available on the Duo
- if (PLATFORM == "duo") {
- $(".prefs-ui-cpu-stats-option").hide()
- }
- if (PREFERENCES['show-unstable-plugins'] == "true") {
- $("#prefs-ui-unstable-plugins").prop("checked", true)
- }
- if (PREFERENCES['update-channel'] == "testing") {
- $("#prefs-update-channel-testing").prop("checked", true)
- $("#prefs-update-channel-note").show()
- } else {
- $("#prefs-update-channel-stable").prop("checked", true)
- }
- if (PREFERENCES['merge-stereo-cables'] == "true") {
- $("#prefs-ui-stereo-cables").prop("checked", true)
- }
- var teleportScale = parseFloat(PREFERENCES['teleport-label-scale'])
- if (! (teleportScale > 0)) {
- teleportScale = 1
- }
- $("#prefs-ui-teleport-scale").val(teleportScale)
- $("#prefs-ui-teleport-scale-value").text(teleportScale.toFixed(1) + "x")
- if (! HMI_EEPROM) {
- $("#prefs-delete-hmi-settings_br").hide()
- $("#prefs-delete-hmi-settings_label").hide()
- }
- // ----------------------------------------------------------------------------------------------------------------
- // --- Personal :: Bluetooth custom name
- this.last_bluetooth_timeout = null
- this.set_bluetooth_name = function() {
- if (self.last_bluetooth_timeout != null) {
- clearTimeout(self.last_bluetooth_timeout)
- self.last_bluetooth_timeout = null
- }
- var name
- if ($("#prefs-bluetooth-custom").prop("checked")) {
- name = $("#prefs-bluetooth-name").val()
- } else {
- name = ""
- }
- write_file_contents("bluetooth/name", name)
- }
- $("#prefs-bluetooth-custom").click(function () {
- var elem_btname = $("#prefs-bluetooth-name")
- if ($(this).prop("checked")) {
- // give it a default name if one was not set before
- if (! elem_btname.val()) {
- elem_btname.val(INFO.hwname)
- }
- // enable text input
- elem_btname.prop("disabled", false)
- } else {
- // disable text input
- elem_btname.prop("disabled", true)
- }
- // set name
- self.set_bluetooth_name()
- })
- $("#prefs-bluetooth-name")
- .keydown(function (e) {
- if (e.keyCode == 13) {
- // detect enter
- self.set_bluetooth_name()
- return false
- } else if (e.keyCode == 8 || e.keyCode == 46) {
- if (self.last_bluetooth_timeout != null) {
- clearTimeout(self.last_bluetooth_timeout)
- }
- // detect delete and backspace
- self.last_bluetooth_timeout = setTimeout(function () {
- self.set_bluetooth_name()
- }, 400)
- }
- })
- .keypress(function (e) { // keypress won't detect delete and backspace but will only allow inputable keys
- if (e.which == 13) {
- return
- }
- if (self.last_bluetooth_timeout != null) {
- clearTimeout(self.last_bluetooth_timeout)
- }
- self.last_bluetooth_timeout = setTimeout(function () {
- self.set_bluetooth_name()
- }, 400)
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Backup & Restore
- // "<device configs>,<plugins>,<user files>,<browser time>"
- // The browser's time dates the backup (and the safety copy of a restore): the Dwarf has no
- // battery-backed clock and would write 1970.
- function backup_options() {
- return ($("#prefs-backup-configs").prop("checked") ? '1' : '0') + ","
- + ($("#prefs-backup-plugins").prop("checked") ? '1' : '0') + ","
- + ($("#prefs-backup-userfiles").prop("checked") ? '1' : '0') + ","
- + Math.floor(Date.now() / 1000)
- }
- $("#button-action-backup-export").click(function () {
- var block = show_blocker("export")
- run_custom_command("backup-export " + backup_options(), function (resp) {
- block.remove()
- if (resp.ok) {
- new Notification("info", "Backup to USB stick complete!<br>You can now safely remove the USB stick.")
- } else {
- new Notification("error", "Backup to USB stick failed!<br>" + resp.error)
- }
- }, function () {
- block.remove()
- new Notification("error", "Backup to USB stick failed!<br>Communication failure.")
- })
- })
- $("#button-action-backup-import").click(function () {
- var block = show_blocker("info")
- run_custom_command("backup-info", function (resp) {
- block.remove()
- if (! resp.ok) {
- new Notification("error", "Cannot read a backup from the USB stick.<br>" + resp.error)
- return
- }
- if (! confirm(backup_restore_question(resp.info))) {
- return
- }
- start_backup_restore()
- }, function () {
- block.remove()
- new Notification("error", "Cannot read a backup from the USB stick.<br>Communication failure.")
- })
- })
- function backup_restore_question(info) {
- var opts = info.options || {},
- sizes = info.sizes || {},
- mb = function (bytes) { return Math.max(1, Math.round((bytes || 0) / 1048576)) + " MB" },
- created = info.created ? new Date(info.created) : null,
- text = "Backup found on the USB stick:\n"
- // a date before 2020 comes from a unit whose clock was not set (1970)
- if (created && (isNaN(created.getTime()) || created.getFullYear() < 2020)) {
- created = null
- }
- text += " made on " + (created ? created.toLocaleString() : "an unknown date")
- if (info.release) {
- text += " with MOD OS " + info.release
- }
- text += "\n pedalboards, banks, settings and presets (" + mb(sizes.user) + ")\n"
- if (opts.plugins) {
- text += " LV2 plugins (" + mb(sizes.plugins) + ")\n"
- }
- if (opts.device_configs) {
- text += " device configs (" + mb(sizes.device) + ")\n"
- }
- if (opts.user_files) {
- text += " user files (" + mb(sizes.files) + ")\n"
- }
- text += "\nThe restore replaces the pedalboards, banks, settings and presets on this MOD"
- if ($("#prefs-backup-configs").prop("checked") && opts.device_configs) {
- text += ", the device configs"
- }
- if ($("#prefs-backup-userfiles").prop("checked") && opts.user_files) {
- text += ", the user files"
- }
- text += ". Plugins and licences are only added, never removed. "
- + "The current data is kept aside on the MOD until the next restore.\n"
- if ($("#prefs-backup-userfiles").prop("checked") && ! opts.user_files) {
- text += "\nThis backup has no user files: the user files on this MOD stay as they are.\n"
- }
- if ($("#prefs-backup-configs").prop("checked") && ! opts.device_configs) {
- text += "\nThis backup has no device configs: the current ones stay as they are.\n"
- }
- if (info.format === 0) {
- text += "\nThis backup was made before MOD OS 1.15.\n"
- }
- return text + "\nContinue?"
- }
- function start_backup_restore() {
- var block = show_blocker("import")
- run_custom_command("backup-import " + backup_options(), function (resp) {
- if (resp.ok) {
- block.html('<p>Restore from USB stick complete!<br/>'
- +'The MOD now restarts its audio and web interface: reload this page in a few seconds.</p>')
- var re = $("<div class='button icon'>Reload</div>").appendTo(block);
- re.css("background-image", "url(img/icons/25/reload.png)");
- re.click(function () { location.reload(); });
- } else {
- block.html('<p>Restore from USB stick failed!<br/>' + resp.error + '</p>')
- var cl = $("<div class='button icon'>Close</div>").appendTo(block);
- cl.click(function () { block.remove(); });
- }
- }, function () {
- block.html('<p>Restore from USB stick: lost contact with the MOD.<br/>Reload this page in a few seconds.</p>')
- var re = $("<div class='button icon'>Reload</div>").appendTo(block);
- re.click(function () { location.reload(); });
- })
- }
- // ----------------------------------------------------------------------------------------------------------------
- // --- Boot & Restore
- $("#button-action-reboot").click(function () {
- ws.close()
- run_custom_command("reboot")
- })
- $("#button-action-reboot-needed").click(function () {
- $("#button-action-reboot").click()
- })
- $("#button-action-restore").click(function () {
- run_custom_command("restore")
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Audio Server
- // the server persists the buffer size for the next boot itself (/data/jack-buffer-size + the marker files)
- $("input[name=prefs-audio-buffer-size]").change(function () {
- var bufferSize = $(this).val()
- $.ajax({
- url: '/set_buffersize/' + bufferSize,
- method: 'POST',
- cache: false,
- success: function (resp) {
- if (! resp.ok) {
- set_buffer_size_radio(resp.size)
- new Notification('error', 'Could not change the buffer size to ' + bufferSize + ' frames', 5000)
- }
- },
- error: function () {
- set_buffer_size_radio($("#info-dsp-buffer-size").text())
- new Notification('error', 'Could not change the buffer size: communication failure', 5000)
- },
- })
- })
- $("#prefs-audio-mono-copy").click(function () {
- create_or_delete_file("jack-mono-copy", $(this).prop("checked"))
- })
- $("#prefs-audio-separate-spdif-outs").click(function () {
- create_or_delete_file("separate-spdif-outs", $(this).prop("checked"))
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Update channel
- // Stored as a preference only. Nothing reads it yet: the device does not send a channel
- // when it checks for updates (the server derives the group from the device registration),
- // so this switch becomes effective once the update service exposes a self-service group.
- $("input[name=prefs-update-channel]").click(function () {
- var channel = $(this).val()
- config_set("update-channel", channel)
- if (channel == "testing") {
- $("#prefs-update-channel-note").show()
- } else {
- $("#prefs-update-channel-note").hide()
- }
- })
- // --- Report a problem
- var problemReport = new ProblemReport({
- version: '{{version}}',
- feedbackUrl: '{{feedback_url}}',
- })
- $("#button-action-report").click(function () {
- problemReport.open()
- })
- // --- User Interface
- $(".prefs-ui-tool").click(function () {
- config_set($(this).data("key"), $(this).prop("checked") ? "on" : "off")
- })
- $("#prefs-ui-unstable-plugins").click(function () {
- config_set("show-unstable-plugins", bool2str($(this).prop("checked")))
- })
- $("#prefs-ui-stereo-cables").click(function () {
- config_set("merge-stereo-cables", bool2str($(this).prop("checked")))
- })
- // Readout follows the drag, value saved once on release -- a debounce on `input`
- // would drop the save if the page is left inside its window. No live preview: this is
- // a standalone page with no pedalboard in it, so the size applies on the next load.
- $("#prefs-ui-teleport-scale").on("input", function () {
- $("#prefs-ui-teleport-scale-value").text((parseFloat($(this).val()) || 1).toFixed(1) + "x")
- })
- $("#prefs-ui-teleport-scale").on("change", function () {
- config_set("teleport-label-scale", String(parseFloat($(this).val()) || 1))
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Services
- $("#prefs-service-netmanager").click(function () {
- enable_service("netmanager", $(this).prop("checked"), false, true)
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Workarounds
- $("#prefs-workarounds-autorestart-hmi").click(function () {
- create_or_delete_file("autorestart-hmi", $(this).prop("checked"), true)
- })
- // ----------------------------------------------------------------------------------------------------------------
- // --- Cleanup
- $("#button-action-delete").attr('disabled', true)
- var deleteEnabled = function() {
- var ok = $("#prefs-delete-confirm").val().toUpperCase() == "DELETE";
- var favorites = !!$("#prefs-delete-favorites").prop('checked');
- var hmiSettings = !!$("#prefs-delete-hmi-settings").prop('checked');
- var licenseKeys = !!$("#prefs-delete-license-keys").prop('checked');
- var banks = !!$("#prefs-delete-banks").prop('checked');
- var pedalboards = !!$("#prefs-delete-pedalboards").prop('checked');
- var plugins = !!$("#prefs-delete-plugins").prop('checked');
- var title = '';
- if (!favorites && !hmiSettings && !licenseKeys && !banks && !pedalboards && !plugins) {
- title = "You need to check at least one checkbox above";
- } else if (!ok) {
- title = 'You need type "DELETE" on the input above to confirm data removal';
- }
- var disabled = !ok || (!favorites && !hmiSettings && !licenseKeys && !banks && !pedalboards && !plugins);
- $("#button-action-delete").attr('disabled', disabled);
- $("#button-action-delete").attr('title', title);
- }
- $("#prefs-delete-confirm").change(deleteEnabled);
- $("#prefs-delete-confirm").keyup(deleteEnabled);
- $("#prefs-delete-favorites").click(deleteEnabled);
- $("#prefs-delete-hmi-settings").click(deleteEnabled);
- $("#prefs-delete-license-keys").click(deleteEnabled);
- $("#prefs-delete-banks").click(deleteEnabled);
- $("#prefs-delete-pedalboards").click(deleteEnabled);
- $("#prefs-delete-plugins").click(deleteEnabled);
- deleteEnabled();
- $("#button-action-delete").click(function() {
- var favorites = !!$("#prefs-delete-favorites").prop('checked');
- var hmiSettings = !!$("#prefs-delete-hmi-settings").prop('checked');
- var licenseKeys = !!$("#prefs-delete-license-keys").prop('checked');
- var banks = !!$("#prefs-delete-banks").prop('checked');
- var pedalboards = !!$("#prefs-delete-pedalboards").prop('checked');
- var plugins = !!$("#prefs-delete-plugins").prop('checked');
- var block = show_blocker("delete");
- system_cleanup(favorites, hmiSettings, licenseKeys, banks, pedalboards, plugins, function (resp) {
- if (resp.ok) {
- setTimeout(function () {
- block.html('<p>Delete operation complete!</p>')
- var re = $("<div class='button icon'>Reload</div>").appendTo(block);
- re.css("background-image", "url(img/icons/25/reload.png)");
- re.click(function () { location.reload(); });
- }, 1000)
- } else {
- block.html('<p>Delete operation failed!<br/>' + resp.error + '</p>')
- }
- })
- });
- $("#form-action-delete").click(function() {
- if ($("#prefs-delete-confirm").val().toUpperCase() == "DELETE") {
- $("#button-action-delete").click();
- }
- return false;
- });
- // ----------------------------------------------------------------------------------------------------------------
- // --- HMI Reflash
- $("#button-action-reflash").attr('disabled', true)
- var reflashEnabled = function() {
- var ok = $("#prefs-reflash-confirm").val().toUpperCase() == "REFLASH";
- var title = '';
- if (!ok) {
- title = 'You need type "REFLASH" on the input above to confirm Controller reflash';
- }
- $("#button-action-reflash").attr('disabled', !ok);
- $("#button-action-reflash").attr('title', title);
- }
- $("#prefs-reflash-confirm").change(reflashEnabled);
- $("#prefs-reflash-confirm").keyup(reflashEnabled);
- reflashEnabled();
- $("#button-action-reflash").click(function() {
- var block = show_blocker("reflash");
- var checkAlive = function() {
- $.ajax({
- url: '/hello',
- method: 'GET',
- cache: false,
- global: false,
- timeout: 1000,
- success: function() {
- block.html('<p>Controller reflash complete!</p>')
- var re = $("<div class='button icon'>Reload</div>").appendTo(block);
- re.css("background-image", "url(img/icons/25/reload.png)");
- re.click(function () { location.reload(); });
- },
- error: function() {
- setTimeout(checkAlive, 2000);
- },
- })
- }
- // Check if mod-ui is alive after 30 seconds
- setTimeout(checkAlive, 30000);
- enable_service("hmi-update", true, false, false);
- });
- $("#form-action-reflash").click(function() {
- if ($("#prefs-reflash-confirm").val().toUpperCase() == "REFLASH") {
- $("#button-action-reflash").click();
- }
- return false;
- });
- // ----------------------------------------------------------------------------------------------------------------
- // --- Device Updates
- var deviceUpdatesRespDev, deviceUpdatesRespVer
- $.ajax({
- method: 'GET',
- url: CONTROLCHAIN_URL + '/devices',
- success: function (resp) {
- deviceUpdatesRespDev = resp
- refresh_device_updates(deviceUpdatesRespDev, deviceUpdatesRespVer)
- },
- error: function () {
- console.log("Error: failed to get devices information")
- report_device_updates_failed()
- },
- cache: false,
- dataType: 'json'
- })
- $.ajax({
- method: 'GET',
- url: CONTROLCHAIN_URL + '/versions',
- success: function (resp) {
- deviceUpdatesRespVer = resp
- refresh_device_updates(deviceUpdatesRespDev, deviceUpdatesRespVer)
- },
- error: function () {
- report_device_updates_failed()
- },
- cache: false,
- dataType: 'json'
- })
- // ----------------------------------------------------------------------------------------------------------------
- // start code for ajax loading bar
- NProgress.configure({
- template: '<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'
- });
- $(document)
- .ajaxStart(function(data) {
- NProgress.start();
- })
- .ajaxComplete(function() {
- NProgress.done();
- });
- // end code for ajax loading bar
- })
- </script>
- <script type="text/javascript" src="js/templates.js?v={{version}}"></script>
- <script type="text/javascript" src="js/common.js?v={{version}}"></script>
- <script type="text/javascript" src="js/file_transfer.js?v={{version}}"></script>
- <script type="text/javascript" src="js/window.js?v={{version}}"></script>
- <script type="text/javascript" src="js/modgui.js?v={{version}}"></script>
- <script type="text/javascript" src="js/notification.js?v={{version}}"></script>
- <script type="text/javascript" src="js/nprogress.js?v={{version}}"></script>
- <script type="text/javascript" src="js/report.js?v={{version}}"></script>
- </head>
- <!-- END HEAD -->
- <!-- BODY -->
- <body class="mod-dark">
- <!-- PRELOAD -->
- <div class="mod-hidden">
- <img src="img/icons/blocked.svg" alt=""/>
- <img src="img/icons/25/reload.png" width="25px" height="25px" alt=""/>
- </div>
- <!-- END PRELOAD -->
- <!-- NOTIFICATIONS -->
- <div id="notifications" class="mod-hidden"></div>
- <!-- END NOTIFICATIONS -->
- <!-- WRAPPER -->
- <div id="wrapper">
- <!-- BANKS|SETTINGS -->
- <div id="bank-library">
- <div class="box clearfix">
- <header>
- <h1 class="bottom top">MOD Settings</h1>
- </header>
- <div class="pedalboards clearfix js-pedalboards"></div>
- </div>
- <!-- BANK|SETTINGS-LIST -->
- <div id="bank-list">
- <div id="tab-device" class="add-bank selected">Device</div>
- <div id="tab-audio" class="add-bank">Audio</div>
- <div id="tab-ui" class="add-bank">User Interface</div>
- <div id="tab-updates" class="add-bank">Updates</div>
- <div id="tab-backup" class="add-bank">Backup & Restore</div>
- <div id="tab-developer" class="add-bank">Developer</div>
- <div id="tab-maintenance" class="add-bank">Maintenance</div>
- <a href="/" id="go-back"><span class="icon-return"></span>Go back</a>
- </div>
- <!-- END BANK|SETTINGS-LIST -->
- <!-- SETTINGS PAGES -->
- <div class="settings-page-content">
- <!-- REBOOT NEEDED -->
- <div id="settings-reboot-needed" class="mod-hidden">
- <input type="button" id="button-action-reboot-needed" value="Reboot MOD"></input>
- <b>Reboot needed.</b> Some of the changes you made only take effect after a reboot.<br/>
- Note that all unsaved pedalboard changes will be lost.
- </div>
- <!-- END REBOOT NEEDED -->
- <!-- SETTINGS PAGE (DEVICE) -->
- <div class="settings-page" id="settings-page-device">
- <h1>System Information</h1>
- <form class="form">
- <h2>System</h2>
- <p>
- <b>Unit:</b> <span id="info-system-unit">---</span><br/>
- <b>Build Date:</b> <span id="info-system-date">---</span><br/>
- <b>OS Version:</b> {{version}}<br/>
- </p>
- <h2>Kernel</h2>
- <p>
- <b>Machine:</b> <span id="info-kernel-machine">---</span><br/>
- <b>Release:</b> <span id="info-kernel-release">---</span><br/>
- <b>Version:</b> <span id="info-kernel-version">---</span><br/>
- </p>
- <h2>Audio</h2>
- <p>
- <b>Buffer Size:</b> <span id="info-dsp-buffer-size">{{bufferSize}}</span> frames<br/>
- <b>Sample Rate:</b> {{sampleRate}} Hz<br/>
- <b>DSP Load:</b> <span id="info-dsp-load">--.- %</span><br/>
- </p>
- </form>
- <h1>Bluetooth</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-bluetooth-custom">
- Use custom Bluetooth device name:
- </input>
- <input type="text" value="" id="prefs-bluetooth-name" autocomplete="off" disabled></input>
- </label>
- </form>
- <h1>Reboot</h1>
- <form class="form">
- <p>
- <b>Reboot the MOD</b>.<br/>
- Note that all unsaved pedalboard changes will be lost.
- </p>
- <label>
- <input type="button" id="button-action-reboot" value="Reboot MOD"></input>
- </label>
- </form>
- </div>
- <!-- END SETTINGS PAGE (DEVICE) -->
- <!-- SETTINGS PAGE (AUDIO) -->
- <div class="settings-page mod-hidden" id="settings-page-audio">
- <h1>Outputs</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-audio-mono-copy">
- Copy mono output buffer to unused channel
- </input>
- </label>
- <p>
- Automatically copy the audio data from an unconnected output to another.<br/>
- With this enabled, the 2 outputs will receive the same data if one of them is unconnected.<br/>
- Takes effect after a reboot.
- </p>
- <div id="prefs-audio-separate-spdif-outs_div">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-audio-separate-spdif-outs">
- Separate S/PDIF outputs
- </input>
- </label>
- <p>
- The Duo X S/PDIF outputs can be set to mirror the analog output or be treated independently.<br/>
- Mirror mode is default, where S/PDIF will contain the same audio signal as the analog outputs.<br/>
- Enable this option to have 2 extra outputs on your pedalboard.<br/>
- Takes effect after a reboot.
- </p>
- </div>
- </form>
- <h1>Buffer Size</h1>
- <form class="form">
- <div id="prefs-audio-buffer-size">
- {% for size in bufferSizes %}
- <label>
- <input type="radio" autocomplete="off" name="prefs-audio-buffer-size" value="{{size}}"{% if size == bufferSize %} checked{% end %}>
- {{size}} frames{% if size == 128 %} (default){% end %}
- </input>
- </label>
- {% end %}
- </div>
- <p>
- MOD runs at 128 frames by default.<br/>
- 256 frames gives plugins twice the time per cycle, at the cost of doubling the latency: use it if you need the extra headroom.<br/>
- {% if 64 in bufferSizes %}
- 64 frames halves the latency but leaves plugins half the time per cycle: a pedalboard that runs fine at 128 frames can drop out at 64.<br/>
- {% end %}
- Changing the buffer size restarts the audio and reloads the current pedalboard; unsaved changes are kept.
- </p>
- </form>
- </div>
- <!-- END SETTINGS PAGE (AUDIO) -->
- <!-- SETTINGS PAGE (UPDATES) -->
- <div class="settings-page mod-hidden" id="settings-page-updates">
- <h1>MOD OS</h1>
- <form class="form">
- <p>
- <b>Installed version:</b> {{version}}<br/>
- Updates are offered on the main screen: when a new release is available for this unit,
- the update icon in the bottom bar tells you so. Click it to download and install.
- </p>
- <p>
- <b>Update channel</b>.<br/>
- Stable receives final releases only. Testing also receives release candidates
- before they become final, so you can try new features early and report problems.
- </p>
- <label>
- <input type="radio" name="prefs-update-channel" value="stable" id="prefs-update-channel-stable" autocomplete="off">
- Stable
- </input>
- </label>
- <label>
- <input type="radio" name="prefs-update-channel" value="testing" id="prefs-update-channel-testing" autocomplete="off">
- Testing
- </input>
- </label>
- <p id="prefs-update-channel-note" class="mod-hidden">
- Note: the update server does not honour this setting yet. Testing releases are currently
- offered to registered devices only, or installed manually from the announcement.
- </p>
- </form>
- <h1>Manual Update</h1>
- <form class="form">
- <p>
- <b>Start the MOD's restore/update mode</b>, where you can manually update the MOD via
- USB Mass Storage mode.<br/>
- Note that all unsaved pedalboard changes will be lost.
- </p>
- <label>
- <input type="button" id="button-action-restore" value="Start update mode"></input>
- </label>
- </form>
- <h1>Control Chain Firmware</h1>
- <form class="form" id="settings-cc-firmware">
- <p id="settings-cc-firmware-status">
- Looking for Control Chain firmware updates...
- </p>
- </form>
- </div>
- <!-- END SETTINGS PAGE (UPDATES) -->
- <!-- SETTINGS PAGE (BACKUP & RESTORE) -->
- <div class="settings-page mod-hidden" id="settings-page-backup">
- <h1>Backup & Restore</h1>
- <form class="form">
- <p>
- <b>Backup and restore user data using a USB stick</b>.<br/>
- A backup always holds your pedalboards, banks, settings and plugin presets, plus the parts you tick below.
- The previous backup on the stick is kept until the new one is complete.<br/>
- A restore replaces the pedalboards, banks, settings and presets on this MOD (and the ticked parts
- that the backup holds). Plugins and licences are only added, never removed.
- The data a restore replaces is kept aside on the MOD until the next restore.<br/>
- The USB stick needs enough free space. A FAT32 stick holds at most 4 GB per part (plugins, user files):
- above that, leave the part out or, on a MOD Dwarf, use a stick formatted as exFAT.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-backup-configs">
- Also backup/restore device configs (audio gains, bluetooth config, etc)
- </input>
- </label>
- <br/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-backup-plugins">
- Also backup/restore LV2 plugins
- </input>
- </label>
- <br/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-backup-userfiles">
- Also backup/restore user files (NAM models, IRs, audio loops, samples, etc)
- </input>
- </label>
- <br/>
- <label>
- <input type="button" id="button-action-backup-export" value="Backup user data..."></input>
- </label>
- <label>
- <input type="button" id="button-action-backup-import" value="Restore user data..."></input>
- </label>
- </form>
- </div>
- <!-- END SETTINGS PAGE (BACKUP & RESTORE) -->
- <!-- SETTINGS PAGE (USER INTERFACE) -->
- <div class="settings-page mod-hidden" id="settings-page-ui">
- <h1>Status Bar</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-xruns" data-key="ui-xruns">
- Xrun counter
- </input>
- </label>
- <p>
- Count the audio dropouts (xruns) since the last reset. Click the counter to reset it.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-buffersize" data-key="ui-buffersize">
- Buffer size
- </input>
- </label>
- <p>
- Show the audio buffer size in frames. Click it to change the size; the pedalboard reloads.
- </p>
- <label class="prefs-ui-cpu-stats-option">
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-cpu-stats" data-key="ui-cpu-stats">
- CPU speed and temperature
- </input>
- </label>
- <p class="prefs-ui-cpu-stats-option">
- Show the processor speed and temperature. Click it to step through the available speeds.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-ping-times" data-key="ui-ping-times">
- Network and controller ping times
- </input>
- </label>
- <p>
- Show how long the unit takes to answer the browser and the controller.
- </p>
- </form>
- <h1>Plugins and Pedalboards</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-store-install-all"
- data-key="ui-store-install-all" data-fallback="ui-store-all">
- Install All in the Plugin Store
- </input>
- </label>
- <p>
- A button to install every plugin shown in the Plugin Store in one go.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-store-update-all"
- data-key="ui-store-update-all" data-fallback="ui-store-all">
- Update All in the Plugin Store
- </input>
- </label>
- <p>
- A button to update every installed plugin that has a new version, in one go.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" class="prefs-ui-tool" id="prefs-ui-share" data-key="ui-share">
- Export and Import of presets and pedalboards
- </input>
- </label>
- <p>
- Export / Import buttons in each plugin's preset list (.modpreset files, for example to send a preset to a
- plugin developer) and in the pedalboard library (.modpedalboard files).
- </p>
- </form>
- <h1>Pedalboard</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-ui-stereo-cables">
- Merge stereo cables
- </input>
- </label>
- <p>
- Draw the two halves of a stereo connection as a single cable, instead of
- one per channel. Pairs wired straight across are merged, and so are a mono
- output into both halves of a stereo input and a stereo output into one mono
- input; a left/right swap stays as two cables so it remains visible. Off by
- default.
- </p>
- <label>
- Teleport label size
- <input type="range" autocomplete="off" id="prefs-ui-teleport-scale"
- min="0.6" max="2" step="0.1" style="vertical-align:middle;width:160px">
- <span id="prefs-ui-teleport-scale-value"></span>
- </label>
- <p>
- How large the label boxes on a split cable are drawn.
- </p>
- </form>
- <p class="prefs-ui-note">
- These options apply when you go back to the main screen.
- </p>
- </div>
- <!-- END SETTINGS PAGE (USER INTERFACE) -->
- <!-- SETTINGS PAGE (DEVELOPER) -->
- <div class="settings-page mod-hidden" id="settings-page-developer">
- <h1>Plugin Store</h1>
- <form class="form">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-ui-unstable-plugins">
- Show beta plugins in the Store
- </input>
- </label>
- <p>
- Show option to list 'beta' plugins in the Plugin Store.<br/>
- Note that beta plugins can be unstable and cause crashes.
- If you share a pedalboard containing beta plugins, it will only be available to users that explicitly accept pedalboards with beta plugins.<br/>
- Just remember: things can break!
- </p>
- </form>
- <h1>Services</h1>
- <form class="form">
- <p>
- Note: Each additional service you enable consumes a small amount of CPU.<br/>
- Only enable services that you absolutely need.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-service-netmanager"> JACK Net Manager (EXPERIMENTAL)</input>
- </label>
- <br/>
- </form>
- <h1>Workarounds</h1>
- <form class="form">
- <div id="workarounds-autorestart-hmi">
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-workarounds-autorestart-hmi">
- Automatically restart controller screen
- </input>
- </label>
- <p>
- If the controller displays locks up or stops working correctly, we can try to detect this and automatically trigger a restart.<br/>
- This is not completely safe though, false positives can happen and the controller screen might be restarted by mistake.<br/>
- Takes effect after a reboot.
- </p>
- </div>
- </form>
- </div>
- <!-- END SETTINGS PAGE (DEVELOPER) -->
- <!-- SETTINGS PAGE (MAINTENANCE) -->
- <div class="settings-page mod-hidden" id="settings-page-maintenance">
- <h1>Report a problem</h1>
- <form class="form">
- <p>
- <b>Found a bug, or something that does not behave as it should?</b><br/>
- This collects the system details a good report needs, for you to paste into the
- forum topic of this release. Nothing is sent automatically.
- </p>
- <label>
- <input type="button" id="button-action-report" value="Report a problem..."></input>
- </label>
- </form>
- <h1>Reflash controller</h1>
- <form class="form">
- <p>
- <b>Reinstall the firmware for the controller board.</b><br/>
- This option is here for support reasons; If the power to your device was cut while installing the controller firmware,
- your device may end up in a state where the controller is not fully functional.<br/>
- <br />
- While the reflashing is happening, please DO NOT DISCONNECT THE POWER to the device.<br/>
- There is a RISK OF BRICKING THE DEVICE if the power is cut.
- </p>
- <label>
- To confirm, please type the word "REFLASH":
- <input type="text" id="prefs-reflash-confirm" size="10" style="text-transform: uppercase" autocomplete="off" />
- </label>
- <br/>
- <label>
- <input type="button" id="button-action-reflash" value="Reflash"></input>
- </label>
- <br/>
- <input type="submit" id="form-action-reflash" style="display: none;"></input>
- </form>
- <h1>Delete user data</h1>
- <form class="form">
- <p>
- <b>Delete selected user data from the device.</b><br />
- This will PERMANENTLY DELETE the selected USER DATA. This action is IRREVERSIBLE.
- The device won't work properly until new items are created or installed.
- </p>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-delete-favorites"> Clear favorite plugin list</input>
- </label>
- <br/>
- <label id="prefs-delete-hmi-settings_label">
- <input type="checkbox" autocomplete="off" id="prefs-delete-hmi-settings"> Clear device settings</input>
- </label>
- <br id="prefs-delete-hmi-settings_br"/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-delete-license-keys"> Clear plugin license keys</input>
- </label>
- <br/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-delete-banks"> Delete all Banks</input>
- </label>
- <br/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-delete-pedalboards"> Delete all Pedalboards</input>
- </label>
- <br/>
- <label>
- <input type="checkbox" autocomplete="off" id="prefs-delete-plugins"> Delete all Plugins</input>
- </label>
- <br/>
- <label>
- To confirm, please type the word "DELETE":
- <input type="text" id="prefs-delete-confirm" autocomplete="off" size="10" style="text-transform: uppercase" />
- </label>
- <br/>
- <label>
- <input type="button" id="button-action-delete" value="Delete"></input>
- </label>
- <br/>
- <input type="submit" id="form-action-delete" style="display: none;"></input>
- </form>
- </div>
- <!-- END SETTINGS PAGE (MAINTENANCE) -->
- </div>
- <!-- END SETTINGS PAGES -->
- <!-- CC DEVICE UPDATE WINDOW -->
- <div id="cc-device-update-window" class="save-popup mod-hidden">
- <div class="mod-box" style="width: 600px; margin:-150px -280px">
- <h1 class="pull-left">Control Chain Device Update</h1><span class="js-cancel close">×</span>
- <form class="bottom">
- <div class="clearfix"></div>
- <div id="cc-device-update-text">
- <p>
- Your Control Chain device firmware is ready to be updated.
- </p>
- <p>
- To begin, follow these steps:
- </p>
- <ul>
- <li>Disconnect the device from the Control Chain/Ethernet port</li>
- <li>Hold down the first footswitch on the Control Chain device</li>
- <li>While the first footswitch is down, connect the device to the MOD unit via USB</li>
- <li>Wait for the "update completed" message</li>
- <li>Disconnect the device from the USB port</li>
- <li>Connect it to the Control Chain/Ethernet port once again</li>
- </ul>
- <p>
- Note: The update should only take a few seconds.
- </p>
- </div>
- </form>
- </div>
- </div>
- <!-- END CC DEVICE UPDATE WINDOW -->
- </div>
- <!-- END BANKS|SETTINGS -->
- <!-- END WRAPPER -->
- </div>
- </body>
- <!-- END BODY -->
- </html>
|