/[RFID]/cpr-m02.pl
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /cpr-m02.pl

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 88 by dpavlin, Fri Jul 16 13:33:10 2010 UTC revision 89 by dpavlin, Fri Jul 16 13:50:52 2010 UTC
# Line 339  sub cpr_read { Line 339  sub cpr_read {
339          my $hex_uid = as_hex($uid);          my $hex_uid = as_hex($uid);
340    
341          cpr( "FF  B0 23  01  $hex_uid 00 04", "Read Multiple Blocks $hex_uid" );          cpr( "FF  B0 23  01  $hex_uid 00 04", "Read Multiple Blocks $hex_uid" );
342  #       cpr( "FF  B0 2B  01  $hex_uid", "Get System Information $hex_uid" );          cpr( "FF  B0 2B  01  $hex_uid", "Get System Information $hex_uid", sub {
343                    my $data = shift;
344    
345                    warn "# data ",as_hex($data);
346    
347                    my $DSFID    = substr($data,5-2,1);
348                    my $UID      = substr($data,6-2,8);
349                    my $AFI      = substr($data,14-2,1);
350                    my $MEM_SIZE = substr($data,15-2,2);
351                    my $IC_REF   = substr($data,17-2,1);
352    
353                    warn "# split ",as_hex( $DSFID, $UID, $AFI, $MEM_SIZE, $IC_REF );
354    
355            });
356  }  }
357    
358    

Legend:
Removed from v.88  
changed lines
  Added in v.89

  ViewVC Help
Powered by ViewVC 1.1.26