Ranger03 Posted July 22, 2018 Share Posted July 22, 2018 code: let a=usr(550) Data 324,400,123 Data 213,123,40 data 123,12,23 end a=usr(550) then a menu popped up and said that the emulator had jammed Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 22, 2018 Share Posted July 22, 2018 What are you trying to do? USR() invokes machine code that you've copied beforehand to the given address. Address 550 isn't a valid address for USR code, it's in the middle of the OS variables. Quote Link to comment Share on other sites More sharing options...
Ranger03 Posted July 22, 2018 Author Share Posted July 22, 2018 did the author test 3.00? i can't run anything Quote Link to comment Share on other sites More sharing options...
phaeron Posted July 22, 2018 Share Posted July 22, 2018 I'm pretty sure he tested it, yes. The BASIC code you have in the original post doesn't make sense and will crash on any Atari computer. If you're trying to type in a BASIC listing from somewhere, it would help to have a link so we can see the original listing or article. 1 Quote Link to comment Share on other sites More sharing options...
Mclaneinc Posted July 22, 2018 Share Posted July 22, 2018 (edited) Ranger, consult books like Mapping the Atari which are all over the place including if memory serves on MrFish's super fine web site http://seriouscomputerist.altervista.org/ It will show you where is and isn't in this case a good place to store code... And yeah, I think we can assume the author tested your code in this case If you have not looked at that book before then do, its a bible for programmers with the odd mistake that the author of Altirra has noticed, in fact you may want to check out this: http://www.virtualdub.org/downloads/Altirra%20Hardware%20Reference%20Manual.pdf Its the Altirra hardware reference manual, another MUST HAVE book... I forget the authors name.. He seems to know his stuff though.. Have great fun with your programming Paul.. Edited July 22, 2018 by Mclaneinc 1 Quote Link to comment Share on other sites More sharing options...
Ranger03 Posted July 22, 2018 Author Share Posted July 22, 2018 i never bothered to complete the program anyway, but it's still somewhat perplexing. it went something like this: rom=8155 ram=8255 fori=8122 to 8255 poke ram+i peek(ram+i) or something like that, can't remember. Quote Link to comment Share on other sites More sharing options...
Ranger03 Posted July 22, 2018 Author Share Posted July 22, 2018 What are you trying to do? USR() invokes machine code that you've copied beforehand to the given address. Address 550 isn't a valid address for USR code, it's in the middle of the OS variables. so is that what the rem statement is for? to copy machine code? Quote Link to comment Share on other sites More sharing options...
flashjazzcat Posted July 22, 2018 Share Posted July 22, 2018 There's some useful reading for those wanting to learn Atari BASIC (which appears to be what you need to do first) in this thread: http://atariage.com/forums/topic/257073-i-need-some-suggestions-for-good-beginner-basic-books/ 1 Quote Link to comment Share on other sites More sharing options...
Kyle22 Posted July 25, 2018 Share Posted July 25, 2018 code: let a=usr(550) Data 324,400,123 Data 213,123,40 data 123,12,23 end a=usr(550) then a menu popped up and said that the emulator had jammed First of all, there is no need to use the word LET. Second, if you would try it, LET USR does the USR call immediately. Jump into Atari BASIC and type: LET A=USR(58487). Instant jump through $E477. As mentioned above: 550 is NOT a proper address for your own code. That area is reserved for the OS Timers. Try $600 (1536). Please Read several times until you understand Mapping the Atari: https://www.atariarchives.org/mapping/memorymap.php 1 Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted July 25, 2018 Share Posted July 25, 2018 And those 324,400 are not suspicious??? 3 Quote Link to comment Share on other sites More sharing options...
Kyle22 Posted July 28, 2018 Share Posted July 28, 2018 How did I miss that??? Of course, only 0-255. Also, you would need a for...read...poke...next loop to load RAM with your data before the USR call. 1 Quote Link to comment Share on other sites More sharing options...
kenjennings Posted August 18, 2018 Share Posted August 18, 2018 Ranger03: Some simple utilities in assembly language for Atari BASIC: http://atariage.com/forums/blog/576/entry-13175-part-1-of-11-simple-assembly-for-atari-basic-introduction/ Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.