Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Command-line serial port logger..??

  1. #1
    Raw Wave tj!2k4's Avatar
    Join Date
    Oct 2004
    Posts
    3,294

    Command-line serial port logger..??

    I'm looking for a strictly command-line based app to log (nmea string) data from a specified serial port to a file, but can't seem to find a freeware app that'll do this.

    Everything is either GUI-driven, or costs $100. wtf. Is it really that involved??

    If I had any programming skills I'd write it myself..

    Does anyone have any suggestions? Thanks..

  2. #2
    MySQL Error MatrixPC's Avatar
    Join Date
    Sep 2003
    Location
    Beach City, Socal
    Posts
    4,053
    Why don't you try xport?
    it may not be command line but free.
    2004 Matrix XR A7N8X-VM/400 AMD XP-M 2500+, DS-ATX
    89 Supra Turbo P3 600E@750/Abit BE6 II, Alpine M-BUS Car2PC.
    Y2K Accord Dell GX150
    RoadRunner is the best FE PERIOD
    EmoRebellion is a SCAMMER

  3. #3
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Location
    Toronto, Canada
    Posts
    9,818
    I've used Hyperterminal to log NMEA data so I could use it later for testing GPS navigation in RR.. if you use xport with it you can log and use the GPS at the same time.. it will be hard to find strictly command-line based software for that (although relatively easy to make one)...
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

  4. #4
    Raw Wave tj!2k4's Avatar
    Join Date
    Oct 2004
    Posts
    3,294
    I'm using already using xport3 to split the serial port.

    The reason I'm looking for a command line app is so i can run it as an automated event, where no user interaction is required, and runs more or less transparently..

  5. #5
    Confusion Master
    Auto Apps:loading...
    Enforcer's Avatar
    Join Date
    Sep 2003
    Location
    If you go down to the woods today, You're sure of
    Posts
    14,622
    try this in a batch file

    Code:
    MODE COM1: baud=4800 parity=N data=8 stop=1
    TYPE command > COM1
    COPY COM1 text.txt
    Only problem you might have is stopping it as it will continue till it receives an end of file code CTRL-Z

  6. #6
    FLAC PURDooM's Avatar
    Join Date
    Jun 2005
    Location
    Anoka County, MN
    Posts
    1,020
    Quote Originally Posted by Enforcer
    try this in a batch file

    Code:
    MODE COM1: baud=4800 parity=N data=8 stop=1
    TYPE command > COM1
    COPY COM1 text.txt
    Only problem you might have is stopping it as it will continue till it receives an end of file code CTRL-Z
    The line TYPE command > COM1 looks wrong to me... thats going to try to pipe the contents of file command (if the file even exsists) into com1. Are you sure you didnt want the command echo?
    Current projects: iGmod reloaded (Latest release) (put on hiatus indefinatly)

    Unlimited Internet and gps tracking for $6 a month with boost mobile!

    Carputer 2: www.lmaocar.com

  7. #7
    Raw Wave tj!2k4's Avatar
    Join Date
    Oct 2004
    Posts
    3,294
    hmm, an interesting approach..

    here's what happens when i try to run it as a batch..

    C:\>MODE COM1: baud=4800 parity=N data=8 stop=1

    Status for device COM1:
    -----------------------
    Baud: 4800
    Parity: None
    Data Bits: 8
    Stop Bits: 1
    Timeout: ON
    XON/XOFF: OFF
    CTS handshaking: OFF
    DSR handshaking: OFF
    DSR sensitivity: OFF
    DTR circuit: ON
    RTS circuit: ON


    C:\>TYPE command 1>COM1
    The system cannot find the file specified.

    C:\>COPY COM1 text.txt
    1 file(s) copied.
    Another thing about the second line, is that when run in the .bat, it automatically inserts a "1" after "type command"

  8. #8

  9. #9
    Confusion Master
    Auto Apps:loading...
    Enforcer's Avatar
    Join Date
    Sep 2003
    Location
    If you go down to the woods today, You're sure of
    Posts
    14,622
    OK option 2

    get yourself a copy of QBASIC (preferably the version that let's you make an EXE (this was given away free with a lot of the earlier versions of DOS)

    Code:
    OPEN "com1:9600,n,8,1,CD0,CS0,DS0,RS" FOR INPUT AS #1
    OPEN "textfile.txt" for output as #2
    WHILE INKEY$ <> " "
    INPUT #1, a$
    PRINT #2, a$
    WEND
    CLOSE #2
    CLOSE #1
    END

    Press <space> for it to end

  10. #10
    Raw Wave tj!2k4's Avatar
    Join Date
    Oct 2004
    Posts
    3,294
    Thanks for the suggestions, enforcer. I'll give that a shot when I get back home.

    If that doesn't do what I need it to, I'll investigate if I can do this in Perl. I'm not 100% certain whether Perl can interface with serial ports or not, but I'm fairly certain that it's possible.

Page 1 of 2 12 LastLast

Similar Threads

  1. serial port to game port adapter wiring
    By asif in forum General Hardware Discussion
    Replies: 5
    Last Post: 08-17-2006, 04:47 PM
  2. USB Serial Port Adapter Troubles
    By bLindmOnkey in forum General MP3Car Discussion
    Replies: 0
    Last Post: 10-13-2004, 11:29 PM
  3. Via Mini-ITX Epia 5000 serial port not working
    By vash in forum General Hardware Discussion
    Replies: 2
    Last Post: 08-13-2002, 08:48 PM
  4. how can I use my printer port as a serial port on win Xp
    By babas151 in forum General Hardware Discussion
    Replies: 3
    Last Post: 04-09-2002, 05:23 PM
  5. 1 serial port, 2 devices
    By Meatballman in forum General Hardware Discussion
    Replies: 7
    Last Post: 04-16-2000, 10:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •