borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (smart menu)Next Topic (A folder making prog) New Topic New Poll Post Reply
AndreaVB Forum : VB General : Need a (small) program written ..
Poster Message
riger
Level: Protégé

Registered: 18-01-2006
Posts: 4

icon Need a (small) program written ..

Is there anyone that can help?

I have a small (66k) dos script that sends a specified text file to a com port.  In the script, one must specify the baud rate, stop bits, port number, etc....  and the file name (which for some reason needs to be a text file with a .msg extension).

This sends the contents of the text file to the specified com port.  There is no pause function, nor is there any recognition of the end of the file, so it loops through if you don't catch it in time...

I would like this written to a Windows app, with the ability to pause the file/data and also to recognise an End of File "flag" I would also like to manually be able to declare flags in the text file to auto pause there (if required).

Obviously I'll have to send the dos exe  file to anyone who wishes to take this on.

Best Regards
Richard

18-01-2006 at 04:19 PM
View Profile Send Email to User Show All Posts | Quote Reply
stickleprojects
Level: Moderator


Registered: 09-09-2002
Posts: 891
icon Re: Need a (small) program written ..

Hi,
If you have the source for the dos file, that would be great!
Kieron


____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)

18-01-2006 at 06:17 PM
View Profile Send Email to User Show All Posts | Quote Reply
riger
Level: Protégé

Registered: 18-01-2006
Posts: 4
icon Re: Need a (small) program written ..

quote:
stickleprojects wrote:
Hi,
If you have the source for the dos file, that would be great!
Kieron



I am sorry, I am not a programmer, I have an exe file, but that's about it, does tha help or does it mean you will have to write the whole widget from scratch ?

Richard
18-01-2006 at 08:01 PM
View Profile Send Email to User Show All Posts | Quote Reply
stickleprojects
Level: Moderator


Registered: 09-09-2002
Posts: 891
icon Re: Need a (small) program written ..

Hi Riger,
What have you tried? What do you need? To code a generic sockets app (with comments) will take time. Can you be more specific pls?
Kieron


____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)

19-01-2006 at 12:01 AM
View Profile Send Email to User Show All Posts | Quote Reply
riger
Level: Protégé

Registered: 18-01-2006
Posts: 4
icon Re: Need a (small) program written ..

Hello there,

Sorry I was not all that clear, I'll try and explain it properly.

OVERVIEW

I am busy trying to test the data captured by a 3rd party prgram.

Normally, this data arrives through a network called AFTN (Aeronautical Fixed Telecommunications Network.

In order to be able to run 24hours of data into the capture software (without waiting the for a whole day), we have recorded numerous days of data already.

We have a little batch file that we edit on a file for file basis. The batch command looks like this

aftnsim -c1 -b9600 -d8 -s1 -pn Af020106.msg

where;

[aftnsim] : is the executable file that we have
[-c1] : Com Port
[-b9600] : baud rate
[-d8] : data bits
[-s1] : stop bits
[-pn] : parity
[Af020106.msg]: file name, of which the contents are to be sent.

Note: The data exists in a txt file, but I have to rename the file to a .msg first ! I am not sure why and I would prefer not to, but I do.  I don't mind if there is a good technical reason of course.

Once you press the correct key (on prompt) the contents of the file are sent to the specified comport at the specified rate.  This is in turn captured by the software that we are testing.

Depending on the results, we will change some configurables (in the software being evaluated) , delete the data and run the "simulation" again.

PROBLEM

Whilst the dos thing we have does the job, there is no way to pause the data (manually or otherwise) without terminating the job.
Once started, the the file does not stop at the end of the file, it starts at the begining again and loops over and over.

REQUIREMENT

Ideally, I would like to have the same functionality as above but in a Windows Program, with the follow extra functionality.

The ability to determine the variables and save them (as a configuration) in the program or in an associated text file, or simply remember the previous settings.

The ability to transmit .txt files

The ability to select that text file via standard windows method.

The ability to "Pause" and "Resume" whilst the file contents are being sent.

The ability to "Loop" or "Run Once Only"

The ability to Manually insert auto pause phrases (unique text) into the text files which cause the "run" to pause (if the check box for this action is selected).

----
That is in essence what I need, the problem is that I do not know enough about programming to do this myself.

How should I procceed from here ?

If there is anyone that would like me to send them the dos executable and batch file, please feel free to email me @


gerstner----<AT>----gmail----<dot>----com




Best Regards
Richard






[Edited by riger on 19-01-2006 at 05:52 AM GMT]

19-01-2006 at 04:03 AM
View Profile Send Email to User Show All Posts | Quote Reply
stickleprojects
Level: Moderator


Registered: 09-09-2002
Posts: 891
icon Re: Need a (small) program written ..

Hi,
This is a very quick and dirty application that (should) send data to the given port.
Can you have a look at it?
Open the VBP
Run it
Check the port settings, then click start
Choose a file name using the "..." button
Choose whether to loop or not
Then click "Send File".

The reason im sending this to you is i haven't found a way of testing this code... it seems to work, but am unsure.

Can you let me know if it works, then i'll tidy it up and add the pause stuff. Can you also explain at bit more about the auto-pause?
Ta
Kieron


____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)

____________________________
Attached:
serialport.zip 5 KB (Downloads: 4)

19-01-2006 at 04:29 PM
View Profile Send Email to User Show All Posts | Quote Reply
riger
Level: Protégé

Registered: 18-01-2006
Posts: 4
icon Re: Need a (small) program written ..

Hi there Kieron,

Thankyou for the fast response.

I am not a programmer, so I am not able to load those files you gave me, I did a search, and I see that they are VB files.

Can you advise me as to how I should use them?

With regards to the Auto-Pause, my idea was to manually insert a string of text like "xx--pause--xx" into the file at critical places, and then (if the option is selected) the program could pause at these locations and wait for the "continue" command.
This will allow me to evaluate a progressive set of data at various stages.

I cannot express how grateful I am for your help.

Richard

19-01-2006 at 08:38 PM
View Profile Send Email to User Show All Posts | Quote Reply
stickleprojects
Level: Moderator


Registered: 09-09-2002
Posts: 891
icon Re: Need a (small) program written ..

Hi Richard,
I have compiled the project for you and built an installation package. Can you run it and then let me know your comments.
Pls note, this project is not commercial-quality, it's a very simple one.. i'll improve it after your comments.
I have emailed you directly asking for permission to send this setup as we cannot upload EXE files here.

Regards,
Kieron

[Edited by stickleprojects on 20-01-2006 at 02:05 PM GMT]

____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)

20-01-2006 at 02:02 PM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : VB General : Need a (small) program written ..
Previous Topic (smart menu)Next Topic (A folder making prog) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder