Results 1 to 11 of 11

Thread: How hard can this be?

  1. #1

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    6

    Question How hard can this be?

    Greetings

    I am looking for a ?simple? module..

    I am trying to collect ASCII data from Com1, 19200,8,n,1.

    Up to 5000 lines of ASCII text is being sent to Com1 when I dump the buffer on the meter reader.

    The collected text is saved into a .txt file

    There is no need for a full blown Term program or module as there is NO communication being sent, just received.

    Anyone have such a module tucked away somewhere?

    Thanks
    Steve

  2. #2
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    well to make things easier for VB coders, the MSComm control should be used, which means a form will be needed instead of a module. i might see if i can do request soon. i will post it here if i do! but just to clarify things, how many lines exactly will be received? and when do u want the code to stop receiving data?
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


  3. #3

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    6
    Thanks for the info regarding MSCOMM and your possible offer to try this.

    While I've never counted the exact number of lines of data, I would guess that 2000 lines of data is stored each day.

    A manual button to shut down the capture or a timeout of 90minutes in case I am working on another unit while the buffer is being dumped would probably be the best.

    Thanks
    Steve

  4. #4
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    just one last question, very important! how is each line seperated? i ask this because the module will have to know when an entire line has been received. after i know this, i can begin working on it.
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


  5. #5

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    6
    The ASCII data is sent in Delimited text, has a <CR> at the end of each line.

    That make any sense?


    Thanks
    Steve

  6. #6
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    yup makes perfect sense. i will have the module ready in a few days.
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


  7. #7
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    all done. test it for me and i will fix it if any bugs come up.
    Attached Files Attached Files
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


  8. #8

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    6
    Works fine.

    Perfect


    Thank you
    Steve

  9. #9
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    no problem.
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


  10. #10

    Thread Starter
    New Member
    Join Date
    Dec 2002
    Posts
    6
    One minor alteration?

    How hard would it be to allow the user to name the directory and filename of the saved text?

    Steve

  11. #11
    Addicted Member TheSarlacc's Avatar
    Join Date
    Aug 2002
    Location
    Somewhere close
    Posts
    185
    not hard at all. here is the modified module. anything else, just post.
    Attached Files Attached Files
    Get Quoted:

    "If Shane Warne had given his mobile phone to Russell Crowe, neither of them would be in trouble."
    "She has more troubles than a centipede with its legs crossed."
    "For every action, there is an equal and opposite Government program."


Posting Permissions

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



Click Here to Expand Forum to Full Width