Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Can't the LOAD command be used in a basic program?
2007-04-18 20:22
Shadow
Account closed

Registered: Apr 2002
Posts: 355
Can't the LOAD command be used in a basic program?

1 LOAD"ROUTINE",8,1
2 SYS 49152
RUN

Ends up in a endless loop, so I guess it doesn't do what I expect it to do...

(This may seem stupid, but it would be very handy for me when crossdeving for the DTV, as I need to load the files from 64HDD all the time, with this I could just do "run" to load the lastest routine from disk and execute)
 
... 30 posts hidden. Click here to view all posts....
 
2007-04-20 19:23
iAN CooG

Registered: May 2002
Posts: 3177
quoting some FAQ file found on the net:

#9. To load a program from BASIC without re-run problems or tricky
variable/ongoto statements....

poke147,0
sys57812 "filename",8,1
sys62631

here's another method for data files:

following will work to read in everything except the first two bytes:

1000 SYS 57812 "NAME,S",8,0:REM SET PARAMETERS FOR LOAD
1010 POKE 193,L%:POKE 194,H%
1020 POKE 147,0:SYS 62631

L% is the low byte of the load address, and H% is the high byte, e.g.
H%= INT(address/256): L%=address-256*H%

POKEing a 0 into 147 performs a load; a 1 would perform a verify.
2007-04-20 21:34
Mace

Registered: May 2002
Posts: 1799
Quote:
1000 SYS 57812 "NAME,S",8,0:REM SET PARAMETERS FOR LOAD
1010 POKE 193,L%:POKE 194,H%
1020 POKE 147,0:SYS 62631

Why "name,s"....? What does the S do?
2007-04-20 21:47
tlr

Registered: Sep 2003
Posts: 1762
Quote: Quote:
1000 SYS 57812 "NAME,S",8,0:REM SET PARAMETERS FOR LOAD
1010 POKE 193,L%:POKE 194,H%
1020 POKE 147,0:SYS 62631

Why "name,s"....? What does the S do?


It loads a SEQ file instead of the default PRG.
Previous - 1 | 2 | 3 | 4 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
zscs
JEZ
sLASH
syncroman
Fred/Channel 4
Meikel aka ZUX/Sparks
Martin Piper
Linus/MSL
Guests online: 132
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Mojo  (9.6)
6 Uncensored  (9.6)
7 Wonderland XIV  (9.6)
8 Comaland 100%  (9.6)
9 No Bounds  (9.6)
10 Unboxed  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 Party Elk 2  (9.6)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.6)
5 Rainbow Connection  (9.5)
6 It's More Fun to Com..  (9.5)
7 Morph  (9.5)
8 Dawnfall V1.1  (9.5)
9 Onscreen 5k  (9.5)
10 Daah, Those Acid Pil..  (9.5)
Top Groups
1 Booze Design  (9.3)
2 Oxyron  (9.3)
3 Nostalgia  (9.3)
4 Censor Design  (9.3)
5 Triad  (9.2)
Top Webmasters
1 Slaygon  (9.6)
2 Perff  (9.6)
3 Morpheus  (9.5)
4 Sabbi  (9.5)
5 CreaMD  (9.1)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.035 sec.