in reply to CRC and Serial Port

The ever cryptic pack() and unpack() functions will be perfect for this sort of binary data munging
my ($stx,$status1,$status2,$data1,$data2,$etx,$crc) = unpack("CCCa5a5CC", $data_received);
My example may not fit your data structure exactly (I make no pretense to my pack()ing skills ;o), but I think it's something along the lines of what you want.
HTH

broquaint

Update: as Albannach kindly pointed out the template should be a5 and not 5a.