So ... here's my list of questions. Warning: Expect abrupt and large topic jumps. Wink

1. I found and installed the CE toolchain and libraries. As far as I understand, they are based on what little technical information TI has published, and probably a whole lot of reverse engineering (especially the contents of ti84pce.inc).

Is that correct?

Does TI have any plans to release more information, libraries, IDE, etc. for C/assembly development on the CE? IMHO it would be the device manufacturers job to provide development tools, or at least release the complete set of documentation necessary for creating them without large amounts of reverse engineering.

2. gfx_SwapDraw vs. gfx_BlitBuffer

If I understand the library code correctly (I am not familiar with eZ80 HW and assembly, but I have over a decade of experience working with various other architectures like MSP430, 8051 and ARM), gfx_SwapDraw actually synchronizes the buffer swap with the LCD refresh, while gfx_BlitBuffer does not?

Side question: What is the refresh rate of the LCD? 30 Hz? 60 Hz?

3. Is there any information on which resources a program can safely use, e.g. on-chip timers, etc, and which are require by the calculators software/OS?

4. Can programs use the MACC unit of the eZ80? And if yes, are there library functions for using it from C? I looked at ZDSII, and it does not appear to have any settings for using a library that takes advantage of the MACC unit. (The MSP430 device I worked with allowed the developer to use libraries that use its on-chip MAC unit, that's why I am asking.)

5. The library function _SetPixel end with the line


Code:
ld   (hl),0                      ; get the actual pixel


It stores the value 00h to the address specificed by the HL register, if I understand the eZ80 assembly correctly. Shouldn't it be storing the value specified by the global color index instead?

Or ... wait ... that's self-modifying code and the 00h is replaced with a different value by _SetColor, right?


Code:
Color_SMC_1 =$+1




Well, that's it for now. I am looking forward to any answers.
1. In the case of the eZ80 calcs, no technical information has actually been released. However, much of ti84pce.inc is based on modified versions of the z80 calc include file that was included in an SDK released by TI a long time ago, and of course lots of reverse engineering.
2. gfx_SwapDraw is meant to be used after drawing everything to the back buffer, so it does a double-buffered swap during vsync. gfx_BlitBuffer is a slower buffer copy, so it's only really useful if you want to change something afterwards (maybe you are blitting a background that you want to draw over) so it wouldn't make sense to wait for vsync. The OS sets the LCD refresh rate to slightly over 63.5Hz, but that can be easily changed.
3. If you disable interrupts, you can use whatever you want, but TIOS uses the OS timer and timer 3 for usb and keypad scanning among other things.
4. As far as we can tell, the calc's eZ80 is a custom fab (especially considering the recent im 2 change, and various other strange behavior) so as far as we know, none of the "on-chip peripherals" have any reason to exist on the calc.
5. Correct, the libraries are full of self modifying code.
I think I found the answer to to 4) ... and it's "No". (bummer)

IN/OUT instructions are prohibited, and since the MACC, if present, uses ports 0xE0 to 0xED, it cannot be accessed by user programs.

http://wikiti.brandonw.net/index.php?title=Category:84PCE:General_Hardware_Information
There are a plethora of ways around that restriction, however even if you were to check, ports 0xE0 through 0xED all appear to read as zero and ignore writes, just like all the ports in the 0x3F to 0xFF range, and in particular, even the ports before 0x3F have a completely unrelated use to what is in the eZ80??? docs.
jacobly wrote:
There are a plethora of ways around that restriction, however even if you were to check, ports 0xE0 through 0xED all appear to read as zero and ignore writes, just like all the ports in the 0x3F to 0xFF range, and in particular, even the ports before 0x3F have a completely unrelated use to what is in the eZ80??? docs.


So the actual eZ80190 data sheet and the eZ80 CPU user manual are in fact just suggestions on how some things inside the TI84+CEs CPU may or may not work. Sad Sounds frustrating.

Even more reason to expect TI to release proper, factual, useful documentation. Which they haven't done yet.
Well, if you bought an eZ80XXX from Zilog it would definitely have those things, but TI probably bought the design to incorporate into their own ASIC so they would have no reason to include the unused on-chip peripherals.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement