TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: ALL
from: SANDER SMEENK
date: 1996-08-11 12:40:00
subject: FossilRoutines

Hello All,
I converted this little Pascal source to initialize and send data through 
fossil (NOT X00!!!!!!!) in PowerBasic, but it won't work properly, unless I 
put in this nasty delay... The problem is that when i remove this delay, 
powerbasic goes too fast for the fossil to process the calls, and all you get 
is 'My Dea'. But with the delay, it goes as slow as a 2400 baud modem!!
Who can tell me what I'm doing wrong?!?!
---
DIM Port AS SHARED INTEGER
Port=3
PRINT "Fossil Revision Level: ";F_FosINIT   'Initialize Fossil
TXString("My Dear User . . .")              'Send stringdata
TXString("Welcome to my TEST Door")
F_FosDEINIT                                 'DeInitialize Fossil
END
SUB TXString(Text AS STRING)
DIM Char AS STRING
IF LEN(Text) THEN
    Text = Text + CHR$(10)
    FOR Counter% = 1 TO LEN(Text)
        Char = MID$(Text, Counter%, 1)
        TXCharWait(Char)
>       delay .028                           'This is the delay I'm
                                             'talking about...
    NEXT Counter%
END IF
END SUB
SUB TXCharWait(Char AS STRING)
    !MOV AH, &H0B
    !MOV DX, Port
    !MOV AL, Char
    !INT &H14
END SUB
SUB F_FosDEINIT PUBLIC
!MOV AH,&h05
!MOV DX,Port
!INT &H14
END SUB
FUNCTION F_FosINIT PUBLIC AS INTEGER
!MOV AH,&h04
!MOV DX,Port
!INT &H14
!MOV FUNCTION,BH
END FUNCTION
L8eRZ!
sander@taf.idn.nl
... Albatross, get your albatross ....
--- GoldED/386 2.50+
---------------
* Origin: iNFiNiTY SYSTeM - !33k6! - 033-4943146 (2:283/507)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.