- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a GPS device connected to my PC, hanging on COM1. I want to send and receive serial bytes to/from it. The baud rate is 9600.
Does this require special routines, or can the OPEN statement suffice, followed by READ and WRITE statements?
I tried accessing the SPORT_**** routines, but USE DFLIB does not allow me to use those. Maybe a different USE statement?
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If you're using Intel Fortran, try USE IFPORT. SPORT routines are the easiest route - OPEN and READ/WRITE won't work well for this and you can't set baud rates.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Unfortunately, I have the Compaq Fortran, version 6.6.
I did notice that some SPORT routinesDO allow me to set baud rate.
Are you saying these don't work properly?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No, I didn't say that. The SPORT routines work fine as far as I know. But the documentation can be unclear, especially as it relates to setting the number of stop bits.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The att. module (posted here before) shows how to do serial communications in a Win32 environment (has to be totally opsys-specific, of course). This is probably more than you were looking for, in that this module addresses the issue of threadedness by creatinga thread for each port and conducting the serial i/o in separate threads, but that's the way to go.
Unfortunately, the SPORT routinesgot the threading model wrong, and are nonfunctional (ie, waste of time).
Regards, Paul Curtis

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page