Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Topcon fc5 Data Collector - Computer program

51 views
Skip to first unread message

Jess P.

unread,
Apr 22, 2004, 4:49:13 PM4/22/04
to
Hello all,

I was asked to write a program which can receive data from the
mentioned device.
I've written such program in BASIC but won't run on any of the BASIC
for Windows compilers I've tried (liberty BASIC, BCC BASIC and others)
- I was specifically asked to write the utillity in BASIC.

I have two questions:
1. Does anyone know where to attain such a utilly (with or without the
source code) that is able to receive data from this device?
2. Can anyone (I realize BASIC is a dying language) try to compile
this and tell why my compilers won't? It been long since I've written
in BASIC but my syntax appears correct to me.
The compilers I've tried only claim for syntax error in many lines
that seem correct to me, also I've checked the language documentation
and it agrees with me - the compilers won't specify why it's a syntax
error which I find especially annoying!!!

Receving the data using ACK-NAK Protocol

10 AK$=CHR$(&H6)+CHR$(&HD)+CHR$(&HA) ' AK$=ACK CR LF - compiler
claims this line to be a syntax error and does specify why..
20 NK$=CHR$(&H15)+CHR$(&HD)+CHR$(&HA)
30 I=1
40 OPEN "c:\data.txt" FOR OUTPUT as #2
50 FIELD #2, 132 AS R$
60 OPEN "COM2:9600,N,8,2,CS0,DS0" FOR INPUT AS #1
70 PRINT #1,CHR$(&H5);CHR$(&HD);CHR$(&HA)
80 LINE INPUT #1,A$
90 IF LEFT$(A$,1)<>CHR$(&H6) THEN 70
100 LINE INPUT #1,RE$
110 IF INSTR(RE$,CHR$(&H4))<>0 THEN 200 - again syntax error
120 RE$=MID$(RE$,INSTR(RE$,CHR$(&H2))+1,INSTR(RE$,CHR$(&H3))-INSTR(RE$,CHR$(&H2))-1)
130 PRINT RE$
140 GOSUB 300
150 IF BC$<>RIGHT$(RE$,3) THEN PRINT #1,NK$; :GOTO 100
160 LSET R$=RE$
170 PUT #2,I
180 I=I+1
190 PRINT #1,AK$; :GOTO 100
200 LSET R$="EOF"
210 PUT #2,I
220 CLOSE #1,#2
230 END


300 'BCC CALC
310 P=LEN(RE$)-3
320 BCC=0
330 FOR J=1 TO P
340 BCC=BCC XOR ASC(MID$(RE$,J,1))
350 NEXT J
360 BC$=RIGHT$("000"+RIGHT$(STR$(BCC),LEN(STR$(BCC))-1),3)
370 RETURN

Many thanks to anyone who tries to help :)
You can also reply to my mailbox je...@cables.org.il

robyn....@gmail.com

unread,
Jan 20, 2013, 9:33:18 PM1/20/13
to
I have a program called DOWNLOAD.EXE which is part of a DOS suite of engineering software, Foresight Software. This program downloads survey data from the FC-5 to a computer.
To upload survey data to the FC-5, UPLOAD.EXE is used (using SURVEY 2 card)
Regards
Ernie Burgers
ernie....@bigpond.com
0 new messages