mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-17 10:00:46 -04:00
modularize code, add dummy version of roverd
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
registerModule('helpers/formatters', (require, exports) => {
|
||||
function formatHex(base64) {
|
||||
if (!base64) return '';
|
||||
const buffer = Uint8Array.from(atob(base64), (c) => c.charCodeAt(0));
|
||||
return Array.from(buffer)
|
||||
.map((b) => b.toString(16).padStart(2, '0'))
|
||||
.join(' ');
|
||||
}
|
||||
|
||||
exports.formatHex = formatHex;
|
||||
});
|
||||
Reference in New Issue
Block a user