wrap command into ESC CR before sending it
authorDobrica Pavlinusic <dpavlin@rot13.org>
Mon, 16 Aug 2010 21:52:54 +0000 (23:52 +0200)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Mon, 16 Aug 2010 21:52:54 +0000 (23:52 +0200)
lib/Printer/EVOLIS/Parallel.pm

index 2ccda9b..61a756f 100644 (file)
@@ -35,6 +35,12 @@ sub new {
 
 sub command {
        my ( $self, $send ) = @_;
+       $send = "\e$send\r" unless $send =~ m/^\e/;
+       $self->send( $send );
+}
+
+sub send {
+       my ( $self, $send ) = @_;
 
        my $port = $self->{port};
        die "no port $port" unless -e $port;