in reply to Slew or error messages

You're using alot of uninitialized variables there. And one bareword. I'd use strict for good measure. I don't know what gqcam does, are you trying to process the output of it, or interact with it? If the former, save the output to a variable:
my @array = `gqcam...`;
If the latter, then use Expect. Also '$boink' never changes; did you want an infinite loop?

And when putting things between code tags, you don't have to escape '&' as '&'. I'm assuming that you don't really have '&' there.

Replies are listed 'Best First'.
Re: Re: Slew or error messages
by peschkaj (Pilgrim) on Aug 08, 2001 at 00:36 UTC

    I intentionally left the code general so that people could try it out themselves. the & came in from the HTML thingamajig, somehow.

    gqcam is a webcam program. I merely want to launch it in the background and have it update the cam every $howevermany seconds. It saves a file that is uploaded to the ftp server by this snippet of code.

    As for $boink, I would like for the loop to be infinite until i close that terminal window or kill the process.

      You might have some contention issues if you start your upload while gqcam is rewriting the file. You might want to rename the file first, wait a bit, then upload the renamed file. And go ahead and use system to start gqcam: system('gqcam &') and die "Error starting gqcam";

      For an infinite loop, all you need is a bare block:

      LOOP: { #do stuff redo LOOP; }

      What sort of errors does gqcam 'spew'?? Are they significant, or can you just redirect them to /dev/null and ignore them?

        gqcam barfs out some variable errors or something, i forget exactly what, but it is my belief that gqcam (through some programming fault of mine) is getting the ftp commands as input and is thoroughly confused by them. While it's barfing out these errors, I am also able to see the gqcam variables zipping about on their little sliders.