Hi everyone, I'm looking for advice on how I would go about making this word processor save routine more efficient. The text is stored in the ram at (decimal) 6168 to 7168 after it is poked into this location when exiting the edit screen. In Basic 4 on a PET 4016 it saves 1000 bytes as 25 or 26 strings. And for some reason. On Basic 1 on my 2001-8 it saves as 20 strings. This makes me think that it's saving before the cassette buffer is full. Each full string is 39 bytes long in basic 4 and about 50 bytes long in basic 1. The problem with this is, is that there's a lot of tape that's being used by interblock tones that happen after each string. 1000 bytes consumes around 3 minutes of tape. So in Basic 4 it saves like this, Leader tone file header 2 second tone 39 bytes of text (saved twice) interblock tone (2 second tone) 39 bytes of text (saved twice) interblock tone (2 second tone) 39 bytes of text And this continues on till the 1000 bytes of text is saved. the a end of file marker is recorded. I realize that it's normal for the 2 second interblock gaps and the information to be saved twice. My question is why is this routine causing a save to happen long before the 192 byte cassette buffer is full? And how would I go about forcing it to fill the buffer before saving the next string? There's something I'm missing. Any help would be greatly appreciated. And this is the routine. *405 open1,1,1:fora=6168to7168:x=peek(a):print#1,x:next:close1 * Text listing listing of the program is here https://planet.davewylie.uk/technology/pet/listings/wpros.txt <https://planet.davewylie.uk/technology/pet/listings/wpros.txt> -- Sent from: http://cbm-hackers.2304266.n4.nabble.com/Received on 2020-05-30 01:45:38
Archive generated by hypermail 2.3.0.