On 7/13/07, Mr. Shawn H. Corey <[EMAIL PROTECTED]> wrote:
CM Analyst wrote:
> Hi,
> In the following script, I am inserting a time stamp.
> The problem is that the time stamp ($sec) is not
> incrementing.
>
> What am I doing wrong?
>
>
> open (PORT, "+>COM1") || die "Can't Open Port\n";
> open
CM Analyst schreef:
> my ($sec, $min, $hour,
> $mday, $mon, $year,
> $wday, $yday, $isdst) = localtime();
You don't have to allocate variables for the values that you don't need,
so in your case this might be sufficient:
my ($sec, $min, $hour) = localtime;
If you need
Dear All,
The following works for me.
#
use strict;
use warnings;
use Win32::SerialPort;
use IO::Select;
use IO::File;
use IO::Handle;
use Time::Local;
# Serial Settings
open (PORT, "+>COM1") || die "Can't Open Port\n";
open (LOG, "> c:\\temp\\logdata.txt") || die "Can't
Open File
CM Analyst wrote:
Hi,
In the following script, I am inserting a time stamp.
The problem is that the time stamp ($sec) is not
incrementing.
What am I doing wrong?
open (PORT, "+>COM1") || die "Can't Open Port\n";
open (LOG, "> c:\\temp\\logdata.txt") || die "Can't
Open File\n";
while ( ) {
#p
On 7/13/07, CM Analyst <[EMAIL PROTECTED]> wrote:
snip
What am I doing wrong?
snip
As far as I can see from the code you posted $hour, $min, and $sec
shouldn't even have values. Scalars don't magically change value
(unless they are tied, but that is magic), so you must put something
inside the
Hi,
In the following script, I am inserting a time stamp.
The problem is that the time stamp ($sec) is not
incrementing.
What am I doing wrong?
open (PORT, "+>COM1") || die "Can't Open Port\n";
open (LOG, "> c:\\temp\\logdata.txt") || die "Can't
Open File\n";
while ( ) {
#print $_;
#sleep 1;
#