technoblogy / ulisp-tdeck

A version of uLisp to convert the LilyGO T-Deck into a self-contained handheld Lisp computer.
15 stars 2 forks source link

Screen Library Confusion #2

Closed hasn0life closed 10 months ago

hasn0life commented 10 months ago

So in trying to run this new version, I figured out that: a) the Arduino_GFX_Library is no longer needed, so you can remove that #include but more importantly b) the TFT_eSPI.h library has to be the one that comes from the t-deck github. If you download the one from the original github it doesn't seem to work. Please document that cause it's not obvious and has caused me some confusion.

technoblogy commented 10 months ago

I didn't encounter this problem, presumably because I didn't have the original TFT_eSPI.h library in my libraries folder.

If you do, how do you make sure it picks up the correct one when compiling?

hasn0life commented 10 months ago

So I didn't even know the t-deck came with its own version (if I did I wouldn't have used the arduino_gfx library in the first place), I just thought I had to install the original one. While I cloned the t-deck repo, unless I move the libraries in the lib folder out into my Arduino libraries folder Arduino doesn't see it. Or maybe I'm missing something else about how this works. Either way I feel like it should be documented that the t-deck github has its own version of the TFT_eSPI.h library and that's what should be used.

incanus commented 10 months ago

+1 to this problem and solution. Just got my T-Deck today and trying this with these versions has problems differing from the setup instructions:

I get a missing TFT_eSPI.h and the normal TFT_eSPI has problems with the builtin LED being redeclared. Putting the T-Deck GitHub TFT_eSPI library in my Arduino libraries folder allows uLisp to build and install.

hasn0life commented 10 months ago

To be clear, what I suspect happened is that @technoblogy had the t-deck repo already downloaded, so when nanomonkey made his changes he didn't notice that the screen library changed cause it was working for him. But if a newcomer follows the instructions from scratch it doesn't tell them to download the t-deck repo so they'll run into this issue.

technoblogy commented 10 months ago

Thanks - I understand now. I'll check and update the instructions.

technoblogy commented 10 months ago

I've been investigating this in a bit more detail, and planned to say in the instructions that you can either install the copy of the TFT_eSPI library from the lib folder in the LilyGO T-Deck repository on GitHub at:

https://github.com/Xinyuan-LilyGO/T-Deck/tree/master/lib

or install the TFT_eSPI library from the Arduino IDE Library Manager by searching for TFT_eSPI and selecting the one by Bodmer, or downloading the latest one from Bodmer's repository:

https://github.com/Bodmer/TFT_eSPI

However, I can only get the uLisp firmware to work correctly using the older one in the T-Deck repository, which is version 2.5.22, but not with the latest one on GitHub, which is version 2.5.31. With the latest one the screen doesn't work.

I don't like to rely on a particular older version of a library. Can anyone work out what's going on?

hasn0life commented 10 months ago

The library in the t-deck repo is a custom fork to some degree, I'm not sure what the differences are but this file is something that's missing from the Bodmer repo.

It might be ok to rely on the custom repo for now and maybe see if Bodmer can support the t-deck in the meantime?

incanus commented 10 months ago

The file that @hasn0life mentions does seem to be related, as the only thing of significance that jumps out to me in a relatively quick scan of [the full diff]() is the removal of the TFT_MISO, TFT_MOSI, and TFT_SCLK definitions in User_Setup.h (here), which that file seems to supplement.

technoblogy commented 10 months ago

Thanks - that explains why I couldn't get the Bodmer repo to work.

technoblogy commented 10 months ago

I've updated the instructions to clarify this - thanks for tracking down what the problem was.