| www.retrosoftware.co.uk http://www.retrosoftware.co.uk/forum/ |
|
| OSWORD 7F and 6502 Second Processor http://www.retrosoftware.co.uk/forum/viewtopic.php?f=73&t=792 |
Page 1 of 1 |
| Author: | s1paulr [ Sun Sep 23, 2012 1:28 pm ] |
| Post subject: | OSWORD 7F and 6502 Second Processor |
If I use the Read Data Multi-Sector command (&53) with OSWORD 7F when the Tube is enabled, no matter which buffer address I specify, the data is always returned to 0x130A in the second processor. Is it possible to specify another buffer address ? If not any suggestions would be gratefully received on how to replicate this command |
|
| Author: | jgharston [ Wed Oct 10, 2012 1:55 am ] |
| Post subject: | Re: OSWORD 7F and 6502 Second Processor |
s1paulr wrote: If I use the Read Data Multi-Sector command (&53) with OSWORD 7F when the Tube is enabled, no matter which buffer address I specify, the data is always returned to 0x130A in the second processor. That would only happen if you actually specify &130A as the data address. Are you filling the control block correctly:Code: Control block XY?&00 Drive XY!&01 Data address XY?&05 Number of parameters (n) XY?&06 Command XY+7... Parameters XY?(7+n) Result Try using the code on the BeebWiki: Code: REM Set up a global control block early in the program: result%=FNdisk(address, &53, drive, track, sector, count, 1) will read 'count' sectors into memory at 'address'.
DIM ctrl% 31:X%=ctrl%:Y%=X%DIV256 ... DEFFNdisk(addr%,cmd%,drv%,trk%,sec%,num%,den%):LOCAL fs% fs%=FNfs:IF fs%<>4:*FX143,18,4 REPEAT X%?0=drv%+den%*24+8:X%!1=addr%:X%?5=3-7*(cmd%>127) X%?6=cmd%:X%?7=trk%:X%?8=sec%:X%!9=num%OR&1E20 A%=127:CALL&FFF1:A%=X%?(X%?5+7) UNTIL A%<>&10:IF fs%<>4:OSCLI"FX143,18,"+STR$ fs% =A% DEFFNfs:LOCAL A%,E%,Y%:=(USR&FFDA)AND&FF |
|
| Author: | s1paulr [ Thu Oct 11, 2012 1:47 pm ] |
| Post subject: | Re: OSWORD 7F and 6502 Second Processor |
Thanks John, No matter what buffer address I specify in the parameter block, the data is returned to 0x130A in the second processor. If I disable the Tube, then the code returns the data to the address specified as expected. When I get some time I will try the other method. In the mean time, I just explicitly set the buffer to 130A and PAGE to 1900 which of course means that the code operates identically with the tube enabled or disabled. Many thanks again, Paul |
|
| Author: | s1paulr [ Sat Oct 13, 2012 10:45 am ] |
| Post subject: | Re: OSWORD 7F and 6502 Second Processor |
Hi John, I tried this code and get exactly the same result as I did with my own code. With the Tube disabled, the data is returned to the correct address, but with the Tube enabled it is always returned to 0x130A in the 2P. Very odd indeed. Either I have discovered an anomaly or maybe there is a bug in the Turbo MMC DFS? Commercial 2P program's such as Hi-View etc. all run flawlessly, so I doubt that there is anything wrong with my hardware. Also all programs I write work as expected aside from this one issue. As an aside I am using John Kortink's FPGA 2P on a Terasic DE0, but I cannot see how this could make any difference to a single OSWORD call. Paul |
|
| Page 1 of 1 | All times are UTC [ DST ] |
| Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |
|