joakimtoe / klipperlcd Goto Github PK
View Code? Open in Web Editor NEWA simple LCD service that enables the Neptune 3 Pro LCD screen with Klipper
License: Apache License 2.0
A simple LCD service that enables the Neptune 3 Pro LCD screen with Klipper
License: Apache License 2.0
First of all thx a lot for that repo and that excellent instruction,
everything works fine except the thumbnail, its not displayed on the "printing" screen.
I work with mainsail and cura, both are up-to-date, i even tried the buddha gcode, that was showing up with the original firmware without klipper. I've followed the guide in your instruction but the thumbnail is only displayed in mainsail.
Also i've reinstalled your tft file for the screen but still no success, only the elegoo logo is displayed.
What am I missing?
btw, great idea with that console.
all in one the display makes sense again!
greez
Hey Joakim,
could you maybe add support for a multiple printer setup, like giving an option where one could choose between the different printers?
That would be great as it would allow to use this great solution as a one-for-all remote control so to say, also for non-Elegoo machines.
Right now we have to add the specific path for the printer in the PrinterData line here:
class KlipperLCD ():
def __init__(self):
...
LCD("/dev/ttyAMA0", callback=self.lcd_callback)
...
PrinterData('XXXXXX', URL=("127.0.0.1"), klippy_sock='/home/pi/printer_data/comms/klippy.sock')
Now if one is using a setup where multiple machines are connected to the host, then the default folder structure is:
~/printer_1_data/..
, ~/printer_2_data/..
, ~/printer_3_data/..
and so on (or instead of "printer_1" , "printer_2" etc one can also choose an indiviual name when setting this up using KIAUH).
The URL is the same (if all printers are connected to the same host), but each printer gets it's own port then, starting with 7125.
So for "printer_1" it would be URL:7125 , for "printer_2" it's URL:7126 , for "printer_3" it's URL:7127 and so on.
It would be really great if you could extend your solution to make it work - if you don't have a setup with multiple printers for testing, just let me know, I'll be happy to test it then for you! :)
TIA & all the best :)
The Neptune 3 Max does not have accel sensors which leads to the following errors:
Traceback (most recent call last):
File "/home/pi/KlipperLCD/main.py", line 224, in <module>
x = KlipperLCD()
File "/home/pi/KlipperLCD/main.py", line 26, in __init__
self.printer.init_Webservices()
File "/home/pi/KlipperLCD/printer.py", line 439, in init_Webservices
self.max_accel_to_decel = toolhead['max_accel_to_decel']
KeyError: 'max_accel_to_decel
A potential solution would be to set default values:
data = self.getREST('/printer/objects/query?toolhead')['result']['status']
toolhead = data['toolhead']
volume = toolhead['axis_maximum'] # [x,y,z,w]
self.MACHINE_SIZE = "{}x{}x{}".format(
int(volume[0]),
int(volume[1]),
int(volume[2])
)
self.X_MAX_POS = int(volume[0])
self.Y_MAX_POS = int(volume[1])
self.max_velocity = toolhead.get('max_velocity', 0.0) # Use a default value if the key is not present
self.max_accel = toolhead.get('max_accel', 0.0) # Use a default value if the key is not present
self.max_accel_to_decel = toolhead.get('max_accel_to_decel', 0.0) # Use a default value if the key is not present
self.square_corner_velocity = toolhead.get('square_corner_velocity', 0.0) # Use a default value if the key is not present
```
Idk if this logic is correct or not but thought I'd share the issue
When I start main.py I got this error and
Waiting for connect to /home/pi/printer_data/comms/klippy.sock
Unable to connect socket /home/pi/printer_data/comms/klippy.sock [2,ENOENT]
Unexpected data received: 0x1a
Unexpected data received: 0xff
Unexpected data received: 0xff
Unexpected data received: 0xff
I chech and I have klippy enable:
cat ~/printer_data/systemd/klipper.env
KLIPPER_ARGS="/home/ink/klipper/klippy/klippy.py /home/ink/printer_data/config/printer.cfg -l /home/ink/printer_data/logs/klippy.log -I /home/ink/printer_data/comms/klippy.serial -a /home/ink/printer_data/comms/klippy.sock"
Hi,
I have a problem when I try to run python3 main.py
.
I followed your installation guide and adjusted the paths (since I don't use a RPi) in both main.py
and KlipperLCD.service
to fit my setup:
main.py
class KlipperLCD ():
def __init__(self):
self.lcd = LCD("/dev/serial/by-path/pci-0000:00:10.0-usb-0:3:1.0-port0", callback=self.lcd_callback)
self.lcd.start()
self.printer = PrinterData('XXXXXX', URL=("127.0.0.1"), klippy_sock='/home/db/printer_1_data/comms/klippy.sock', callback=self.printer_callback)
KlipperLCD.service
[Unit]
Description=KlipperLCD Service
After=moonraker.service
[Service]
Type=simple
User=db
Restart=always
RestartSec=1
ExecStart=/bin/sh -c '/usr/bin/env python3 /home/db/KlipperLCD/main.py > /tmp/KlipperLCD.log 2>&1'
[Install]
WantedBy=multi-user.target
When executing python3 main.py
in ~/KlipperLCD it gives me the following error though:
Traceback (moste recent call last):
File "/home/db/KlipperLCD/main.py", line 8, in <module> from printer import PrinterData
File "/home/db/KlipperLCD/printer.py", line 7, in <module> import requests
ModuleNotFoundError: No module named 'requests'
Do you have an idea what's wrong?
TIA
In the klipper github commit 0105aa3, the name of parameter max_accel_to_decel changed to minimum_cruise_ratio. Loading the program with a newly updated firmware causes the screen to hang on "Waiting for Klipper" as it cannot find the max_accel_to_decel in it's dictionary. Simply changing every instance of the old name to the new name lets it pull the actual data it needs from klipper and fixes the issue.
For those using linux its as easy as:
sed -i 's/max_accel_to_decel/minimum_cruise_ratio/g' main.py lcd.py printer.py
within the KlipperLCD directory. Cheers.
My printer swears at the code from LCD
SET_LED LED=top_LEDs WHITE=0.5 SYNC=0 TRANSMIT=1
after accomplishment this code
cd KlipperLCD
sed -i 's/top_LEDs/LED_Light/g' main.py lcd.py printer.py
LEDs tune (on/off) do correctly
I am interested in this project, and would like to try extending it for the Twotrees SK1 printer. I just downloaded fresh Nextion Editor v1.65.1, and tried to open LCD_program.HMI. Unfortunately the editor states "Wrong Hmifile or Hmifile has been damaged". What editor shall I use for the screen layout editing?
Hi, when I try to flash 20240129.tft to my Neptune 3 Pro LCD, I get the following error:
Model does not match TJC4827X243_011C File Info ERROR!
The main chip on my LCD's board is labeled TJC4827X243_011_z05
I get the same error when I try to flash the latest Elegoo LCD firmware file, 3D38_20230520.tft.
I tried flashing while connected to the printer and also powered by the USB/TTY converter.
Did Elegoo use various controller chips in its LCD boards?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.