thelastWallE / OctoprintKlipperPlugin

A plugin for a better integration of Klipper into OctoPrint.
GNU Affero General Public License v3.0
65 stars 14 forks source link

Syntax Highlighting #48

Closed Sineos closed 3 years ago

Sineos commented 3 years ago

Version: 0.3.8rc4

The Syntax Highlighting is pretty cool and thanks for your mission to get it perfect šŸ‘

Some minor weirdness I noticed:

grafik

grafik

grafik

Don't get me wrong: Feel free to simply close this issue and tell me to get lost with this crap šŸ˜

thelastWallE commented 3 years ago

No all fine. Will be even better as i get more configurations from users.

I will look into it. Didn't see anything on my configuration. Seems like some values are missing on the highlighter that are allowed to put as values.

jalabaya commented 3 years ago

I realise this is closed, but I found this mismatched colour for AD597 under Octoprint (all latest public version). Unsure if that is fixed by the commit ... Thanks!

image

thelastWallE commented 3 years ago

you can test it with https://github.com/thelastWallE/OctoprintKlipperPlugin/archive/rc.zip this will have the latest commit on the rc branch in it. Iā€˜m not at the pc atm.

jalabaya commented 3 years ago

Thanks for that! According to the plugin manager I now run OctoKlipper (0.3.8rc8) after a restart of the server. Nice additions! The single purple letter is still there though. I am not a programmer, but let me know if you need more information (logs etc.)

(Not related to this issue, but rc8: It would be nice to be able to set a "default" zoom level for the config viewer. It now resets, for example after looking at the general settings.)

thelastWallE commented 3 years ago

try https://github.com/thelastWallE/OctoprintKlipperPlugin/archive/refs/heads/rc.zip

The zoom level should be saved if you click on the "Save" button on the OctoPrint settings dialog.

jalabaya commented 3 years ago

This fixed it. It fixed the purple one, but introduced a white letter in the beginning of the line (first "s"). Allso, can confirm the zoom level is saved after clicking that button.

image

thelastWallE commented 3 years ago

hmm i think you are actually on the version from yesterday. i had this letter in this version and was sure i fixed the AD597 before the version from yesterday. have you restarted after installing? take the link because the last commit is not on the last release.

jalabaya commented 3 years ago

Yes, I took your most recent link https://github.com/thelastWallE/OctoprintKlipperPlugin/archive/refs/heads/rc.zipand installed that, after that I was prompted to restart, which I did. I just did the procedure again (from the most recent link) and noticed in the log:

Found existing installation: OctoKlipper 0.3.8rc8
Uninstalling OctoKlipper-0.3.8rc8:
Successfully uninstalled OctoKlipper-0.3.8rc8
Successfully installed OctoKlipper-0.3.8rc8
Done!

So, I guess it remained the same?

thelastWallE commented 3 years ago

It's just reinstalling, because the version is the same. But the latest commits are in the zip.

jalabaya commented 3 years ago

Ok, well, after the restart (from your most recent link) it still shows the white "s".

thelastWallE commented 3 years ago

There is a new function in octoprint for the logs to download. Should be at http://"YOUR OCTOPRINT IP"/downloads/systeminfo.zip or over the system informaton dialog. The link for the button should be in the bottom right of octoprint. I suspect a cached file that is not updated correctly. Maybe try to CTRL+F5 the site in the browser to get the latest files from octoprint.

jalabaya commented 3 years ago

CTRL+F5 fixed it. Thank you for the help!

Sineos commented 3 years ago

Two more (latest RC branch) šŸ˜

grafik

grafik

thelastWallE commented 3 years ago

i need a bigger snip of the last image. you can also post the cfg here. So that i can investigate. On my cfg is it all looking fine. šŸ§

