regex to remove strange character from text file

Each line of text in log file I get from a device has a small rectangle at the begining, how do I get rid of it? Here is what it looks like, just imagine the zero's are small rectangles:

0SeqNum: 57
0Display: 1
0Point: 9
0CurrentState: Alarm

I have chomped, choped, tried to strip out with regexs, and have had no success.
omcrAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ozoCommented:
what do you see if you do
while( <> ){
  s/([^\n -z])/sprintf'\x%02x',ord $1/eg;
  print;
}
omcrAuthor Commented:
That gave me this:
\x0dSeqNum: 81\x0d
\x0dDisplay: 1\x0d
\x0dPoint: 9\x0d
\x0dCurrentState: Alarm\x0d
ozoCommented:
"\0xd" is a carriage return, was the log file generated in DOS?
perl -i.bak -pe 's/\xd//g' logfile
Introduction to Web Design

Develop a strong foundation and understanding of web design by learning HTML, CSS, and additional tools to help you develop your own website.

omcrAuthor Commented:
generated in unix.
Can you put "perl -i.bak -pe 's/\xd//g' logfile" into a file format instead of command line?
ozoCommented:
#!/usr/bin/perl
{local @ARGV=<*.log>;
 local $I^='';
 while( <> ){
    s/\xd//g;
    print;
 }
}

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Kim RyanIT ConsultantCommented:
Can you dump the file so we can identify the strange character?
od -s logfile
od -x logfile

If you are on unix, thr tr utility may be simpler. The first example removes all control characters. The second, all characters with octal value of 015

cat logfile | tr -d '[:control:]' > new_logfile
cat logfile | tr -d '\015' > new_logfile
omcrAuthor Commented:
That did it. Thanks.
omcrAuthor Commented:
Did not see your post before I commented last time teraplane, but ozo's suggestion cleaned it up, and my scripts are now working. Thanks.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Perl

From novice to tech pro — start learning today.