Node.js examples for Number:Binary
Outputs uint32 as a comma-separated list of bytes
function getU8str(u) { var str = "", s; for(var i=0; i < 4; i++, u >>>= 8) { s = (u & 0xff).toString(16); if (s.length < 2) s = "0" + s; str += s + (i < 3 ? ",":""); }/*w ww .jav a2 s . c om*/ return str; }