Created
April 7, 2020 15:23
-
-
Save dvv/6da5d5fbd5a7242b7e5f697977cbaa29 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const from_Myhome_to_NEC = (x) => { | |
const s = Number(x).toString(2).split("").reverse(); | |
while (s.length < 32) s.push("0"); | |
return parseInt(s.join(""), 2).toString(16); | |
} | |
/* | |
0xdb24f708 => 10ef24db | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment