From 2569ef966a1d20d3916017fa44fbb6cd03c69420 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:33:07 +0200 Subject: [PATCH 01/13] Update blc.js additional functions (change colors in settings) --- apps/blc/blc.js | 329 +++++++++++++++++++++++++++++------------------- 1 file changed, 199 insertions(+), 130 deletions(-) diff --git a/apps/blc/blc.js b/apps/blc/blc.js index 8a0f93d708..b12492a5ee 100644 --- a/apps/blc/blc.js +++ b/apps/blc/blc.js @@ -2,135 +2,204 @@ { // must be inside our own scope here so that when we are unloaded everything disappears // we also define functions using 'let fn = function() {..}' for the same reason. function decls are global - let drawTimeout; - - // Actually draw the watch face - let draw = function() - { - // Bangle.js2 -> 176x176 - var x_rgt = g.getWidth(); - var y_bot = g.getHeight(); - //var x_cntr = x_rgt / 2; - var y_cntr = y_bot / 18*7; // not to high because of widget-field (1/3 is to high) - g.reset().clearRect(Bangle.appRect); // clear whole background (w/o widgets) - - let white = [1,1,1]; - let red = [1,0,0]; - let green = [0,1,0]; - //let blue = [0,0,1]; - let yellow = [1,1,0]; - //let magenta = [1,0,1]; - //let cyan = [0,1,1]; - let black = [0,0,0]; - let bord_col = white; - let col_off = black; - - var col = new Array(red, green, yellow, yellow); // [R,G,B] - - let pot_2 = [1, 2, 4, 8, 16, 32]; // array with powers of two, because power-op (**) - // doesn't work -> maybe also faster - - var nr_lines = 4; // 4 rows: hour (hr), minute (min), day (day), month (mon) - - // Arrays: [hr, min, day, mon] - //No of Bits: 5 6 5 4 - let msbits = [4, 5, 4, 3]; // MSB = No bits - 1 - let rad = [12, 12, 8, 8]; // radiuses for each row - var x_dist = 28; - let y_dist = [0, 30, 60, 85]; // y-position from y_centr for each row from top - // don't calc. automatic as for x, because of different spaces - var x_offs_rgt = 16; // distance from right border (layout) - - // Date-Time-Array: 4x6 Bit - //var idx_hr = 0; - //var idx_min = 1; - //var idx_day = 2; - //var idx_mon = 3; - var dt_bit_arr = [[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0]]; - - var date_time = new Date(); - var hr = date_time.getHours(); // 0..23 - var min = date_time.getMinutes(); // 0..59 - var day = date_time.getDate(); // 1..31 - var mon = date_time.getMonth() + 1; // GetMonth() -> 0..11 - - let dt_array = [hr, min, day, mon]; - - -//////////////////////////////////////// -// compute bit-pattern from time/date and draw leds -//////////////////////////////////////// - var line_cnt = 0; - var cnt = 0; - var bit_cnt = 0; - - while (line_cnt < nr_lines) - { - - //////////////////////////////////////// - // compute bit-pattern - bit_cnt = msbits[line_cnt]; - - while (bit_cnt >= 0) - { - if (dt_array[line_cnt] >= pot_2[bit_cnt]) - { - dt_array[line_cnt] -= pot_2[bit_cnt]; - dt_bit_arr[line_cnt][bit_cnt] = 1; - } - else - { - dt_bit_arr[line_cnt][bit_cnt] = 0; - } - bit_cnt--; - } - - //////////////////////////////////////// - // draw leds (first white border for black screen, then led itself) - cnt = 0; - - while (cnt <= msbits[line_cnt]) - { - g.setColor(bord_col[0], bord_col[1], bord_col[2]); - g.drawCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-20+y_dist[line_cnt], rad[line_cnt]); - - if (dt_bit_arr[line_cnt][cnt] == 1) - { - g.setColor(col[line_cnt][0], col[line_cnt][1], col[line_cnt][2]); - } - else - { - g.setColor(col_off[0], col_off[1], col_off[2]); - } - g.fillCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-20+y_dist[line_cnt], rad[line_cnt]-1); - cnt++; - } - line_cnt++; - } - - // queue next draw - if (drawTimeout) clearTimeout(drawTimeout); - drawTimeout = setTimeout(function() - { - drawTimeout = undefined; - draw(); - }, 60000 - (Date.now() % 60000)); - }; - - // Show launcher when middle button pressed - Bangle.setUI( - { - mode : "clock", - remove : function() - { - // Called to unload all of the clock app - if (drawTimeout) clearTimeout(drawTimeout); - drawTimeout = undefined; - } - }); - // Load widgets - Bangle.loadWidgets(); - draw(); - setTimeout(Bangle.drawWidgets,0); + const SETTINGSFILE = "BinaryClk.settings.json"; + + // variables defined from settings + let HourCol; + let MinCol; + let DayCol; + let MonCol; + let RingOn; + + // color arrays + // !!! don't change order unless change oder in BinaryClk.settings.js !!! + // !!! order must correspond to each other between arrays !!! + let LED_Colors = ["#FFF", "#F00", "#0F0", "#00F", "#FF0", "#F0F", "#0FF", "#000"]; + let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; + + // load settings + let loadSettings = function() + { + function def (value, def) {return value !== undefined ? value : def;} + + var settings = require('Storage').readJSON(SETTINGSFILE, true) || {}; + // get name from setting, find index of name and assign corresponding color code by index + HourCol = LED_Colors[LED_ColorNames.indexOf(def(settings.HourCol, "red"))]; + MinCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MinCol, "green"))]; + DayCol = LED_Colors[LED_ColorNames.indexOf(def(settings.DayCol, "yellow"))]; + MonCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MonCol, "yellow"))]; + RingOn = def(settings.RingOn, true); + + delete settings; // settings in local var -> no more required + } + + + function getTemperature() + { + try + { + var temperature = E.getTemperature(); + var formatted = require("locale").temp(temperature).replace(/[^\d-]/g, ''); + return formatted; + } + catch(ex) + { + print(ex); + return "?"; + } + } + + function getSteps() + { + var steps = Bangle.getHealthStatus("day").steps; + return steps; + } + + + let drawTimeout; + + // actually draw the watch face + let draw = function() + { + // Bangle.js2 -> 176x176 + var x_rgt = g.getWidth(); + var y_bot = g.getHeight(); + var x_cntr = x_rgt / 2; + var y_cntr = y_bot / 18*7; + g.reset().clearRect(Bangle.appRect); // clear whole background (w/o widgets) + + var white = "#FFF"; + var black = "#000"; + var bord_col = white; + var col_off = black; + + var col = new Array(HourCol, MinCol, DayCol, MonCol); // each #rgb + if (g.theme.dark) + { + bord_col = white; + col_off = black; + } + else + { + bord_col = black; + col_off = white; + } + + let pwr2 = [1, 2, 4, 8, 16, 32]; // array with powers of 2, because poweroperator '**' doesnt work + // maybe also faster + + + var no_lines = 4; // 4 rows: hour (hr), minute (min), day (day), month (mon) + var no_hour = 5; + var no_min = 6; + var no_day = 5; + var no_mon = 4; + + // arrays: [hr, min, day, mon] + let msbits = [no_hour-1, no_min-1, no_day-1, no_mon-1]; // MSB = No bits - 1 + let rad = [13, 13, 9, 9]; // radiuses for each row + var x_dist = 29; + let y_dist = [0, 35, 75, 100]; // y-position from y_centr for each row from top + // don't calc. automatic as for x, because of different spaces + var x_offs_rgt = 15; // offset from right border (layout) + var y_offs_cntr = 25; // vertical offset from center + + //////////////////////////////////////// + // compute bit-pattern from time/date and draw leds + //////////////////////////////////////// + + // date-time-array: 4x6 bit + var idx_hour = 0; + var idx_min = 1; + var idx_day = 2; + var idx_mon = 3; + var dt_bit_arr = [[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0]]; + + var date_time = new Date(); + var hour = date_time.getHours(); // 0..23 + var min = date_time.getMinutes(); // 0..59 + var day = date_time.getDate(); // 1..31 + var mon = date_time.getMonth() + 1; // GetMonth() -> 0..11 + + let dt_array = [hour, min, day, mon]; + + var line_cnt = 0; + var cnt = 0; + var bit_cnt = 0; + + while (line_cnt < no_lines) + { + + //////////////////////////////////////// + // compute bit-pattern + bit_cnt = msbits[line_cnt]; + + while (bit_cnt >= 0) + { + if (dt_array[line_cnt] >= pwr2[bit_cnt]) + { + dt_array[line_cnt] -= pwr2[bit_cnt]; + dt_bit_arr[line_cnt][bit_cnt] = 1; + } + else + { + dt_bit_arr[line_cnt][bit_cnt] = 0; + } + bit_cnt--; + } + + //////////////////////////////////////// + // draw leds (and border, if enabled) + cnt = 0; + + while (cnt <= msbits[line_cnt]) + { + if (RingOn) // draw outer ring, if enabled + { + g.setColor(bord_col); + g.drawCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]); + } + if (dt_bit_arr[line_cnt][cnt] == 1) + { + g.setColor(col[line_cnt]); + } + else + { + g.setColor(col_off); + } + g.fillCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]-1); + cnt++; + } + line_cnt++; + } + + // queue next draw + if (drawTimeout) clearTimeout(drawTimeout); + drawTimeout = setTimeout(function() + { + drawTimeout = undefined; + draw(); + }, 60000 - (Date.now() % 60000)); + } + + + // Init the settings of the app + loadSettings(); + + // Show launcher when middle button pressed + Bangle.setUI( + { + mode : "clock", + remove : function() + { + // Called to unload all of the clock app + if (drawTimeout) clearTimeout(drawTimeout); + drawTimeout = undefined; + } + }); + // Load widgets + Bangle.loadWidgets(); + draw(); + setTimeout(Bangle.drawWidgets,0); } From 2da349874b4fc63ff7f90bd89b3bd143339874b5 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:35:14 +0200 Subject: [PATCH 02/13] Update metadata.json --- apps/blc/metadata.json | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/apps/blc/metadata.json b/apps/blc/metadata.json index 174926ebca..53dde47e3e 100644 --- a/apps/blc/metadata.json +++ b/apps/blc/metadata.json @@ -1,10 +1,10 @@ { "id":"blc", "name":"Binary LED Clock", - "version": "0.10", - "description": "Binary LED Clock with date", + "version": "0.40", + "description": "a binary LED-Clock with time and date and customizable LED-colors", "icon":"blc-icon.png", - "screenshots": [{"url":"screenshot_blc.bmp"}], + "screenshots": [{"url":"screenshot_blc_1.bmp"},{"url":"screenshot_blc_2.bmp"}], "type": "clock", "tags": "clock", "supports": ["BANGLEJS2"], @@ -12,6 +12,8 @@ "readme": "README.md", "storage": [ {"name":"blc.app.js","url":"blc.js"}, + {"name":"blc.settings.js","url":"blc.settings.js"}, {"name":"blc.img","url":"blc-icon.js","evaluate":true} - ] + ], + "data": [{"name":"blc.settings.json"}] } From ca055b4a31b7cd1676aec5a6a7c7fc774f73525b Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:37:23 +0200 Subject: [PATCH 03/13] upload new screenshots upload new screenshots for V0.4 --- apps/blc/screenshot_blc_1.bmp | Bin 0 -> 92982 bytes apps/blc/screenshot_blc_2.bmp | Bin 0 -> 92982 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 apps/blc/screenshot_blc_1.bmp create mode 100644 apps/blc/screenshot_blc_2.bmp diff --git a/apps/blc/screenshot_blc_1.bmp b/apps/blc/screenshot_blc_1.bmp new file mode 100644 index 0000000000000000000000000000000000000000..8a8c86ce5683649fdda1f9837764aaf13b70081f GIT binary patch literal 92982 zcmeI5;g#Gr42112QbHz|)L^6OXn^=JC^@A>QJk3Z5Vz0T+5246t{1V8`;KmY_l00ck)1V8`;KmY_l00ck) z1V8`;KmY_l00ck)1V8`;KmY_l00ck)1V8`;KmY_l00ck)1V8`;KmY{38-d@~m)G{M zuD`#ht=F#KDjVHqhSD{`w%&DXdaGW~?TlN~TlJ1r{U}eDu7|eu5_^r)#_N|? z_}Vj#zo)I&uHgd$AOHd&00JNY0w4eaAOHfP1n?)ggm*6pLH*GB^LwkVjFG2H*SfaS z#vIZH*h-cTHO*!<8Wtr_8C`4HvJKpBC)3`1SYg7JIXK?x!|0VMUKZ=FRcv)k&1nN{ zb(V{%bj@(~j6QpitvhTK86 zh6G<+s_gbeL9aZ;y0crwR(Hj=RMCVW5u1V8`;KmY_l00ck) z1V8`;KmY_l00ck)1V8`;KmY_l00ck)1V8`;KmY_l00cl_5d!RAH!8Q!v%xko+z7(( z+=l|OXUuRLwrY3mMI#rCq-=8ZXR z)9LcSY#YG#63F*Pm$vQ-)%roUsm@;WMFIcgLR%VpL`pTIncJVH}xX{f_iR8DA)$D?F4XmUG{%JxFFkrH$_QGC+HHK+yW0S00qVNhv4FP zm{7Ss=*vvc~c^kr1fy9#UXFUTyq7+lTu0GH zPrePv9B4bS=i3wk!c8+#5Nre3QZTk0)%63>As3&;ez&cD!;-R@Rub!LP1^vr`c#w3 zXPKLe2H7^(Tk^rC5T;}I4u zrkS{9hI0h&>%unf$nLaJ0Ra#I0T2KI5C8!X009sH0T2KI5CDOV2;c`t>9F>K5Yb() zpF=i(sQMDv79Y+U3dHq>vxb5%U@LCHrI_fY_k`v;l-f1*V!bl0trzQ++u3T*U`D6v zglo6VEQ2{a5SVC&GG&L&A)}4JbTgnOY@pXyAKzOa^@I4`SuC1phz?@$yV;udYZ4!L zA2mby?F2g}c58}MisycwU$0sK|i1$&IUn0BoMxD zJ#wQ#>&K(ZNu>6X}RpNOj_FwqifZwNOeaD2B? zb%p8snqI6|Cc1jDUb&rZbeAP`2fb!jyacu&!&yUtxZZHqQ1At8#VxoO3rY6%`6|qC z?!4|XV0&kR3J8Dz2!H?xfB*=900@8p2!H?xfB*=9z?uZapJfFVhXnHfVIci%7_ZL} z2s(PvcDT#Z51p0}ZCP=+3IrVj1!hO!@<_Q#>4ef1_jTF1cW&=z4m&`SrD9*LZYUrJ+e>>W4C}Z;uK;`QpT@Y+4cF ztB%0sq~6{S>~o+#N%ko1rgiSEx()zT7XqK{hvSt0|5%`YxHrS0yqtW!jmraasTCOO z2)wf&>Qk%J(dn0yq}y7P#`W|xuAg=u)iR8S1PaMh7X1C9J~bAs^Z1x`x0a{XicMWzb1}30&z~ z^-6-_n7{>N@b`;W8tQ>GNH4k-^_RevqE)XX7>)^CFn*#R>eDa%kV4l*wuejL>RGE^ zNiZA}xL|yHKd^JBen`35BihL&FjccYzp4U;GXyRe-`)=_aebcsekif;Uzs6ptpqOp zV4bYiD_5a@Xf;Dw@ZJVWe|6sPD|`=0cb6{PAFY56hja} WAmZFxp2Ph3WEdiX00cnbPT)WNq@{)c literal 0 HcmV?d00001 diff --git a/apps/blc/screenshot_blc_2.bmp b/apps/blc/screenshot_blc_2.bmp new file mode 100644 index 0000000000000000000000000000000000000000..ee07e3bb3942b81c845a5e4258b0f5c1bc84f00c GIT binary patch literal 92982 zcmeI3VV2uA41|+g^awpc4$%KSNiNqLwxndCGz5wO1lXiKe%dTa4+h{zNZ#yA{`&jZ z@1H;F>sR^uvwZ#Y`1<+dk1{H+$NT$a|MOqGKmY_l00ck)1V8`;KmY_l00ck)1V8`; zKmY_l00ck)1V8`;KmY_l00ck)1V8`;KmY_l00ck)1V8`;KmY_l00ck)1ipqq`+o|` zIBMUpjUxFnpY8NZ1Mur+SM&pH1!h7o$TTY-bxoNA+K8bAGtN@|y4F?cSh(^OG zX+ks_$u=GW%QF9TLpR{CH--taUaVIZn0m2ZdDzB7nE&*p3RN7AXN6?&32T5*PjS16 z3@DU0ol-`9q|_^AF57qrRK`*R1BcIjL;ynV+3j{SqZr<#LxFg|45NmE8@BNf#9}62 z+z7{`$UHbR(P1%35X^;65Rimocm(3shfzbp4cqveLM&$TMf5{Cpd<*BAH7&!5{k?l zS=`6f;;@(`2v;>t{hs+zIrVOw#R0+tob~P)-fp|EQbwnz)GK8!TSH4&%bCfbf8}b-Rj&>Auj5^~zGQUaVIhw($@geK|wOhHgN^gm>SRCPbrQh%_M@jbs}S zfn`}}x-k@hIM}wk?uGZ(+t`b7FTA&YVb#91g~vl^Q>-;EK-yPS@vUbWf2VEKuHgd$ zAOHd&00JNY0w4eaAOHfX1n@Vwf_E(lN&V3K`+IL)Sw;;PeiLK(6|tBo(N@YA03pFv zvJ6<$Y*wRTrSy)hZI8KZ*#=HiXSF9Ew&1X34uMmBF?wYwuZpF|!g+BPTOCt#wF$O5 z%gI!_W_YxRzV;+reE}b>G20LYdK{@wF$Ns%W1ThW-vS=l5D5J_TEC2 zea?y;Mpc3R;NEG=cBq)Ds#W+f$B4iKNJY|*O0B<(h%XxK8!*?lrtDo z63@vOC0aQaec6XmRe&hBxxYQN%+DaP>s5Ze?vJ74;8*g7x z?yYAT!!{5?6ioPl00@8p2!H?xfB*=900@8p2!H?xfB*=900@8p2!H?xfB*=900@8p z2!H?xfB*=9z$66NKR4Q^_iKY~VYm>4;kge5V$VDX6coK{Q;4w_i^F1u0?|CR+Ae{k zPsEZg7L%$i8H@8p-u5lMa<{#L&~}KrfEBAvf{p;k`?H#3f=+}$vm;#z%XYx#gWw|ct;$7yGSMA+X>p;k`-ElE87Ywi8Vm^6zhf1A`jCbzt5(GUCSZl!?VOPpRk)Q=YjUJYGYdB1R=u~{Xn-sUiW4k zTvD|y4I29f>~`Bt0?K~AFUZzcBt^Zr+Pf{$fskQKh>`|3Yfh@FXPZ>*TDCnnQR{9R zQ3aTMlB!+H)$L$}uS)exFV-tda=louT+UW~2zH^m8UF7LdlE#f zLBP=rd&nBwLzNZ+?q)zsSTHZ4t)H#;F7eY@Tr>d@9mK_Nvo-D4B(8WPE_O_8YAUG} zGaoi>m8LQCVN;V;D`q}y+A2-sC?8GInk(XBHM6Ov5>dl^*i;PBEHWQ9)i{V6=EJ69 zh-NX$N0Te086GC8d=Sk`pf+CIMQu!jke!no4ZhhnWbZwbN;vMK^P)j7uW6m!XkZHO ziOG!yJ*8=#+-P75?}=mGuCkyX3W2y69UKipykp&ZCDkl(7u8IIUS88WxzWHB-V>7> z4SGt`I=Run6y6iZx?N>KKj8Ur^hfQwxQlw221lM--^q;zx9pB!a-+fV&aLm{MuS^+ zM{um$;mW_)EO8grOaq?JH77S3xNLY3xzT_tTyt`xfy;&m#kz6#b{^Lctt-Zh5~z(A zaj^zwQ#Tyu!=~S9>)y2{uo8~A*h#UerV>%ZeArYB(JV3_Hq|(Y8s@{MVu)rj%14u{ zXllB9msqg4s4Quhi4Nl8x7nKZ>k;4U2Tw-COisYv5|i%><+%wsTEd+Rfh!QGpU%3= z^f|5<>y-tkUaVIxXPezt1zn}rza9c(9mA-hKukD{8VWwZR@_4P;!cwNc|Qv?^qtqa z4A`ETU Date: Thu, 12 Sep 2024 16:39:19 +0200 Subject: [PATCH 04/13] add settings files add settings files for V4.0 --- apps/blc/blc.settings.js | 72 ++++++++++++++++++++++++++++++++++++++ apps/blc/blc.settings.json | 7 ++++ 2 files changed, 79 insertions(+) create mode 100644 apps/blc/blc.settings.js create mode 100644 apps/blc/blc.settings.json diff --git a/apps/blc/blc.settings.js b/apps/blc/blc.settings.js new file mode 100644 index 0000000000..33d6246203 --- /dev/null +++ b/apps/blc/blc.settings.js @@ -0,0 +1,72 @@ +// Change settings for BinaryClk + +(function(back){ + + // color array -- don't change order unless change oder in BinaryClk.js + let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; + + var FILE = "BinaryClk.settings.json"; + // Load settings + var settings = Object.assign({ + HourCol: "red", + MinCol: "green", + DayCol: "yellow", + MonCol: "yellow", + RingOn: true, + }, require('Storage').readJSON(FILE, true) || {}); + + function writeSettings(){ + require('Storage').writeJSON(FILE, settings); + } + + // Helper method which uses int-based menu item for set of string values + function stringItems(startvalue, writer, values) { + return{ + value: (startvalue === undefined ? 0 : values.indexOf(startvalue)), + format: v => values[v], + min: 0, + max: values.length - 1, + wrap: true, + step: 1, + onchange: v => { + writer(values[v]); + writeSettings(); + } + }; + } + + // Helper method which breaks string set settings down to local settings object + function stringInSettings(name, values) { + return stringItems(settings[name], v => settings[name] = v, values); + } + + // Show the menu + var mainmenu = { + "" : { + "title" : "BinaryCLK" + }, + "< Back" : () => back(), + 'Color Hour.:': stringInSettings("HourCol", LED_ColorNames), + 'Color Minute:': stringInSettings("MinCol", LED_ColorNames), + 'Color Day': stringInSettings("DayCol", LED_ColorNames), + 'Color Month:': stringInSettings("MonCol", LED_ColorNames), + 'LED ring on/off': { + value: (settings.RingOn !== undefined ? settings.RingOn : true), + onchange: v => { + settings.RingOn = v; + writeSettings(); + } + }, + }; + + // Show submenues + //var submenu1 = { + //"": { + // "title": "Show sub1..." + //}, + //"< Back": () => E.showMenu(mainmenu), + //"ItemName": stringInSettings("settingsVar", ["Yes", "No", "DontCare"]), + //}; + + E.showMenu(mainmenu); +}); diff --git a/apps/blc/blc.settings.json b/apps/blc/blc.settings.json new file mode 100644 index 0000000000..acdb1a78a7 --- /dev/null +++ b/apps/blc/blc.settings.json @@ -0,0 +1,7 @@ +{ + "HourCol": "red", + "MinCol": "green", + "DayCol": "yellow", + "MonCol": "yellow", + "RingOn": true +}; From 5403964960006f27f338275866e9f2f34ec16ed7 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:40:04 +0200 Subject: [PATCH 05/13] Delete apps/blc/screenshot_blc.bmp screenshot is outdated --- apps/blc/screenshot_blc.bmp | Bin 15562 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 apps/blc/screenshot_blc.bmp diff --git a/apps/blc/screenshot_blc.bmp b/apps/blc/screenshot_blc.bmp deleted file mode 100644 index 50b8539bbde952b4b8be2b09aee5ed2691245fc2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 15562 zcmeHNOOD(i5GC4YH6fMxkIm^qs)?j>7BGNsQx`gr-kqJ?W3C9|*>X9me5r8P2y9VzSzsZ+K&*iel zvx&L#=sJiLmg!K4o6#_mAHs# zlKU0HH39+_rS-&2JB4IzN0n4W>+NXb59v8do+=^DWKttSyWp-{%DFp^#NA8)>P9>2 z(S?rea0#h{V;_=eN4!o2TRqJnnmtvJ#m@2%z>i);fzxi8j{|O^9ZmcgRyvkZpv_yz zLgPUg61aqdyd*Fpv}?SyS)vdsQ$naHBDA|leKGP%h@Nh$pdHP^lTt*1bisMsD?da> zjJ7yzY>q+*Pzw>-(UbW{f1X7&fePmwpLhh>z~#a$JWH1n2TDj?lo}D*@#?UUbKfnS zAofF3q;ps+VBv{u?ENny_Cwe+If&S^2=PAO54wJ7&nWLA+9_M8al9VyTpR`uur+75*LgD}yp&h;Xa=d(R9*=J zlej_PIfQn(6J7{TA3oJ^qlnaDw##{qE-bF9!}AF3a$@JOTh_U_q!Ndx+;wjhKg^7d z_NMo-HLmh?nJdwHngUIMrojKDfK8@J;pgvOZj>P*wNQ9ZRLS6`6{3Hb5PQc<4%3^# z7JWIc;-BI*)?v&0PS+|zH+e{YAT!QiV;!!}dotZFyxmLZbV&an*kVa?9VjABo!hs{ zyxoc7%<5a2*PQ5FSl%1rOn!)?`xB{Wne3f;Z#x%byrP3S*wCeGL&^7zNMzrt^SU^z z&g;%abzURqO#))8zR9L&e(;Gh8D9v6CYtPcZ%ynH`thCD=-Az8xwXxhQQE>w=k4Cg EUtq$(RR910 From 19391a0136a0afaf20dc34d0c32cbf3ee54c9408 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:44:52 +0200 Subject: [PATCH 06/13] Update README.md Added description for new functionalities. --- apps/blc/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/apps/blc/README.md b/apps/blc/README.md index a3581cdc74..3d126bcf83 100644 --- a/apps/blc/README.md +++ b/apps/blc/README.md @@ -9,5 +9,9 @@ From top to bottom the watch face shows four rows of leds: * day (yellow leds, top row) * month (yellow leds, bottom row) -As usual, luminous leds represent a logical one, dark leds a logcal '0'. +The colors are default colors and can be changed at the settings page, also, the outer ring can be disabled. + +The rightmost LED represents 1, the second 2, the third 4, the next 8 and so on, i.e. values are the powers of two. + +As usual, luminous leds represent a logical one, and "dark" leds a logcal '0'. Dark means the color of the background. Widgets aren't affected and are shown as normal. From 8bd5f3e56f79bc3a9fb2c5d9b58ff27ec6c35293 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 16:46:40 +0200 Subject: [PATCH 07/13] Update ChangeLog --- apps/blc/ChangeLog | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/blc/ChangeLog b/apps/blc/ChangeLog index 4860c24a6d..6075cacf8d 100644 --- a/apps/blc/ChangeLog +++ b/apps/blc/ChangeLog @@ -1 +1,4 @@ 0.10: New app introduced to the app loader! +0.20: skipped (internal revision) +0.30: skipped (internal revision) +0.40: added functionality for customizing colors From 8336e4e7c52882d494dc05e222bff96f07dee7e1 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:02:07 +0200 Subject: [PATCH 08/13] Update blc.settings.js removed space/tab mix --- apps/blc/blc.settings.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/blc/blc.settings.js b/apps/blc/blc.settings.js index 33d6246203..be10d9e894 100644 --- a/apps/blc/blc.settings.js +++ b/apps/blc/blc.settings.js @@ -62,10 +62,10 @@ // Show submenues //var submenu1 = { //"": { - // "title": "Show sub1..." - //}, - //"< Back": () => E.showMenu(mainmenu), - //"ItemName": stringInSettings("settingsVar", ["Yes", "No", "DontCare"]), + // "title": "Show sub1..." + //}, + //"< Back": () => E.showMenu(mainmenu), + //"ItemName": stringInSettings("settingsVar", ["Yes", "No", "DontCare"]), //}; E.showMenu(mainmenu); From 3bdaad5fa44ca519f6fef95ec3cf3c2afecb57fd Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:02:53 +0200 Subject: [PATCH 09/13] Update blc.js removed unused variables and cleaned tab/space-mix --- apps/blc/blc.js | 35 ++++++----------------------------- 1 file changed, 6 insertions(+), 29 deletions(-) diff --git a/apps/blc/blc.js b/apps/blc/blc.js index b12492a5ee..51663e5026 100644 --- a/apps/blc/blc.js +++ b/apps/blc/blc.js @@ -34,30 +34,7 @@ delete settings; // settings in local var -> no more required } - - function getTemperature() - { - try - { - var temperature = E.getTemperature(); - var formatted = require("locale").temp(temperature).replace(/[^\d-]/g, ''); - return formatted; - } - catch(ex) - { - print(ex); - return "?"; - } - } - - function getSteps() - { - var steps = Bangle.getHealthStatus("day").steps; - return steps; - } - - - let drawTimeout; + let drawTimeout; // actually draw the watch face let draw = function() @@ -65,7 +42,7 @@ // Bangle.js2 -> 176x176 var x_rgt = g.getWidth(); var y_bot = g.getHeight(); - var x_cntr = x_rgt / 2; + //var x_cntr = x_rgt / 2; var y_cntr = y_bot / 18*7; g.reset().clearRect(Bangle.appRect); // clear whole background (w/o widgets) @@ -110,10 +87,10 @@ //////////////////////////////////////// // date-time-array: 4x6 bit - var idx_hour = 0; - var idx_min = 1; - var idx_day = 2; - var idx_mon = 3; + //var idx_hour = 0; + //var idx_min = 1; + //var idx_day = 2; + //var idx_mon = 3; var dt_bit_arr = [[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0]]; var date_time = new Date(); From b5491e1371f03e96e3f066eec358e8ce2315d0fc Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:05:12 +0200 Subject: [PATCH 10/13] Update blc.js --- apps/blc/blc.js | 352 ++++++++++++++++++++++++------------------------ 1 file changed, 176 insertions(+), 176 deletions(-) diff --git a/apps/blc/blc.js b/apps/blc/blc.js index 51663e5026..6015bc548a 100644 --- a/apps/blc/blc.js +++ b/apps/blc/blc.js @@ -3,180 +3,180 @@ { // must be inside our own scope here so that when we are unloaded everything disappears // we also define functions using 'let fn = function() {..}' for the same reason. function decls are global - const SETTINGSFILE = "BinaryClk.settings.json"; - - // variables defined from settings - let HourCol; - let MinCol; - let DayCol; - let MonCol; - let RingOn; - - // color arrays - // !!! don't change order unless change oder in BinaryClk.settings.js !!! - // !!! order must correspond to each other between arrays !!! - let LED_Colors = ["#FFF", "#F00", "#0F0", "#00F", "#FF0", "#F0F", "#0FF", "#000"]; - let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; - - // load settings - let loadSettings = function() - { - function def (value, def) {return value !== undefined ? value : def;} - - var settings = require('Storage').readJSON(SETTINGSFILE, true) || {}; - // get name from setting, find index of name and assign corresponding color code by index - HourCol = LED_Colors[LED_ColorNames.indexOf(def(settings.HourCol, "red"))]; - MinCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MinCol, "green"))]; - DayCol = LED_Colors[LED_ColorNames.indexOf(def(settings.DayCol, "yellow"))]; - MonCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MonCol, "yellow"))]; - RingOn = def(settings.RingOn, true); - - delete settings; // settings in local var -> no more required - } - - let drawTimeout; - - // actually draw the watch face - let draw = function() - { - // Bangle.js2 -> 176x176 - var x_rgt = g.getWidth(); - var y_bot = g.getHeight(); - //var x_cntr = x_rgt / 2; - var y_cntr = y_bot / 18*7; - g.reset().clearRect(Bangle.appRect); // clear whole background (w/o widgets) - - var white = "#FFF"; - var black = "#000"; - var bord_col = white; - var col_off = black; - - var col = new Array(HourCol, MinCol, DayCol, MonCol); // each #rgb - if (g.theme.dark) - { - bord_col = white; - col_off = black; - } - else - { - bord_col = black; - col_off = white; - } - - let pwr2 = [1, 2, 4, 8, 16, 32]; // array with powers of 2, because poweroperator '**' doesnt work - // maybe also faster - - - var no_lines = 4; // 4 rows: hour (hr), minute (min), day (day), month (mon) - var no_hour = 5; - var no_min = 6; - var no_day = 5; - var no_mon = 4; - - // arrays: [hr, min, day, mon] - let msbits = [no_hour-1, no_min-1, no_day-1, no_mon-1]; // MSB = No bits - 1 - let rad = [13, 13, 9, 9]; // radiuses for each row - var x_dist = 29; - let y_dist = [0, 35, 75, 100]; // y-position from y_centr for each row from top - // don't calc. automatic as for x, because of different spaces - var x_offs_rgt = 15; // offset from right border (layout) - var y_offs_cntr = 25; // vertical offset from center - - //////////////////////////////////////// - // compute bit-pattern from time/date and draw leds - //////////////////////////////////////// - - // date-time-array: 4x6 bit - //var idx_hour = 0; - //var idx_min = 1; - //var idx_day = 2; - //var idx_mon = 3; - var dt_bit_arr = [[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0]]; - - var date_time = new Date(); - var hour = date_time.getHours(); // 0..23 - var min = date_time.getMinutes(); // 0..59 - var day = date_time.getDate(); // 1..31 - var mon = date_time.getMonth() + 1; // GetMonth() -> 0..11 - - let dt_array = [hour, min, day, mon]; - - var line_cnt = 0; - var cnt = 0; - var bit_cnt = 0; - - while (line_cnt < no_lines) - { - - //////////////////////////////////////// - // compute bit-pattern - bit_cnt = msbits[line_cnt]; - - while (bit_cnt >= 0) - { - if (dt_array[line_cnt] >= pwr2[bit_cnt]) - { - dt_array[line_cnt] -= pwr2[bit_cnt]; - dt_bit_arr[line_cnt][bit_cnt] = 1; - } - else - { - dt_bit_arr[line_cnt][bit_cnt] = 0; - } - bit_cnt--; - } - - //////////////////////////////////////// - // draw leds (and border, if enabled) - cnt = 0; - - while (cnt <= msbits[line_cnt]) - { - if (RingOn) // draw outer ring, if enabled - { - g.setColor(bord_col); - g.drawCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]); - } - if (dt_bit_arr[line_cnt][cnt] == 1) - { - g.setColor(col[line_cnt]); - } - else - { - g.setColor(col_off); - } - g.fillCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]-1); - cnt++; - } - line_cnt++; - } - - // queue next draw - if (drawTimeout) clearTimeout(drawTimeout); - drawTimeout = setTimeout(function() - { - drawTimeout = undefined; - draw(); - }, 60000 - (Date.now() % 60000)); - } - - - // Init the settings of the app - loadSettings(); - - // Show launcher when middle button pressed - Bangle.setUI( - { - mode : "clock", - remove : function() - { - // Called to unload all of the clock app - if (drawTimeout) clearTimeout(drawTimeout); - drawTimeout = undefined; - } - }); - // Load widgets - Bangle.loadWidgets(); - draw(); - setTimeout(Bangle.drawWidgets,0); + const SETTINGSFILE = "BinaryClk.settings.json"; + + // variables defined from settings + let HourCol; + let MinCol; + let DayCol; + let MonCol; + let RingOn; + + // color arrays + // !!! don't change order unless change oder in BinaryClk.settings.js !!! + // !!! order must correspond to each other between arrays !!! + let LED_Colors = ["#FFF", "#F00", "#0F0", "#00F", "#FF0", "#F0F", "#0FF", "#000"]; + let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; + + // load settings + let loadSettings = function() + { + function def (value, def) {return value !== undefined ? value : def;} + + var settings = require('Storage').readJSON(SETTINGSFILE, true) || {}; + // get name from setting, find index of name and assign corresponding color code by index + HourCol = LED_Colors[LED_ColorNames.indexOf(def(settings.HourCol, "red"))]; + MinCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MinCol, "green"))]; + DayCol = LED_Colors[LED_ColorNames.indexOf(def(settings.DayCol, "yellow"))]; + MonCol = LED_Colors[LED_ColorNames.indexOf(def(settings.MonCol, "yellow"))]; + RingOn = def(settings.RingOn, true); + + delete settings; // settings in local var -> no more required + } + + let drawTimeout; + + // actually draw the watch face + let draw = function() + { + // Bangle.js2 -> 176x176 + var x_rgt = g.getWidth(); + var y_bot = g.getHeight(); + //var x_cntr = x_rgt / 2; + var y_cntr = y_bot / 18*7; + g.reset().clearRect(Bangle.appRect); // clear whole background (w/o widgets) + + var white = "#FFF"; + var black = "#000"; + var bord_col = white; + var col_off = black; + + var col = new Array(HourCol, MinCol, DayCol, MonCol); // each #rgb + if (g.theme.dark) + { + bord_col = white; + col_off = black; + } + else + { + bord_col = black; + col_off = white; + } + + let pwr2 = [1, 2, 4, 8, 16, 32]; // array with powers of 2, because poweroperator '**' doesnt work + // maybe also faster + + + var no_lines = 4; // 4 rows: hour (hr), minute (min), day (day), month (mon) + var no_hour = 5; + var no_min = 6; + var no_day = 5; + var no_mon = 4; + + // arrays: [hr, min, day, mon] + let msbits = [no_hour-1, no_min-1, no_day-1, no_mon-1]; // MSB = No bits - 1 + let rad = [13, 13, 9, 9]; // radiuses for each row + var x_dist = 29; + let y_dist = [0, 35, 75, 100]; // y-position from y_centr for each row from top + // don't calc. automatic as for x, because of different spaces + var x_offs_rgt = 15; // offset from right border (layout) + var y_offs_cntr = 25; // vertical offset from center + + //////////////////////////////////////// + // compute bit-pattern from time/date and draw leds + //////////////////////////////////////// + + // date-time-array: 4x6 bit + //var idx_hour = 0; + //var idx_min = 1; + //var idx_day = 2; + //var idx_mon = 3; + var dt_bit_arr = [[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0]]; + + var date_time = new Date(); + var hour = date_time.getHours(); // 0..23 + var min = date_time.getMinutes(); // 0..59 + var day = date_time.getDate(); // 1..31 + var mon = date_time.getMonth() + 1; // GetMonth() -> 0..11 + + let dt_array = [hour, min, day, mon]; + + var line_cnt = 0; + var cnt = 0; + var bit_cnt = 0; + + while (line_cnt < no_lines) + { + + //////////////////////////////////////// + // compute bit-pattern + bit_cnt = msbits[line_cnt]; + + while (bit_cnt >= 0) + { + if (dt_array[line_cnt] >= pwr2[bit_cnt]) + { + dt_array[line_cnt] -= pwr2[bit_cnt]; + dt_bit_arr[line_cnt][bit_cnt] = 1; + } + else + { + dt_bit_arr[line_cnt][bit_cnt] = 0; + } + bit_cnt--; + } + + //////////////////////////////////////// + // draw leds (and border, if enabled) + cnt = 0; + + while (cnt <= msbits[line_cnt]) + { + if (RingOn) // draw outer ring, if enabled + { + g.setColor(bord_col); + g.drawCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]); + } + if (dt_bit_arr[line_cnt][cnt] == 1) + { + g.setColor(col[line_cnt]); + } + else + { + g.setColor(col_off); + } + g.fillCircle(x_rgt-x_offs_rgt-cnt*x_dist, y_cntr-y_offs_cntr+y_dist[line_cnt], rad[line_cnt]-1); + cnt++; + } + line_cnt++; + } + + // queue next draw + if (drawTimeout) clearTimeout(drawTimeout); + drawTimeout = setTimeout(function() + { + drawTimeout = undefined; + draw(); + }, 60000 - (Date.now() % 60000)); + } + + + // Init the settings of the app + loadSettings(); + + // Show launcher when middle button pressed + Bangle.setUI( + { + mode : "clock", + remove : function() + { + // Called to unload all of the clock app + if (drawTimeout) clearTimeout(drawTimeout); + drawTimeout = undefined; + } + }); + // Load widgets + Bangle.loadWidgets(); + draw(); + setTimeout(Bangle.drawWidgets,0); } From 15c2ddb3c99fee0e2ee3742451d8add4b90aaed4 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:05:31 +0200 Subject: [PATCH 11/13] Update blc.settings.js --- apps/blc/blc.settings.js | 126 +++++++++++++++++++-------------------- 1 file changed, 63 insertions(+), 63 deletions(-) diff --git a/apps/blc/blc.settings.js b/apps/blc/blc.settings.js index be10d9e894..270ece0719 100644 --- a/apps/blc/blc.settings.js +++ b/apps/blc/blc.settings.js @@ -1,72 +1,72 @@ // Change settings for BinaryClk (function(back){ - - // color array -- don't change order unless change oder in BinaryClk.js - let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; + + // color array -- don't change order unless change oder in BinaryClk.js + let LED_ColorNames = ["white", "red", "green", "blue", "yellow", "magenta", "cyan", "black"]; - var FILE = "BinaryClk.settings.json"; - // Load settings - var settings = Object.assign({ - HourCol: "red", - MinCol: "green", - DayCol: "yellow", - MonCol: "yellow", - RingOn: true, - }, require('Storage').readJSON(FILE, true) || {}); + var FILE = "BinaryClk.settings.json"; + // Load settings + var settings = Object.assign({ + HourCol: "red", + MinCol: "green", + DayCol: "yellow", + MonCol: "yellow", + RingOn: true, + }, require('Storage').readJSON(FILE, true) || {}); - function writeSettings(){ - require('Storage').writeJSON(FILE, settings); - } + function writeSettings(){ + require('Storage').writeJSON(FILE, settings); + } - // Helper method which uses int-based menu item for set of string values - function stringItems(startvalue, writer, values) { - return{ - value: (startvalue === undefined ? 0 : values.indexOf(startvalue)), - format: v => values[v], - min: 0, - max: values.length - 1, - wrap: true, - step: 1, - onchange: v => { - writer(values[v]); - writeSettings(); - } - }; - } + // Helper method which uses int-based menu item for set of string values + function stringItems(startvalue, writer, values) { + return{ + value: (startvalue === undefined ? 0 : values.indexOf(startvalue)), + format: v => values[v], + min: 0, + max: values.length - 1, + wrap: true, + step: 1, + onchange: v => { + writer(values[v]); + writeSettings(); + } + }; + } - // Helper method which breaks string set settings down to local settings object - function stringInSettings(name, values) { - return stringItems(settings[name], v => settings[name] = v, values); - } + // Helper method which breaks string set settings down to local settings object + function stringInSettings(name, values) { + return stringItems(settings[name], v => settings[name] = v, values); + } - // Show the menu - var mainmenu = { - "" : { - "title" : "BinaryCLK" - }, - "< Back" : () => back(), - 'Color Hour.:': stringInSettings("HourCol", LED_ColorNames), - 'Color Minute:': stringInSettings("MinCol", LED_ColorNames), - 'Color Day': stringInSettings("DayCol", LED_ColorNames), - 'Color Month:': stringInSettings("MonCol", LED_ColorNames), - 'LED ring on/off': { - value: (settings.RingOn !== undefined ? settings.RingOn : true), - onchange: v => { - settings.RingOn = v; - writeSettings(); - } - }, - }; - - // Show submenues - //var submenu1 = { - //"": { - // "title": "Show sub1..." - //}, - //"< Back": () => E.showMenu(mainmenu), - //"ItemName": stringInSettings("settingsVar", ["Yes", "No", "DontCare"]), - //}; - - E.showMenu(mainmenu); + // Show the menu + var mainmenu = { + "" : { + "title" : "BinaryCLK" + }, + "< Back" : () => back(), + 'Color Hour.:': stringInSettings("HourCol", LED_ColorNames), + 'Color Minute:': stringInSettings("MinCol", LED_ColorNames), + 'Color Day': stringInSettings("DayCol", LED_ColorNames), + 'Color Month:': stringInSettings("MonCol", LED_ColorNames), + 'LED ring on/off': { + value: (settings.RingOn !== undefined ? settings.RingOn : true), + onchange: v => { + settings.RingOn = v; + writeSettings(); + } + }, + }; + + // Show submenues + //var submenu1 = { + //"": { + // "title": "Show sub1..." + //}, + //"< Back": () => E.showMenu(mainmenu), + //"ItemName": stringInSettings("settingsVar", ["Yes", "No", "DontCare"]), + //}; + + E.showMenu(mainmenu); }); From b7b23b83f1adb4b26c4bd49352f6a298dfb8ce16 Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Thu, 12 Sep 2024 18:08:26 +0200 Subject: [PATCH 12/13] Update blc.settings.js --- apps/blc/blc.settings.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/blc/blc.settings.js b/apps/blc/blc.settings.js index 270ece0719..00e9c284bb 100644 --- a/apps/blc/blc.settings.js +++ b/apps/blc/blc.settings.js @@ -43,7 +43,7 @@ // Show the menu var mainmenu = { "" : { - "title" : "BinaryCLK" + "title" : "BinaryCLK" }, "< Back" : () => back(), 'Color Hour.:': stringInSettings("HourCol", LED_ColorNames), From b4f7f6f61787d1d3ffc6fc3f116adcf32d9c889b Mon Sep 17 00:00:00 2001 From: aemkai <87898467+aemkai@users.noreply.github.com> Date: Wed, 25 Sep 2024 19:58:31 +0200 Subject: [PATCH 13/13] Update apps/blc/blc.settings.json Yes, i found it in a tutorial this way, but i'm fairly new to JS Co-authored-by: Rob Pilling --- apps/blc/blc.settings.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/blc/blc.settings.json b/apps/blc/blc.settings.json index acdb1a78a7..37abfc700f 100644 --- a/apps/blc/blc.settings.json +++ b/apps/blc/blc.settings.json @@ -4,4 +4,4 @@ "DayCol": "yellow", "MonCol": "yellow", "RingOn": true -}; +}