#! /usr/bin/perl $data_file="1.flv"; open (FILE, $data_file) or die ("Could not open file!"); my $len=0; while($len!=7){ read (FILE, $buffer, 1); print "Char Format: "; print "$buffer "; print "Hex Format: "; printf ("%lX ", $buffer); print " Test Print Format"; $test=255; print " ".$test." "; printf ("%lX", $test); print "\n"; $len++; } print "\n=====End of Script====="; close(FILE);