On 09/21/2006 12:06 AM, Welly Hartanto wrote:
Thank you for all your suggestions.
It's solved by using :
for ($i=0; $i < (length($gotit)); $i++) {
my $c = substr($gotit, $i, 1);
$str1 = sprintf("%01x", ((ord($c) & 0xf0) >> 4) & 0x0f);
$str2 = sprintf("%01x", ord($c) & 0x0f);
prin
Dave Carrigan wrote:
On Tuesday 19 September 2006 23:29, Welly Hartanto wrote:
for ($i=0; $i < (length($gotit)); $i++) {
my $c = substr($gotit, $i, 1);
$c1 = $c & 0xF0; #get the high nibble
$c1 = $c1 >> 4; #
$c1 =
On 09/20/2006 01:29 AM, Welly Hartanto wrote:
I've managed to create an application for reading some bytes of data
from an id card reader connected into a serial port.
But it's under Win$ ...
So, now I've been trying for at least capturing the data then convert
it the way I want.
The convertion i
On 09/20/2006 01:29 AM, Welly Hartanto wrote:
I've managed to create an application for reading some bytes of data
from an id card reader connected into a serial port.
But it's under Win$ ...
So, now I've been trying for at least capturing the data then convert
it the way I want.
The convertion i
On Wed, Sep 20, 2006 at 01:29:44PM +0700, Welly Hartanto wrote:
> #Loop through the whole data
> for ($i=0; $i < (length($gotit)); $i++) {
> my $c = substr($gotit, $i, 1);
> $c1 = $c & 0xF0; #get the high nibble
> $c1 = $c1 >> 4; #
>
On Tuesday 19 September 2006 23:29, Welly Hartanto wrote:
> for ($i=0; $i < (length($gotit)); $i++) {
> my $c = substr($gotit, $i, 1);
> $c1 = $c & 0xF0; #get the high nibble
> $c1 = $c1 >> 4; #
> $c1 = $c1 & 0x0F;
On 9/20/06, Welly Hartanto <[EMAIL PROTECTED]> wrote:
I've managed to create an application for reading some bytes of data
from an id card reader connected into a serial port.
But it's under Win$ ...
So, now I've been trying for at least capturing the data then convert
it the way I want.
The conv
I've managed to create an application for reading some bytes of data
from an id card reader connected into a serial port.
But it's under Win$ ...
So, now I've been trying for at least capturing the data then convert
it the way I want.
The convertion is called "byte to hex string" convertion.
Below
8 matches
Mail list logo