Jump to content
IGNORED

CHARA1 file load


Recommended Posts

37 minutes ago, ti99iuc said:

Unfortunately this article only has the first half of the program, and the second half is in the following month's issue that I don't have access to, as it is already packed up and in the garage.  I still have the 1997-1999 combined issues only.  I also remember trying to down load the MP pdf files from WHTECH, but was unsuccessful (lots of internet problems at the time), so if you can provide the second half also, it will be gratefully appreciated, even though it will take me a long time to actually create the complete program.  Thanks again for your quick help.

Link to comment
Share on other sites

It's just a PROGRAM image file, so you use the LOAD opcode to the correct VDP address and you're done.

 

I only have one example of a CHARA1 file, and it starts with character 0 (so you'd load it right at the pattern table base), but I thought in the back of my mind that I've seen others that start with space (so character 32, so start at pattern table + >100), and some start up at character 96 for /just/ the lowercase (so pattern table + >300). There's no header of any sort to tell you in advance, I usually just look for the exclamation mark (since it's easy to pick out), or decode the first character to graph paper to see what it is.

 

This code loads DSK1.CHARA1 as described above then returns, so you can run it from Editor/Assembler and see the results in the EA menu ;)

 


* LOAD DSK1.CHARA1 TO >800                                                      
* ASSUMES EA VDP SETUP                                                          
* ASSUMES CHARA1 STARTS WITH CHARACTER 0                                        
* DOES NOT CHECK FOR ERRORS                                                     
* BASED ON EA EXAMPLE SECTION 18.3                                              
                                                                                
       DEF START                                                                
       REF DSRLNK,VMBW,KSCAN                                                    
                                                                                
PAB    EQU >1000                                                                
PNTR   EQU >8356                                                                
DEST   EQU >0800                                                                
KEYM   EQU >8374                                                                
STATUS EQU >837C                                                                
                                                                                
* THIS IS THE PAB ITSELF                                                        
* LOAD,DEST,NA,MAX SIZE,NAME LENGTH                                             
PDATA  DATA >0500,DEST,>0000,>0400,>000B                                        
       TEXT 'DSK1.CHARA1'                                                       
       EVEN                                                                     
                                                                                
* SOMETHING TO SAY                                                              
TXT    TEXT 'This is just something to say'                                     
       EVEN                                                                     
                                                                                
* FIRST, COPY THE PAB INTO VDP RAM                                              
START  LI R0,PAB                                                                
       LI R1,PDATA                                                              
       LI R2,21                                                                 
       BLWP @VMBW                                                               
                                                                                
       LI R6,PAB+9       POINTER TO NAME LENGTH BYTE                            
       MOV R6,@PNTR      THIS IS WHERE THE DSRLNK LOOKS                         
       BLWP @DSRLNK      DO THE OPERATION                                       
       DATA 8            DEVICE, NOT SUBPROGRAM                                 
                                                                                
* DISPLAY A LINE OF TEXT TO SEE RESULT                                          
       LI R0,320         10 ROWS DOWN                                           
       LI R1,TXT                                                                
       LI R2,29                                                                 
       BLWP @VMBW        ADD YOUR OWN ERROR HANDLING...                         
                                                                                
* WAIT FOR KEY SO YOU CAN SEE IT...                                             
       LI R0,>0500                                                              
       MOVB R0,@KEYM                                                            
LP     BLWP @KSCAN                                                              
       MOVB @STATUS,R0                                                          
       ANDI R0,>2000     CHECK STATUS BIT                                       
       JEQ LP                                                                   
                                                                                
       CLR @STATUS       SO EA DOESN'T COMPLAIN                                 
                                                                                
       B *R11                                                                   
                                                                                
       END                                                                      

 

 

 

  • Like 4
Link to comment
Share on other sites

6 hours ago, arcadeshopper said:

Thanks Greg.  Hopefully I'll have more success downloading from WHTECH this time around than I did the previous time, back when we were having lots of Internet problems with our provider.

Link to comment
Share on other sites

4 hours ago, Tursi said:

It's just a PROGRAM image file, so you use the LOAD opcode to the correct VDP address and you're done.

 

I only have one example of a CHARA1 file, and it starts with character 0 (so you'd load it right at the pattern table base), but I thought in the back of my mind that I've seen others that start with space (so character 32, so start at pattern table + >100), and some start up at character 96 for /just/ the lowercase (so pattern table + >300). There's no header of any sort to tell you in advance, I usually just look for the exclamation mark (since it's easy to pick out), or decode the first character to graph paper to see what it is.

 

This code loads DSK1.CHARA1 as described above then returns, so you can run it from Editor/Assembler and see the results in the EA menu ;)

 

 


* LOAD DSK1.CHARA1 TO >800                                                      
* ASSUMES EA VDP SETUP                                                          
* ASSUMES CHARA1 STARTS WITH CHARACTER 0                                        
* DOES NOT CHECK FOR ERRORS                                                     
* BASED ON EA EXAMPLE SECTION 18.3                                              
                                                                                
       DEF START                                                                
       REF DSRLNK,VMBW,KSCAN                                                    
                                                                                
PAB    EQU >1000                                                                
PNTR   EQU >8356                                                                
DEST   EQU >0800                                                                
KEYM   EQU >8374                                                                
STATUS EQU >837C                                                                
                                                                                
* THIS IS THE PAB ITSELF                                                        
* LOAD,DEST,NA,MAX SIZE,NAME LENGTH                                             
PDATA  DATA >0500,DEST,>0000,>0400,>000B                                        
       TEXT 'DSK1.CHARA1'                                                       
       EVEN                                                                     
                                                                                
* SOMETHING TO SAY                                                              
TXT    TEXT 'This is just something to say'                                     
       EVEN                                                                     
                                                                                
* FIRST, COPY THE PAB INTO VDP RAM                                              
START  LI R0,PAB                                                                
       LI R1,PDATA                                                              
       LI R2,21                                                                 
       BLWP @VMBW                                                               
                                                                                
       LI R6,PAB+9       POINTER TO NAME LENGTH BYTE                            
       MOV R6,@PNTR      THIS IS WHERE THE DSRLNK LOOKS                         
       BLWP @DSRLNK      DO THE OPERATION                                       
       DATA 8            DEVICE, NOT SUBPROGRAM                                 
                                                                                
* DISPLAY A LINE OF TEXT TO SEE RESULT                                          
       LI R0,320         10 ROWS DOWN                                           
       LI R1,TXT                                                                
       LI R2,29                                                                 
       BLWP @VMBW        ADD YOUR OWN ERROR HANDLING...                         
                                                                                
* WAIT FOR KEY SO YOU CAN SEE IT...                                             
       LI R0,>0500                                                              
       MOVB R0,@KEYM                                                            
LP     BLWP @KSCAN                                                              
       MOVB @STATUS,R0                                                          
       ANDI R0,>2000     CHECK STATUS BIT                                       
       JEQ LP                                                                   
                                                                                
       CLR @STATUS       SO EA DOESN'T COMPLAIN                                 
                                                                                
       B *R11                                                                   
                                                                                
       END                                                                      

 

 

 

 

Thanks Mike.  I just wish the process was simpler for us old coots.  I guess my process of wanting to try out many CHARA(X) files will really take much longer time than I can spare until after our move is completed.  It's something that can wait any way.  I do appreciate everyone who has tried to be helpful.  I just think about all the times I've loaded programs that automatically load a CHARA1 file if it's on DSK1; like, 4ADOS (COMMAND DOS), and JJ's BOOT MENU programs, and a few others.  Oh well, I at least know what it will take, once I have the time.

  • Like 1
Link to comment
Share on other sites

Couldn't they be tried out the old fashioned way?

 

1. Put it on the disk with tiwriter's editor files. 

2. Load a text file in tiwriter, and edit it.

*. Repeat step 1 with the next CHARA1 to try...

 

I think fbForth has a word to load/reload them. That'd be fairly expediant. 

  • Like 2
Link to comment
Share on other sites

3 hours ago, jedimatt42 said:

I think fbForth has a word to load/reload them. That'd be fairly expedient.

 

USEFFL (USE Font FiLe) sets fbForth 2.0 up to load a font file and FNT actually loads it. The font file is expected to start with the pattern for ASCII 0 rather than the 6 program-loading bytes at the beginning of the usual TI Writer font files (like CHARA1). If you want to load CHARA1 in fbForth 2.0, FONTED can strip those 6 bytes and save the change as a new font file. Font files can be 1 KiB (ASCII 0 – 127) or 2 KiB (ASCII 0 – 255).

 

...lee

  • Like 2
Link to comment
Share on other sites

Oh, for some reason that TI-Writer CHARA1 format astonishes me... The optimal location to load it is 3 words early in the VDP buffer.

 

