Touchscreen UI for PID!?


Using these components (along with the PID circuit Ryan designed and the PWM AC dimmer) I plan to create a GUI to control the set point/mode of operation. So mission statement aside, this is how it will work:

  1. Get the Pi talking to the display, I’ve accomplished this previously, just gotta dig out the diagram of how I had it wired.
  2. Set the display to mirror the hdmi out
  3. Build a website that utilizes Python to establish a Serial connection between the Pi & the nano.
  4. Modify Ryan’s code to also utilize the established Serial connection on the arduino side
  5. Eat cake.

I’m still waiting for some of the components to arrive, and I’m down some female headers atm but once I get everything in, I will start plugging away at it.
I worked as a web developer a lifetime ago, so hopefully it’s like riding a bike.

There are javascript packages to talk to the serial ports, but I think most browsers have killed that permission. The solution I see often is having a small program (lile in python) to talk to the serial port, and then open a web socket that javascript can talk to.

You could also go full python and use flask to just handle all the buttons as post requests and then do all the serial in one program.

Sounds like a fun project.

1 Like

Also, the tft from bigtreetech is a screen and a microcontroller all rolled into one. And it just talks over the serial to the skr. I see you already have the hardware and you are looking at web. But refactoring the screen code to do this might be easier.

1 Like

Will that screen work with other boards? Or standalone? I have a rambo v1.4 but your idea sounds so much more self-contained. If I go my route I’ll have to fab a pcb after I get everything worked out.

It literally connects to the skr via Tx, Rx, 5V and Gnd. There is an optional reset button. Everything else is flexible.

The trouble then is the software, which is no joke. The btt firmware is very complicated because it tries to support a bunch of screens and dozens of languages. But after you deleted 95% of the code, you would have something to work with.

We tried connecting it to the rambo, but we couldn’t get it to work. The trouble is with enabling the second serial port and I would be very interested in someone figuring that out. I don’t have a rambo to try it out.

I have also connected to the screen from a uart to usb on the computer. I just send it things marlin would and it sends me gcode. This is how I tested the screen.

Very cool, definitely worth looking into

1 Like

Screen connection established!


I have to dig for my usb microsd card reader tomorrow so I can install raspian with a GUI, and we’re off to the races!

Octodash installs the ratpoison window manager, which is almost not a wm. It would be good for a display on an otherwise headless setup like this.

would it be able to display a browser? it looks text-based

1 Like

ok nvm, i saw a few more screenshots that showed linux apps running with an actual gui, i’m gonna try getting it installed and see if maybe i can have it boot straight into a browser instance with my web app running

1 Like

Progress report, day 2, hdmi successfully mirroring on spi bus:


You can see I am installing ratpoison wm to see if I can scrape together a barebones chromium kiosk without a lot of overhead, excellent suggestion!
Looking into flask and some node js options, I’m much more familiar with js than with Python, but I have been meaning to learn. Maybe I’ll end up doing both… we’ll see.

I think node.js apps can access the local serial ports. But javascript can’t access them on the machine running the browser (client side). I may be wrong.

i’m sure it will be the culmination of a few of my different skills that eventually gets the job done. it feels good to “stretch my legs” again, that’s what i love and hate about web coding, take a 6 month break from it and you come back to an entirely different landscape. i guess that’s true of other things too, but i’m metaphorically jet-lagged every time i have to bring myself back up to speed :stuck_out_tongue:

ok, as always i spent a considerable amount of time and effort trying to reinvent the wheel, instead of googling wheel. i found this just now, after trying a buncha different methods to boot into chromium:

1 Like

but of course it wont play nice with my screen for some reason :stuck_out_tongue:
this one looks better:

he uses the same screen i have, so whatever conflict the last thing had should be avoided here

Oh yeah. There is an image made by the same person that maintains the octopi image (and the tools that I use for v1pi) that is just a kiosk on a disk:

1 Like

yeah i found a number of different versions of something similar, fingers crossed i can get one to play nice with the lcd drivers, they broke the chilipie install for some reason, it worked fine, then i ran the install script for the lcd and it failed to start the x server or some gobbledegook i couldn’t quite make out, i have been out running errands since shortly after i found that 2nd one, but i have a good feeling, and if not i’ll try the one you just suggested.

1 Like

So I’m interested to see where all this goes because it seems to compact a lot of functionality into one place. I was wondering about some things. Now I’m no programmer, unless you count Basic on a C64 back in 80-something, so I just have some ideas, with no actual skills on implementing them.

  1. I know the BTT screens are powered by a 32 bit processor, how do these compare to the silicon on the Raspberry Pi?

  2. If they are similar, in processing power, memory, etc., is it possible to run octoprint, host sandify, and have it controlled via the TFT and via wifi, possibly connected via an esp8266, or similar, while also sending everything out the serial port to the attached control board?

Just wondering.

If you were going to use a pi 4, yes I believe you could install all of those things, in my setup I have a 3b+ with the v1pi image. I just had this hardware gathering dust in my workshop and thought it would be a neat learning experience that would end up being a really nifty mod for my machine. I do know that once I have achieved what I set out to do I may adjust the project’s trajectory.

And it looks like the zero is rocking a 1ghz vs the 120mhz on the btt tft