-=comment
- for my $controller (1..6) {
- my $byte = $data[$controller];
- next if defined $controllers[$controller-1]
- && $controllers[$controller-1] == $byte;
- $controllers[$controller-1] = $byte;
-
- my $progressbar = $builder->get_object(
- 'progressbar_controller'.$controller);
- if ($byte == 0xaa) {
- $progressbar->set_text('inactive');
- $progressbar->set_fraction(0);
- next;
- }
- my $light = !($byte & 0x20);
- my $backbutton = !($byte & 0x10);
- my $speed = $byte & 0x0f;
-
- my $text = ($backbutton ? '+' : '') . $speed;
- $progressbar->set_text($text);
- $progressbar->set_fraction($speed / 12);
+ my @log_data;
+
+ for my $car (0..5) {
+ my $byte = $bytes[$car];
+
+ if ($byte == 0xAA) {
+ $self->track->car($car)->set_throttle(undef, undef,
+ $self->{last_read_time});
+ push @log_data, 'undef', '0';
+ next;