I'm working on a presentation box for the TI-84+. This box essentially will allow you to output screenshots (and possibly video) of your TI-84+ to a TV over either HDMI or composite.

How does it work? The box is made using a Raspberry Pi. Three of the Pi's GPIO pins are connected to a 2.5mm TRS jack. When you want to link your calculator to the Pi, you simply put one end of the link cable into the jack and the other end into the calculator. The calculator can then send the data of its current screen over the link and the Pi will interpret it and draw it to the screen.

Currently, in order to send a screenshot, you need to run the command "Asm(SCRNOUT". Here is a TI-BASIC program that runs two simple tests:
Code:
ClrHome
Disp "Test 1..."
Asm(prgmSCRNOUT
100:prgmWAIT
Disp "Hello, World!"
Asm(prgmSCRNOUT
250:prgmWAIT
Disp "Test 2..."
Asm(prgmSCRNOUT
100:prgmWAIT
"X²→Y₁
Asm(prgmSCRNOUT
250:prgmWAIT
Disp "Done!"
Asm(prgmSCRNOUT

As you can see, it runs two tests and sends new screenshots each time.
Here is a video of it in action running on a CRT:


The operating system on the Pi is just Raspbian that boots to an application written in C using GTK+ and wiringPi. The TI-84+'s side is written in Z80 Assembly (currently using Mimas as the assembler). The image it outputs is 480i over composite or 480p over HDMI. If you have a good connection to the Pi, you shouldn't notice any errors in the image, but if you do get one, it will correct itself with one or two more screenshots.

Here's the Pi's setup, it's very simple:All it is is a 2.5mm TRS jack that I soldered three wires to and those wires are connected to the Pi's GPIO pins using female-female wires. When you want to link the calculator to it, you plug the link cable into the calculator and the other end into the Pi.

I want to eventually have this capable of running in the background using hardware interrupts to allow continuous screen data to be transmitted for full video.

I may also consider adding support for the TI-84+CSE, I won't even attempt video support for the CSE as there's too much data in a single screen, but at least screenshots I would do (the presentation box could automatically detect what calculator is connected to it).

I do not plan to add support for the TI-84+CE since there's no link port, I could make it transfer the images over the TI-Innovator Hub, but I seem to be one of the few people who actually bought one, and it'd also be ridiculously slow.

This is designed to be very easy to setup and use. When it's done, you will just be able to flash a very small image to the Pi's SD card, hook up the 2.5mm jack like I showed, and it should be good to go. I'm also thinking of adding a physical button to switch between composite and HDMI.
I don't have much to say other than this is really cool!
Why no use 240p? Since the screen is small enough? As for errors you can probably implement some basic error correction Smile
Alex wrote:
I don't have much to say other than this is really cool!

Thank you! ^-^

c4ooo wrote:
Why no use 240p? Since the screen is small enough?

240p would work unless I implement support for the TI-84+CSE then it would not work. The TI-84+CSE has a 240p screen, meaning it'd fill up the entire display resolution, and if you displayed it on a CRT, would not fit in the display (since CRTs overscan a little bit). By using a 480i resolution, I have extra space to fit a white border around everything so it's not noticeable.

Quote:
As for errors you can probably implement some basic error correction Smile

Probably, I'm still working on that. I do have basic error correction as I mentioned, if the Pi messes up it will correct itself in 1-2 frames. It's challenging because I don't want to sacrifice speed, I'm trying to make the process as fast as possible.
This is absolutely incredible!

Forgive me if I didn't read close enough, but is it only possible to send the screen data to the monitor while inside the ti-basic program? Or is there some way to make the program run in the background?
I'd love to get my hands on this for my Pi, were you to add CE compatibility. Do you think you'll add CE compatibility?
I'd be really neat if you could run it at 4K! I purposefully made it that small

Also, it be cool if instead of sending out screenshots every so often, it would be a fluid recording!
Michael2_3B wrote:
This is absolutely incredible!

Thank you. ^-^

Quote:
Forgive me if I didn't read close enough, but is it only possible to send the screen data to the monitor while inside the ti-basic program? Or is there some way to make the program run in the background?

"I want to eventually have this capable of running in the background using hardware interrupts to allow continuous screen data to be transmitted for full video."

CalcMeister wrote:
I'd love to get my hands on this for my Pi, were you to add CE compatibility. Do you think you'll add CE compatibility?

"I do not plan to add support for the TI-84+CE since there's no link port"

TheLastMillennial wrote:
I'd be really neat if you could run it at 4K!

Even over HDMI it is not HD, it is a 480p signal, but most HDMI TVs will accept a 480p signal over HDMI, and I think many 4K TVs will as well. The image is in a 640x480 resolution (either 480p over HDMI or 480i over composite). If your 4K TV supports 480p images over HDMI, it should display.

Quote:
Also, it be cool if instead of sending out screenshots every so often, it would be a fluid recording!

Yeah I'm working on that.
Progress update: I've got video streaming to work... sort of. It's pretty slow and buggy. It has a frame rate of like 0.125 frames per second (yes, that is ~8 seconds for each frame), and the frames sometimes get noise in them. Also, for some reason, using the graph screen crashes the calculator, and using the program button stops the stream.

Here's an example of me streaming video so far. Since I'm using composite video, I can actually capture this on my capture card.



As you can see, the frame rate is reaaaally slow so far. It can take over 10 seconds to output a single frame. Also, occasionally the images would have noise in them. Not all the distortions were noise, tho, if I am scrolling the image while it's trying to read it, it will come out a little distorted. If the frame rate was faster, that wouldn't be an issue.

I'm working on speeding up the framerate and working on other bugs I mentioned before.

It works by installing a hardware interrupt inside of appBackupScreen that will output the video through the link port when called. It doesn't output the entire screen at once, though, that would slow down the calculator way too much. It just outputs 2 bytes at a time.
I tried pushing the calculator a bit harder and got it to update the image at about 3 seconds per frame. The calculator slows to a crawl, though.



I will see if I can optimize things to get this to work better. I would like to hit at least 1 frame per second.
This is a very impressive project!

What is your biggest throughput bottleneck? Is it sending the image data? Are you employing any kind of calc-side image compression etc?
Adding on to what tr1p1ea said, perhaps you could post some of your code that's bottlenecking your program. I'm sure that the community can find a few optimizations and suggestions that may elude you. Smile
  
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