Sineos commented 3 years ago
Complete cfg ``` [stepper_x] step_pin: P2.2 dir_pin: P2.6 enable_pin: !P2.1 microsteps: 64 full_steps_per_rotation: 400 #rotation_distance: 40 rotation_distance: 39.95 endstop_pin: P1.29 position_endstop: 264 position_max: 264 homing_speed: 30 [tmc2209 stepper_x] uart_pin: P1.10 interpolate: true sense_resistor: 0.110 run_current: .955 hold_current: .5 stealthchop_threshold: 1000 #driver_TBL: 3 #driver_TOFF: 5 #driver_HSTRT: 2 #driver_HEND: 3 [stepper_y] step_pin: P0.19 #dir_pin: P0.20 dir_pin: !P0.20 enable_pin: !P2.8 #step_distance: .0015589154812192 #step_distance: .0015625 microsteps: 64 full_steps_per_rotation: 400 #rotation_distance: 40 rotation_distance: 40 endstop_pin: P1.28 position_endstop: 250 position_max: 250 #position_min: -11.2 homing_speed: 30 #[tmc2209 stepper_y] #uart_pin: P1.9 #interpolate: true #sense_resistor: 0.110 #run_current: 1.00 #hold_current: 0.500 #stealthchop_threshold: 1000 #driver_TBL: 3 #driver_TOFF: 5 #driver_HSTRT: 1 #driver_HEND: 3 [tmc5160 stepper_y] cs_pin: P1.9 spi_software_miso_pin: P0.5 spi_software_mosi_pin: P1.17 spi_software_sclk_pin: P0.4 interpolate: true sense_resistor: 0.110 run_current: 1.00 hold_current: 0.500 stealthchop_threshold: 9999 #driver_TBL: 3 #driver_TOFF: 5 #driver_HSTRT: 1 #driver_HEND: 3 [stepper_z] step_pin: P0.22 dir_pin: P2.11 enable_pin: !P0.21 #step_distance: .000057855 microsteps: 128 full_steps_per_rotation: 400 rotation_distance: 1.5 #endstop_pin: !P1.27 endstop_pin: probe:z_virtual_endstop #position_endstop: 0.0 position_min: -2.5 position_max: 300 [tmc2209 stepper_z] uart_pin: P1.8 interpolate: true sense_resistor: 0.110 run_current: 1.0 hold_current: 0.8 stealthchop_threshold: 0 #driver_TBL: 3 #driver_TOFF: 5 #driver_HSTRT: 1 #driver_HEND: 3 [extruder] step_pin: P2.13 dir_pin: P0.11 enable_pin: !P2.12 #step_distance: .0005956800000000 microsteps: 64 full_steps_per_rotation: 400 gear_ratio: 50:17 rotation_distance: 22.221342 nozzle_diameter: 0.400 filament_diameter: 1.750 heater_pin: P2.5 #sensor_type: EPCOS 100K B57560G104F #sensor_pin: P0.24 sensor_type: MAX31865 sensor_pin: P1.1 spi_speed: 4000000 spi_software_sclk_pin: P0.4 spi_software_mosi_pin: P1.17 spi_software_miso_pin: P0.5 rtd_nominal_r: 100 rtd_reference_r: 430 rtd_num_of_wires: 2 rtd_use_50Hz_filter: True #control: pid #pid_Kp: 19.388 #pid_Ki: 0.930 #pid_Kd: 101.060 min_temp: 0 max_temp: 275 min_extrude_temp: 0 max_extrude_only_distance: 500.0 [tmc2209 extruder] uart_pin: P1.4 interpolate: true sense_resistor: 0.110 run_current: 0.90 hold_current: 0.500 stealthchop_threshold: 0 #driver_TBL: 3 #driver_TOFF: 5 #driver_HSTRT: 2 #driver_HEND: 3 [verify_heater extruder] max_error: 140 check_gain_time: 40 [idle_timeout] timeout: 600 [heater_fan heatsink] pin: P2.4 heater: extruder heater_temp: 50.0 [heater_bed] heater_pin: P2.7 sensor_type: EPCOS 100K B57560G104F sensor_pin: P0.25 #control: pid #pid_Kp: 19.388 #pid_Ki: 0.930 #pid_Kd: 101.060 min_temp: 0 max_temp: 130 [fan] pin: P2.3 [mcu] serial: /dev/serial/by-id/usb-Klipper_lpc1769_0C70001625813AAF86E06B5CC32000F5-if00 [virtual_sdcard] path: ~/.octoprint/uploads/ [printer] kinematics: cartesian max_velocity: 300 #max_accel: 10000 #max_accel_to_decel: 10000 max_accel: 3500 max_accel_to_decel: 2500 max_z_velocity: 6 max_z_accel: 80 [input_shaper] shaper_freq_x: 60 shaper_type_x: ei shaper_freq_y: 81.4 shaper_type_y: 2hump_ei [mcu rpi] serial: /tmp/klipper_host_mcu [adxl345] cs_pin: rpi:None [resonance_tester] accel_chip: adxl345 probe_points: 117,123,20 [board_pins] aliases: # EXP1 header EXP1_1=P1.30, EXP1_3=P1.18, EXP1_5=P1.20, EXP1_7=P1.22, EXP1_9=, EXP1_2=P0.28, EXP1_4=P1.19, EXP1_6=P1.21, EXP1_8=P1.23, EXP1_10=<5V>, # EXP2 header EXP2_1=P0.17, EXP2_3=P3.26, EXP2_5=P3.25, EXP2_7=P1.31, EXP2_9=, EXP2_2=P0.15, EXP2_4=P0.16, EXP2_6=P0.18, EXP2_8=, EXP2_10= # Pins EXP2_1, EXP2_6, EXP2_2 are also MISO, MOSI, SCK of bus "ssp0" [display] lcd_type: emulated_st7920 spi_software_miso_pin: EXP1_6 spi_software_mosi_pin: EXP1_3 spi_software_sclk_pin: EXP1_5 en_pin: EXP1_4 #cs_pin: EXP1_4 #sclk_pin: EXP1_5 #sid_pin: EXP1_3 encoder_pins: ^EXP2_3, ^EXP2_5 click_pin: ^!EXP1_2 [output_pin beeper] pin: EXP1_1 #[filament_motion_sensor my_sensor] #detection_length: 7.0 #switch_pin: P1.26 #extruder: extruder #pause_on_runout: true #runout_gcode: # PAUSE_MACRO [endstop_phase stepper_z] #endstop_phase: 56 [force_move] enable_force_move: true [bed_screws] screw1: 24,200 #back, left screw1_name: back, left screw2: 194,200 #back, right screw2_name: back, right screw3: 194,30 # front, right screw3_name: front, right screw4: 30,24 # front, left screw4_name: front, left [screws_tilt_adjust] # Enter toolhead position, so that # the probe is over the screw screw1: 83,197 #back, left screw1_name: back, left screw2: 253,197 #back, right screw2_name: back, right screw3: 253,27 # front, right screw3_name: front, right screw4: 83,27 # front, left screw4_name: front, left horizontal_move_z: 10. speed: 50. screw_thread: CW-M4 [bltouch] #sensor_pin: P0.10 sensor_pin: ^P1.27 control_pin: P2.0 pin_move_time: 0.680 stow_on_each_sample: True probe_with_touch_mode: False #pin_up_reports_not_triggered: True #pin_up_touch_mode_reports_triggered: True x_offset: -45.4 y_offset: 11.2 #z_offset = 0 speed: 5.0 samples: 4 samples_result: median #sample_retract_dist: 8 #samples_result: samples_tolerance: 0.05 samples_tolerance_retries: 5 #[homing_override] #set_position_z:0 #gcode: # G1 Z10 F600 # G28 X Y # G1 X122 Y93 F6000 # G28 Z [safe_z_home] home_xy_position: 169,112 speed: 50 z_hop: 10 z_hop_speed: 5 [homing_heaters] steppers: stepper_z heaters: extruder [bed_mesh] speed: 50 horizontal_move_z: 5 #place probe over min/max #enter toolhead position corrected with #probe offsets mesh_min: 0,11.2 mesh_max: 218.6,245.4 probe_count: 9,9 #fade_start: 1.0 #fade_end: 0.0 algorithm: bicubic bicubic_tension: .2 [gcode_macro PRINT_START] gcode: G92 E0; Reset Extruder G1 E-15.0 F3600; retract filament G4 P120000; Dwell to let heatbed soak G28; Home all axes G1 X0.1 Y30 Z0.3 F5000.0; Move to start position G1 E15.0 F3600; unretract filament G92 E0; Reset Extruder G1 X0.1 Y200.0 Z0.3 F1500.0 E15; Draw the first line G1 X0.4 Y200.0 Z0.3 F5000.0; Move to side a little G1 X0.4 Y30 Z0.3 F1500.0 E30; Draw the second line G92 E0; Reset Extruder G1 Z1.0 F1500; Move Z Axis up little to prevent scratching of Heat Bed G4 P5000 [gcode_macro PRINT_END] gcode: M400; wait for buffer to clear G92 E0; zero the extruder G1 E-10.0 F3600; retract filament G91; relative positioning TURN_OFF_HEATERS M107; turn off fan G1 Z15 F3000; move nozzle up 15mm G90; absolute positioning G28 X0 Y0; home x and y axis BED_MESH_CLEAR [pause_resume] [gcode_macro PARK_MACRO] default_parameter_X: 0 default_parameter_Y: 0 default_parameter_Z: 30 gcode: M117 PARKING.. G91 G1 E-3.14 F1500 G1 Z{Z} G90 G1 X{X} Y{Y} F3000 [gcode_macro UNLOAD] gcode: G91 G1 E5.0 F1200 G1 E3.0 F1600 G1 E-13.14 F7000 G1 E-540 F3000 G90 [gcode_macro M600] gcode: PAUSE_MACRO UNLOAD [gcode_macro PAUSE_MACRO] gcode: PAUSE PARK_MACRO [gcode_macro PURGE] gcode: M117 PURGING.. G91 G1 E45.0 F250 G90 [gcode_macro LOAD_FILAMENT] gcode: M117 LOADING... G91 G1 E25.0 F1000 G1 E435 F2500 G4 P900 G1 E45.0 F250 G90 [gcode_macro RESUME_MACRO] gcode: M117 RESUMING... RESUME [gcode_macro M900] gcode: {% if 'K' in params %} {% if 'E' in params %} SET_PRESSURE_ADVANCE EXTRUDER={E} ADVANCE={K} {% else %} SET_PRESSURE_ADVANCE ADVANCE={K} {% endif %} {% endif %} #*# <---------------------- SAVE_CONFIG ----------------------> #*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated. #*# #*# [bltouch] #*# z_offset = 1.6 #*# #*# [heater_bed] #*# control = pid #*# pid_kp = 57.136 #*# pid_ki = 2.396 #*# pid_kd = 340.673 #*# #*# [bed_mesh default] #*# version = 1 #*# points = #*# -0.072964, -0.060688, -0.059194, -0.047593, -0.040840, -0.041060, -0.047271, -0.061040, -0.092314 #*# -0.085913, -0.058345, -0.070269, -0.038511, -0.039551, -0.047095, -0.073491, -0.082324, -0.122139 #*# -0.086660, -0.076729, -0.064336, -0.048750, -0.037793, -0.047827, -0.058184, -0.074429, -0.103799 #*# -0.083599, -0.068013, -0.059092, -0.043125, -0.043374, -0.060352, -0.058975, -0.073403, -0.107036 #*# -0.073535, -0.063003, -0.054390, -0.030425, -0.049907, -0.057349, -0.043052, -0.062651, -0.095259 #*# -0.080596, -0.060396, -0.046963, -0.028784, -0.029121, -0.035669, -0.041265, -0.053013, -0.085576 #*# -0.074897, -0.067866, -0.060513, -0.041030, -0.039170, -0.027729, -0.032827, -0.055254, -0.071162 #*# -0.052295, -0.032783, -0.034028, -0.022617, -0.014751, -0.026968, -0.020874, -0.025811, -0.063662 #*# -0.034644, -0.007280, -0.006357, 0.027891, 0.027993, 0.012363, 0.009214, -0.018662, -0.044370 #*# tension = 0.2 #*# min_x = 0.0 #*# algo = bicubic #*# y_count = 9 #*# mesh_y_pps = 2 #*# min_y = 11.2 #*# x_count = 9 #*# max_y = 245.36 #*# mesh_x_pps = 2 #*# max_x = 218.56 #*# #*# [bed_mesh 60deg] #*# version = 1 #*# points = #*# 0.036142, 0.057789, 0.014713, 0.022128, 0.042143, -0.010401, -0.019025, -0.043600, -0.057701 #*# 0.099466, 0.075925, 0.081431, 0.063616, 0.060323, 0.015893, -0.001107, -0.027401, -0.040832 #*# 0.111047, 0.110872, 0.100689, 0.092197, 0.094542, 0.071380, 0.041153, 0.009003, -0.027328 #*# 0.137763, 0.132548, 0.124813, 0.128440, 0.123720, 0.129562, 0.095533, 0.083952, 0.052836 #*# 0.150160, 0.139774, 0.136379, 0.139846, 0.128775, 0.106953, 0.105875, 0.088555, 0.084680 #*# 0.172827, 0.161464, 0.154166, 0.159017, 0.152972, 0.144129, 0.132417, 0.115854, 0.103078 #*# 0.195902, 0.185384, 0.190279, 0.188662, 0.191415, 0.187205, 0.171603, 0.163154, 0.146387 #*# 0.227775, 0.229159, 0.229290, 0.228838, 0.231664, 0.230164, 0.220651, 0.208619, 0.195290 #*# 0.279678, 0.275119, 0.273342, 0.273516, 0.285025, 0.291828, 0.294522, 0.276809, 0.254069 #*# tension = 0.2 #*# min_x = -8.3 #*# algo = bicubic #*# y_count = 9 #*# mesh_y_pps = 2 #*# min_y = -1.3 #*# x_count = 9 #*# max_y = 243.58 #*# mesh_x_pps = 2 #*# max_x = 186.58 #*# #*# [extruder] #*# control = pid #*# pid_kp = 20.446 #*# pid_ki = 0.995 #*# pid_kd = 105.043 #*# #*# [bed_mesh 80deg] #*# version = 1 #*# points = #*# 0.005533, 0.013986, 0.043492, 0.055800, 0.033929, 0.067275, 0.081261, 0.076955, 0.050967 #*# -0.010059, -0.026732, -0.009577, -0.004964, 0.047244, 0.006964, 0.021841, 0.011767, 0.026338 #*# -0.023286, -0.028980, -0.015665, -0.057814, -0.012045, 0.001460, 0.023797, -0.018133, -0.005635 #*# -0.092518, -0.063421, -0.028148, -0.029506, -0.014308, -0.012395, -0.041317, -0.046938, -0.023608 #*# -0.036280, -0.079918, -0.045843, -0.033594, -0.078079, -0.058428, -0.051872, -0.057917, -0.112636 #*# -0.110417, -0.117352, -0.145996, -0.101058, -0.072867, -0.124140, -0.123907, -0.166100, -0.097146 #*# -0.108650, -0.125352, -0.135601, -0.052179, -0.080429, -0.134068, -0.096503, -0.107774, -0.165209 #*# -0.056749, -0.081656, -0.104519, -0.099263, -0.133762, -0.087247, -0.091437, -0.105263, -0.158493 #*# -0.004511, -0.050135, -0.078473, -0.111658, -0.071231, -0.109804, -0.037156, -0.127411, -0.177969 #*# tension = 0.2 #*# min_x = -8.3 #*# algo = bicubic #*# y_count = 9 #*# mesh_y_pps = 2 #*# min_y = -1.3 #*# x_count = 9 #*# max_y = 243.58 #*# mesh_x_pps = 2 #*# max_x = 186.58 #*# #*# [bed_mesh 100deg] #*# version = 1 #*# points = #*# -0.072964, -0.060688, -0.059194, -0.047593, -0.040840, -0.041060, -0.047271, -0.061040, -0.092314 #*# -0.085913, -0.058345, -0.070269, -0.038511, -0.039551, -0.047095, -0.073491, -0.082324, -0.122139 #*# -0.086660, -0.076729, -0.064336, -0.048750, -0.037793, -0.047827, -0.058184, -0.074429, -0.103799 #*# -0.083599, -0.068013, -0.059092, -0.043125, -0.043374, -0.060352, -0.058975, -0.073403, -0.107036 #*# -0.073535, -0.063003, -0.054390, -0.030425, -0.049907, -0.057349, -0.043052, -0.062651, -0.095259 #*# -0.080596, -0.060396, -0.046963, -0.028784, -0.029121, -0.035669, -0.041265, -0.053013, -0.085576 #*# -0.074897, -0.067866, -0.060513, -0.041030, -0.039170, -0.027729, -0.032827, -0.055254, -0.071162 #*# -0.052295, -0.032783, -0.034028, -0.022617, -0.014751, -0.026968, -0.020874, -0.025811, -0.063662 #*# -0.034644, -0.007280, -0.006357, 0.027891, 0.027993, 0.012363, 0.009214, -0.018662, -0.044370 #*# tension = 0.2 #*# min_x = 0.0 #*# algo = bicubic #*# y_count = 9 #*# mesh_y_pps = 2 #*# min_y = 11.2 #*# x_count = 9 #*# max_y = 245.36 #*# mesh_x_pps = 2 #*# max_x = 218.56 ```
thelastWallE commented 3 years ago

Ok can you try rc9? Should fix all left over problems. edit: The Lines like these are now just white:

#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
Sineos commented 3 years ago

Works nicely. Many thanks šŸ‘

jalabaya commented 3 years ago

Hello, found one more: image

thelastWallE commented 3 years ago

Sry for the late reply. I didn't see the issue because it is closed. I will add those gpio pins to the list. Seems like there is also more to add, because some are having hosts with other gpiochip numbers. https://github.com/KevinOConnor/klipper/pull/2935#