Then, if interpretted like EA5, the header indicates a single file, to load at 0x0800, and nearly 2k (almost an entire set of character definitions) but the file is only about 1k (7 bit ascii sufficient)

 

00 00 08 00 07 fa

 

I don't know if this is an original ti-writer file, or if someone truncated it to take advantage of the inner details of LOAD.

 

 

Link to comment
Share on other sites

9 hours ago, jedimatt42 said:

Couldn't they be tried out the old fashioned way?

 

1. Put it on the disk with tiwriter's editor files. 

2. Load a text file in tiwriter, and edit it.

*. Repeat step 1 with the next CHARA1 to try...

 

I think fbForth has a word to load/reload them. That'd be fairly expediant. 

Yes, this would seem like a much easier method to do what I want to do, but maybe Lee has an even better solution, so I'll be able to create my own CHARA1 files.

Link to comment
Share on other sites

5 hours ago, Lee Stewart said:

 

USEFFL (USE Font FiLe) sets fbForth 2.0 up to load a font file and FNT actually loads it. The font file is expected to start with the pattern for ASCII 0 rather than the 6 program-loading bytes at the beginning of the usual TI Writer font files (like CHARA1). If you want to load CHARA1 in fbForth 2.0, FONTED can strip those 6 bytes and save the change as a new font file. Font files can be 1 KiB (ASCII 0 – 127) or 2 KiB (ASCII 0 – 255).

 

...lee

Just as I thought, if fbForth is used, then fonted can be used to fix the bad headers of existing CHARA1 files, until I'm ready to create my own CHARA1 files.  My thanks to all you very helpful TI'ers on AtariAge.  No wonder I have such a hard time staying away when I'm suppose to be "packing" my TI hobby stuff to move or ship! ?

Link to comment
Share on other sites

1 hour ago, jedimatt42 said:

Oh, for some reason that TI-Writer CHARA1 format astonishes me... The optimal location to load it is 3 words early in the VDP buffer.

 

Then, if interpretted like EA5, the header indicates a single file, to load at 0x0800, and nearly 2k (almost an entire set of character definitions) but the file is only about 1k (7 bit ascii sufficient)

 


00 00 08 00 07 fa

 

I don't know if this is an original ti-writer file, or if someone truncated it to take advantage of the inner details of LOAD.

 

 

Yes, the CHARA1 file header has become an obvious flaw to deal with for those of us just now learning about it.  Thanks for your assistance.

Link to comment
Share on other sites

Where does one find these CHARA(X) fonts.  I would enjoy perusing them.

 

I have a loader saver utility for Camel99 as well.

Currently set for 1K files but it's just 1 parameter change to make it 2K.

\ Use SAVE-FILE LOAD-FILE for fast FONT LOADING
\ Usage:  S" DSK3.FONT0000" SAVE-FONT
\         S" DSK3.FONT0000" LOAD-FONT
 
\                            pdt size  mode
: SAVE-FONT ( file$ len --)  800 400  W/O100 SAVE-FILE ;
: LOAD-FONT ( file$ len --)  800 400  R/O100 LOAD-FILE ;
 

 

  • Like 3
Link to comment
Share on other sites

15 hours ago, TheBF said:

Where does one find these CHARA(X) fonts.  I would enjoy perusing them.

 

I have a loader saver utility for Camel99 as well.

Currently set for 1K files but it's just 1 parameter change to make it 2K.


\ Use SAVE-FILE LOAD-FILE for fast FONT LOADING
\ Usage:  S" DSK3.FONT0000" SAVE-FONT
\         S" DSK3.FONT0000" LOAD-FONT
 
\                            pdt size  mode
: SAVE-FONT ( file$ len --)  800 400  W/O100 SAVE-FILE ;
: LOAD-FONT ( file$ len --)  800 400  R/O100 LOAD-FILE ;
 

 

 

There are 270+ in  @sometimes99er's  font collection 

 

 

 

 

  • Like 5
  • Thanks 1
Link to comment
Share on other sites

1 hour ago, FarmerPotato said:

 

There are 270+ in  @sometimes99er's  font collection 

 

That is an excellent resource.  I thought there might be something in TI-99 binary format.

 

I can use Magellan to extract these but I still need to do some significant text file massaging to get it into a Forth source format.

I guess I need to write some code to allow Forth to swallow what Magellan gives me directly. :) 

 

Edit: I just saw that magellan can output binary data. DOH!

 

  • Like 4
Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...