Skip to content

Commit

Permalink
Update logfs header and codal-core
Browse files Browse the repository at this point in the history
  • Loading branch information
Amerlander committed Jun 24, 2024
1 parent f2d8c00 commit 498c64c
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 58 deletions.
6 changes: 3 additions & 3 deletions resources/logfs/basic-header.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
let n = null;
let csv = "";
let tag = d.createElement.bind(d);
let x = " Calliope mini ";
let x = "Calliope mini";
// Allow external JS to override these actions if we managed to load it.
// This script block is first so external JS can override individual functions.
w.dl = {
Expand All @@ -55,11 +55,11 @@
},
update: alert.bind(
n,
`Verbinde den${x}neu und warte.`
`Verbinde den ${x} neu und warte.`
),
clear: alert.bind(
n,
`Log wird gelöscht, wenn du den${x}neu flashst.`
`Log wird gelöscht, wenn du den ${x} neu flashst.`
),
load: () => {
// Find the CSV text in the file system
Expand Down
11 changes: 6 additions & 5 deletions resources/logfs/default-header.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,14 @@
let n = null;
let csv = "";
let tag = d.createElement.bind(d);
let x = "Calliope mini";
// Allow external JS to override these actions if we managed to load it.
// This script block is first so external JS can override individual functions.
w.dl = {
mode: "default",
download: function () {
let a = tag("a");
a.download = "microbit.csv";
a.download = x+".csv";
a.href = URL.createObjectURL(new Blob([csv], { type: "text/csv" }));
a.click();
a.remove();
Expand All @@ -55,11 +56,11 @@
},
update: alert.bind(
n,
"Unplug your micro:bit, then plug it back in and wait"
`Unplug your ${x}, then plug it back in and wait`
),
clear: alert.bind(
n,
"The log is cleared when you reflash your micro:bit"
`The log is cleared when you reflash your ${x}`
),
load: function () {
// Find the CSV text in the file system
Expand Down Expand Up @@ -128,11 +129,11 @@
</script>
<base href="https://data.microbit.org" />
<script src="v3/dl.js"></script>
<title>micro:bit data log</title>
<title>Calliope mini data log</title>
</head>
<body onload="dl.load()">
<div id="w">
<h1>micro:bit data log</h1>
<h1>Calliope mini data log</h1>
<div class="bb">
<button onclick="dl.download()">Download</button>
<button onclick="dl.copy()">Copy</button>
Expand Down
4 changes: 2 additions & 2 deletions resources/logfs/nextgen-header.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
</script>
<base href="https://data.microbit.org" />
<script onerror="window.dl.handleBootstrapError()" src="v3/dl.js"></script>
<title>micro:bit data log</title>
<title>Calliope mini data log</title>
</head>
<body>
<div id="w">
<h1>micro:bit data log</h1>
<h1>Calliope mini data log</h1>
<p id="v">Loading&hellip;</p>
64 changes: 20 additions & 44 deletions resources/logfs/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions source/MicroBitLog.cpp

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion target-locked.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"generate_hex": true,
"libraries": [
{
"branch": "da93588bc0b445a426252abd73158deafad293e1",
"branch": "c55f6ae7ea48b63738bf015fd50bd001cf3fd5fd",
"name": "codal-core",
"type": "git",
"url": "https://github.com/calliope-edu/codal-core"
Expand Down

0 comments on commit 498c64c

Please sign in to comment.