>A second is quite a bit of time to wait in a program, so you may want to
use
>Time::HiRes and usleep for a few milliseconds.

Another option is to use:
select( undef, undef, undef, x )

where x can be fractions of a second:
select( undef, undef, undef, 0.26 )
select( undef, undef, undef, 0.76 )
select( undef, undef, undef, 5.49 )



-----------------------------------------
Craig Moynes
Internship Student
netCC Development
IBM Global Services, Canada
Tel: (905) 316-3486
[EMAIL PROTECTED]



                                                                                       
                            
                    Michael Fowler                                                     
                            
                    <michael@shoeb       To:     Paul Burkett 
<[EMAIL PROTECTED]>                           
                    ox.net>              cc:     [EMAIL PROTECTED]                    
                            
                                         Subject:     Re: I discovered the problem 
BUT...                          
                    06/21/01 04:12                                                     
                            
                    PM                                                                 
                            
                    Please respond                                                     
                            
                    to Michael                                                         
                            
                    Fowler                                                             
                            
                                                                                       
                            
                                                                                       
                            



On Thu, Jun 21, 2001 at 12:45:33PM -0700, Paul Burkett wrote:
> No, the default setting is 9600 I did a test with it
> by making a loop on the serial devices, it seems that
> the camera can only take characters at a delayed input
> rate, that's why it worked in 'tip' is because I typed
> it character-by-character. I did an 'echo' command in
> solaris and it did not work with one line but if I
> type it:
>
> echo "@" >>/dev/term/a [enter]
> echo "2" >>/dev/term/a [enter]
> echo "2" >>/dev/term/a [enter]
>
> it worked!

How odd.  You could try sleeping between prints:

    foreach my $c (split //, $string) {
        print SERIAL $c;
        sleep(1);
    }

A second is quite a bit of time to wait in a program, so you may want to
use
Time::HiRes and usleep for a few milliseconds.


Michael
--
Administrator                      www.shoebox.net
Programmer, System Administrator   www.gallanttech.com
--




Reply via email to