Join us on Discord!
You can help CodeWalrus stay online by donating here.

DotStar/SPI library

Started by Ivoah, July 01, 2015, 04:17:57 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ivoah

I'm working on a super simple SPI library for the TI-8[34]\+( C?SE)? calculators. The goal is to be able to control some Adafruit DotStar individually addressable LEDs with my calculator. I have the basic SPI part done, and I've managed to bang out a "library" for controlling up to 256 LEDs from the linkport. Here's a picture of it running on my 84+ SE:


The code can be found here: https://github.com/Ivoah/z80DotStar

You might notice the two microcontrollers on the breadboard, don't worry, I didn't cheat ;) The one on the bottom is an Arduino Micro and is only being used for 5V, and the one on the top is an ESP8266 + FT232H breakout (uart/gpio/i2c/spi to USB) that just happen to be occupying the other half of the breadboard. You can see the edge of ESP8266 on the far left of the image. The spi.asm file is easily usable in another project, just #include it at the bottom of you code.
  • Calculators owned: TI-86 (now broken), TI SR-56, TI-Nspire CX CAS, TI-84+ SE, TI-84+ SE, TI-85, TI-73 Explorer VS, ViewScreen, TI-84+ CSE, TI-83+ SE

Dream of Omnimaga

Do you think you could display parts of the LCD content on a LED grid with this? O.O
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Ivoah

Quote from: DJ Omnimaga on July 01, 2015, 05:03:56 AM
Do you think you could display parts of the LCD content on a LED grid with this? O.O

Easily, if you had enough you could mirror the entire LCD, but that would require 320*240=76800 LEDs, and at $0.36 a pop, that'd be $27,648, not to mention the crazy power requirements and the fact that my program can only handle 256 LEDs. A feasible application for this would be light painting.
  • Calculators owned: TI-86 (now broken), TI SR-56, TI-Nspire CX CAS, TI-84+ SE, TI-84+ SE, TI-85, TI-73 Explorer VS, ViewScreen, TI-84+ CSE, TI-83+ SE

Dream of Omnimaga

Wait, don't you mean 96x64, since it's for the 84+? That said, it would still be pretty expensive. >.<
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

novenary

Oh nice. It can only handle one-way communications though but it's still possible to implement a half duplex system for it I guess.

Snektron

I was actually hinking of tha a while ago, controlling another LCD with a 84+.
You can probably do it with a few SIPO's :P
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


novenary

Mgos did that with an arduino actually. It was pretty neat.

Ivoah

Quote from: DJ Omnimaga on July 01, 2015, 05:14:19 AM
Wait, don't you mean 96x64, since it's for the 84+? That said, it would still be pretty expensive. >.<

Well, it will run on either, just a change of include file and header tokens. The latest version actually has a define for choosing target.
  • Calculators owned: TI-86 (now broken), TI SR-56, TI-Nspire CX CAS, TI-84+ SE, TI-84+ SE, TI-85, TI-73 Explorer VS, ViewScreen, TI-84+ CSE, TI-83+ SE

alexgt

That is awesome O.O!
Now I remake Nagoji 4x3 on Ti-84+ :P
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Dream of Omnimaga

Quote from: Ivoah on July 01, 2015, 09:20:54 PM
Quote from: DJ Omnimaga on July 01, 2015, 05:14:19 AM
Wait, don't you mean 96x64, since it's for the 84+? That said, it would still be pretty expensive. >.<

Well, it will run on either, just a change of include file and header tokens. The latest version actually has a define for choosing target.
Aah I see now. Thanks for the clarification :)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Ivoah

bump

I made this for the 4th of July and forgot to update the topic here


It's kind of hard to see, but the LEDs are cycling through red, white, and blue.
  • Calculators owned: TI-86 (now broken), TI SR-56, TI-Nspire CX CAS, TI-84+ SE, TI-84+ SE, TI-85, TI-73 Explorer VS, ViewScreen, TI-84+ CSE, TI-83+ SE

Dream of Omnimaga

I was expecting some fireworks :P, but glad that the calculator is safe. THis is cool, by the way :). Was it hard to control from the calc?
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Ivoah

Quote from: DJ Omnimaga on October 13, 2015, 06:29:02 AM
I was expecting some fireworks :P, but glad that the calculator is safe. THis is cool, by the way :). Was it hard to control from the calc?

Not really, it's just a static animation right now, but I'm trying to make a GUI using DCS. Here's what I have so far:
  • Calculators owned: TI-86 (now broken), TI SR-56, TI-Nspire CX CAS, TI-84+ SE, TI-84+ SE, TI-85, TI-73 Explorer VS, ViewScreen, TI-84+ CSE, TI-83+ SE

Dream of Omnimaga

Oh that would be nice for controlling, since some people earlier asked on IRC for an hardware schematic, meaning that they probably are interested in reproducing your hardware mod. :)
  • Calculators owned: TI-82 Advanced Edition Python TI-84+ TI-84+CSE TI-84+CE TI-84+CEP TI-86 TI-89T cfx-9940GT fx-7400G+ fx 1.0+ fx-9750G+ fx-9860G fx-CG10 HP 49g+ HP 39g+ HP 39gs (bricked) HP 39gII HP Prime G1 HP Prime G2 Sharp EL-9600C
  • Consoles, mobile devices and vintage computers owned: Huawei P30 Lite, Moto G 5G, Nintendo 64 (broken), Playstation, Wii U

Powered by EzPortal