matlab double window and updated packet_tx