Help for this page

Select Code to Download


  1. or download this
    sub uint16_to_bytes {
       my ($int) = @_;
    ...
       my ($lo, $hi) = @_;
       return unpack('s', pack('S', unpack('v', pack('C2', $lo, $hi))));
    }