Unoffical empeg BBS

Quick Links: Empeg FAQ | RioCar.Org | Hijack | BigDisk Builder | jEmplode | emphatic
Repairs: Repairs

Topic Options
#249910 - 19/02/2005 14:05 Debug/Reverse Engineer Serial Port & VB Program?
hybrid8
carpal tunnel

Registered: 12/11/2001
Posts: 7738
Loc: Toronto, CANADA
This definitely belongs in this forum because it's not empeg related, but would someone with Mod access be kind enough to add linking messages to the Programming and Technical forums? It looks like there are quite a number of people that don't pop into OffTopic who i think may have a suggestion or two.

Anyway, I have a small serial port IR receiver and a VB program (Windows XP - came with the serial hardware) that listens to it and displays some info about what it reads from the HW. I would like to snoop all the signals on that COM port while the software is working in hopes of finding out exactly how to initialize the hardware and what it spits back when functioning.

Basically the software is limited in what it presents in its UI and I'd like to do something on my own - it'll also be the first steps in making this thing work on the Mac (which will further require a USB/serial adapter).

I've seen a lot of serial port projects being talked about here over the years and I know plenty of people have quite a bit of experience with this sort of thing. I have a full installation of Visual Studio .NET at work if any of the included tools will be relevant. Other than that I'll simply have to get whatever other tools are recommended.

Thanks.
Bruno
_________________________
Bruno
Twisted Melon : Fine Mac OS Software

Top
#249911 - 19/02/2005 14:16 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: hybrid8]
tfabris
carpal tunnel

Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
Quote:
I would like to snoop all the signals on that COM port while the software is working in hopes of finding out exactly how to initialize the hardware and what it spits back when functioning.

This is precisely what I did to fix most of the port initialization bugs in the win32 version of UPLOAD.EXE for my logo editor. The serial port snooper program I used for that is now one of my "must have" utilities.

The utility you want is portmon.

Ah, good old sysinternals.
_________________________
Tony Fabris

Top
#249912 - 19/02/2005 14:54 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: tfabris]
sn00p
addict

Registered: 24/07/2002
Posts: 618
Loc: South London
Quote:
Quote:
I would like to snoop all the signals on that COM port while the software is working in hopes of finding out exactly how to initialize the hardware and what it spits back when functioning.

This is precisely what I did to fix most of the port initialization bugs in the win32 version of UPLOAD.EXE for my logo editor. The serial port snooper program I used for that is now one of my "must have" utilities.

The utility you want is portmon.

Ah, good old sysinternals.


Yeah, portmon is the beast! Used it to figure out the protocol that our autoloading cd duplicator uses at work....

There was no way that I was going to sit there and rip all my cd's to mp3 by hand, so I figured I may as well get some (unintended) use from the cd duplicator! Worked a treat.

Top
#249913 - 19/02/2005 15:12 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: tfabris]
hybrid8
carpal tunnel

Registered: 12/11/2001
Posts: 7738
Loc: Toronto, CANADA
Looks like just the program. I suppose with all the serial details it won't evenbe worth taking apart or otherwise debugging the (VB) program that came with the hardware. Likely better off just writing something completely from scratch in C which will serve the purpose of doing what the original program is lacking, plus what it already does, but a lot faster/smoother and without the occassional crash.

Then I'll email the vendor and let them know about the software - and that they can get stuffed if they think I'll share it with them. They have yet to reply to any emails and that ticks me off.

Bruno
_________________________
Bruno
Twisted Melon : Fine Mac OS Software

Top
#249914 - 19/02/2005 15:50 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: sn00p]
andym
carpal tunnel

Registered: 17/01/2002
Posts: 3996
Loc: Manchester UK
Another vote for PortMon, it rocks. We've gotten out of signing NDAs because of it.
_________________________
Cheers,

Andy M

Top
#249915 - 20/02/2005 21:10 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: tfabris]
n6mod
enthusiast

Registered: 27/09/1999
Posts: 200
Loc: Berkeley, CA
Any suggestions for a "dual port" version of PortMon that could monitor traffic between two serial devices? LIke, say, a head unit and a tuner box?

You'd need to connect the TD line from each device to an RD line on a serial port, but that's doable.

I guess I could write something that "shorted" the serial ports together, and then just run PortMon on one of them. That probably wouldn't introduce enough delay to matter.

-Z

PS: Linux solutions would work, too.
_________________________
-Zandr
Mk.IIa #010101243 currently getting a 500GB SSD. More spares in the shed.

Top
#249916 - 21/02/2005 05:12 Re: Debug/Reverse Engineer Serial Port & VB Program? [Re: n6mod]
n6mod
enthusiast

Registered: 27/09/1999
Posts: 200
Loc: Berkeley, CA
Quote:
PS: Linux solutions would work, too.


Found one, I'll give it a shot soon.

Linux Serial Sniffer
_________________________
-Zandr
Mk.IIa #010101243 currently getting a 500GB SSD. More spares in the shed.

Top