(buffer)
| 1729 | } |
| 1730 | |
| 1731 | function buffer2hexlist(buffer) { |
| 1732 | let byteArray = new Uint8Array(buffer); |
| 1733 | let hexParts = []; |
| 1734 | for (let i = 0; i < byteArray.length; i++) { |
| 1735 | let hex = byteArray[i].toString(16); |
| 1736 | let padded = ("00" + hex).slice(-2); |
| 1737 | hexParts.push("0x" + padded); |
| 1738 | } |
| 1739 | return hexParts.join(", "); |
| 1740 | } |
| 1741 | |
| 1742 | function toPaddedHex(value) { |
| 1743 | return "0x" + ("00" + value.toString(16)).slice(-2); |
no test coverage detected