snicklin Posted January 21, 2016 Share Posted January 21, 2016 All, Here is a new version of the document which now reflects xBIOS 4.3 (released last weekend). Please note that it is still a beta version and knowingly needs a fair amount of work done to it. Any new code examples / requests for corrections are welcomed. Steve xBIOSDocumentation0.4.0.pdf 4 Quote Link to comment Share on other sites More sharing options...
twh/f2 Posted January 21, 2016 Share Posted January 21, 2016 HI Snicklin! thanks very much for your work. It helped me finally to understand XBios and the framework behind it! One idea: why not putting the content to the AtariWiki instead of publishing various PDF versions? https://atariwiki.org greetings twh Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 21, 2016 Author Share Posted January 21, 2016 One idea: why not putting the content to the AtariWiki instead of publishing various PDF versions? I fully intend to start putting the information onto the AtariWiki in time. The history of the document is that it started off as a document on my Google Docs account that I could update whenever and wherever I find any code that I could update the document with. It started off as a document for me to understand xBIOS and once I had enough examples I thought that I could distribute it, as long as people realise that I know it's not the finished document. A couple of weeks ago I considered putting it onto the AtariWiki but it will need some reformatting and it already needs a load of reformatting. Unless anyone wants to put it up there for me?? p.s. I love AtariWiki. Quote Link to comment Share on other sites More sharing options...
xxl Posted January 22, 2016 Share Posted January 22, 2016 if anyone has comments on how to develop the project or what else is needed in the xB then let me know. Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted January 22, 2016 Share Posted January 22, 2016 (edited) yeah... XXL, make a IRQ loader version (separate xbios version) which leave the CPU free for code while loading parallel. Imho compared to C64 scene A8 scene lacks of "custom" loaders for games/demos. (yeah I know there are several devices like sio2sd and hispeed yes or no etc)... but could be also interesting for games: stream map data like in 7cities of Gold... play music/grafics like Rescue on Fractalus Intro. etc etc etc. Edited January 22, 2016 by Heaven/TQA Quote Link to comment Share on other sites More sharing options...
xxl Posted January 22, 2016 Share Posted January 22, 2016 xB isnt IRQ loader: 1 Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted January 22, 2016 Share Posted January 22, 2016 xxl... I know... but I want to have xbios or xboot (file loading) functionality in combination with IRQ loader... your loading example... how would you handle 2 frame fx? and still waiting for the source code of that above example Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 23, 2016 Author Share Posted January 23, 2016 HI Snicklin! thanks very much for your work. It helped me finally to understand XBios and the framework behind it! One idea: why not putting the content to the AtariWiki instead of publishing various PDF versions? https://atariwiki.org greetings twh You'll all be pleased to know that I've got the document onto AtariWiki here: https://atariwiki.org/wiki/Wiki.jsp?page=XBIOS If anyone wants to edit the document, create an account and then follow the process to get edit permissions. Please note that some of the Google translations haven't been cleaned up into real English yet and that it isn't a finished document, but documents are never finished when they're on wiki's! The code needs some reformatting as it's come out strangely after several rounds of copying and pasting. If you understand the code and think that it could do with a bit of documentation to explain to others how it works, please add some text before/after/in the code. Krzysztof, can you add a link to the page from your website? I'll now add an update mentioning the xBIOS.cfg file as you mentioned in a PM. 3 Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 23, 2016 Author Share Posted January 23, 2016 OK, I've added a mention of the .cfg file in. As I've not used it myself, perhaps someone could add a comment on how to use the file. Do you just link it in with your PC based tool into your project or is it a file in the .atr disk? I now declare my PDF document obsolete. Quote Link to comment Share on other sites More sharing options...
twh/f2 Posted January 23, 2016 Share Posted January 23, 2016 awesome! I think Atariwiki is an excellent resource for that kind of documentation! Which guy did you contact to get write permissions? greetings, twh Quote Link to comment Share on other sites More sharing options...
xxl Posted January 23, 2016 Share Posted January 23, 2016 your loading example... how would you handle 2 frame fx? and still waiting for the source code of that above example not because its partly not my code. VBI can be programmed to perform extended parts of the code that does take a specified amount of time. You'll all be pleased to know that I've got the document onto AtariWiki here: https://atariwiki.org/wiki/Wiki.jsp?page=XBIOS Krzysztof, can you add a link to the page from your website? done and thanks :-) Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 24, 2016 Author Share Posted January 24, 2016 done and thanks :-) Thank you! Is there any way that xBIOS can detect how many disk drives exist? I can see that you can access more than 1 drive, but if drive 2 isn't connected, this won't be of much use. Or do you need to try and write a byte to disk 2 to see if it exists? Quote Link to comment Share on other sites More sharing options...
Kyle22 Posted January 24, 2016 Share Posted January 24, 2016 Do a $53 Status $302 DCOMND on $301 DUNIT. Does xBIOS support that? Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 24, 2016 Author Share Posted January 24, 2016 Do a $53 Status $302 DCOMND on $301 DUNIT. Does xBIOS support that? That's gone straight over my head, so I'll leave XXL to answer this one! Quote Link to comment Share on other sites More sharing options...
xxl Posted January 24, 2016 Share Posted January 24, 2016 Do a $53 Status $302 DCOMND on $301 DUNIT. Does xBIOS support that? you can use Status command without using AtariOS: use xBSIO isted of SIOINI: xBSIO jmp (xIOV) lets use Status command for drive: jsr xBIOS_SET_DEFAULT_DEVICE ; default xB SIO lda #$100-$04 ; set buffer size to 4 sta xBUFSIZE ldx #$53 ; 'S' - status jsr xBSIO we want see what is the sector size: lda $07fc ; buffer adress: xBUFFERH and xBUFSIZE and #%00100000 ; 1=Double 0=Single beq _jestS asl @ asl @ _jestS eor #$80 ; $80 - S; $00 - D and now lets configure xB FS to use 128/256 sectors in drive: jsr xBIOS_SET_BUFFER_SIZE 1 Quote Link to comment Share on other sites More sharing options...
xxl Posted January 24, 2016 Share Posted January 24, 2016 Is there any way that xBIOS can detect how many disk drives exist? I can see that you can access more than 1 drive, but if drive 2 isn't connected, this won't be of much use. lda #device_number sta xDEVICE jsr status Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 24, 2016 Author Share Posted January 24, 2016 awesome! I think Atariwiki is an excellent resource for that kind of documentation! Which guy did you contact to get write permissions? greetings, twh Sorry, I've only just seen this question. I followed this advice: https://atariwiki.org/wiki/Wiki.jsp?page=How%20to%20get%20Wiki%20edit%20permissions Quote Link to comment Share on other sites More sharing options...
MaPa Posted January 24, 2016 Share Posted January 24, 2016 Still error in the documentation which I pointed out earlier. The part "Replace the $xxxx at the start with a starting address. $0800 should a be safe address for all purposes. If you ever wish to start from a different address, simply change the value for ‘xBIOS’." is wrong. First, there is no $xxxx so the sentence is pointless and second, you can't simply change the value of 'xBIOS'. As I said several times, you have to change xBIOS.com binary header too or use xBIOS.CFG file with the same address in header as in your equ xBIOS. Quote Link to comment Share on other sites More sharing options...
snicklin Posted January 24, 2016 Author Share Posted January 24, 2016 Still error in the documentation which I pointed out earlier. The part "Replace the $xxxx at the start with a starting address. $0800 should a be safe address for all purposes. If you ever wish to start from a different address, simply change the value for ‘xBIOS’." is wrong. First, there is no $xxxx so the sentence is pointless and second, you can't simply change the value of 'xBIOS'. As I said several times, you have to change xBIOS.com binary header too or use xBIOS.CFG file with the same address in header as in your equ xBIOS. I've updated the $xxxx text as you are right, this didn't make snse. As for the other stuff, I've updated this in the document too. I thought that XXL was contradicting what you were saying, sometimes it's a bit hard to tell what is being said. As I've not played around with the config file, it's not an area that I am yet comfortable in. Anyway, doesn't matter, if there's any more errors, feel free to update the document, it's not my baby anymore. Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted February 26, 2016 Share Posted February 26, 2016 (edited) @xxl if I call xboot_load_file $5f1.... what ZPs need to be set? $FA...??? as out of a demo when setting back everything to OS I am loading xboot again to $0480-$5ff and try to load a file but somehow it fails as the directory content is loaded to $0580.... so it breaks the loader? demo_exit lda $d40b bne demo_exit load_next_part lda #0 sta $d20f :8 sta $d200+# lda #3 sta $d20f ;exit into OS lda #0 sta $d40e sta $d400 sta 559 lda #$ff ;roms on sta $d301 lda #$40 sta $d40e ;C598: A9 01 LC598 LDA #$01 ;C59A: 8D 01 03 STA DUNIT [$0301] ;C59D: A9 53 LDA #$53 ;C59F: 8D 02 03 STA DCOMND [$0302] ;C5A2: 20 53 E4 JSR DSKINV [$E453] = $4C lda #1 sta $0301 lda #$53 sta $0302 jsr $e453 bmi diskerror ;load 3 sectors to $0480,$500,$580 lda #$52 sta $0302 LDA #$00 STA $030B LDA #$01 STA $030A LDA #$80 STA $0304 LDA #$04 STA $0305 jsr $e453 bmi diskerror inc $030a LDA #$00 STA $0304 LDA #$05 STA $0305 jsr $e453 bmi diskerror inc $030a LDA #$80 STA $0304 LDA #$05 STA $0305 jsr $e453 bmi diskerror LDA #$00 STA $0304 LDA #$07 STA $0305 ;xboot loaded ldy #<fname ldx #>fname jmp xBOOT_LOAD_FILE fname .byte c'DESIRE1 DAT' diskerror lda 53770 sta $d01a jmp diskerror Edited February 26, 2016 by Heaven/TQA Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted February 27, 2016 Share Posted February 27, 2016 @xxl if I call xboot_load_file $5f1.... what ZPs need to be set? $FA...??? as out of a demo when setting back everything to OS I am loading xboot again to $0480-$5ff and try to load a file but somehow it fails as the directory content is loaded to $0580.... so it breaks the loader? demo_exit lda $d40b bne demo_exit load_next_part lda #0 sta $d20f :8 sta $d200+# lda #3 sta $d20f ;exit into OS lda #0 sta $d40e sta $d400 sta 559 lda #$ff ;roms on sta $d301 lda #$40 sta $d40e ;C598: A9 01 LC598 LDA #$01 ;C59A: 8D 01 03 STA DUNIT [$0301] ;C59D: A9 53 LDA #$53 ;C59F: 8D 02 03 STA DCOMND [$0302] ;C5A2: 20 53 E4 JSR DSKINV [$E453] = $4C lda #1 sta $0301 lda #$53 sta $0302 jsr $e453 bmi diskerror ;load 3 sectors to $0480,$500,$580 lda #$52 sta $0302 LDA #$00 STA $030B LDA #$01 STA $030A LDA #$80 STA $0304 LDA #$04 STA $0305 jsr $e453 bmi diskerror inc $030a LDA #$00 STA $0304 LDA #$05 STA $0305 jsr $e453 bmi diskerror inc $030a LDA #$80 STA $0304 LDA #$05 STA $0305 jsr $e453 bmi diskerror LDA #$00 STA $0304 LDA #$07 STA $0305 ;xboot loaded ldy #<fname ldx #>fname jmp xBOOT_LOAD_FILE fname .byte c'DESIRE1 DAT' diskerror lda 53770 sta $d01a jmp diskerror ok.... solved it with this patch: ;xboot loaded, patch ldx #10 @ lda fname,x sta $05db,x dex bpl @- jmp $0486 Quote Link to comment Share on other sites More sharing options...
RobS Posted December 16, 2018 Share Posted December 16, 2018 lda #device_number sta xDEVICE jsr status Would you mind elaborating and explaining this a bit more please? I can see no equate/function in xBIOS that is named "status" so where would you jsr to to get this status after setting the device #? Thank you. 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.