I am sorry for nubby question....
i found default menu in klipper/klippy/extras/display/menu.cfg
how i can enable it ?
Thanks!
It's enabled by default.
Simply provide the encoder and click pins in your configuration file.
Here is an example for a "RepRapDiscount 2004 Smart Controller" connected to a RAMPS (compatible) board:
https://github.com/KevinOConnor/klipper/blob/170b9678fba2749063023008f51ebdff7e0e0759/config/printer-anycubic-kossel-2016.cfg#L99
Here is an explanation:
https://github.com/KevinOConnor/klipper/blob/170b9678fba2749063023008f51ebdff7e0e0759/config/example-extras.cfg#L820
It's enabled by default.
Simply provide the encoder and click pins in your configuration file.
Here is an example for a "RepRapDiscount 2004 Smart Controller" connected to a RAMPS (compatible) board:
klipper/config/printer-anycubic-kossel-2016.cfgLine 99 in 170b967
encoder_pins: ^ar31, ^ar33
Here is an explanation:
klipper/config/example-extras.cfgLine 820 in 170b967
#encoder_pins:
Thanks man!
one more questions:
how i can disable few items on default menu ?
how i can add personal items to menu?
i need create new own menu? or have simply patch?
To remove items from the default menu you have to delete them from menu.cfg. Although re-defining them as empty in printer.cfg may also work - I am not sure, see here https://github.com/KevinOConnor/klipper/pull/500#issuecomment-412507818
Add your custom menus in printer.cfg.
Documentation:
https://github.com/KevinOConnor/klipper/blob/master/config/example-menu.cfg
An example:
https://github.com/KevinOConnor/klipper/issues/596#issuecomment-417929870
I don't recommend to make changes in the default menu.cfg
Next time you update Klipper's codebase your changes may be overwritten.
But you can easily overwrite default menu items.
Just redefine items with the same name in your printer config.
For example, to hide Octoprint menu just redefine it with enable: false
[menu __octoprint]
type: list
enable: false
name: OctoPrint
items:
.__pause
.__resume
.__abort
To add something to the menu, you need to redefine and include your item.
For example, to add your menu to main, just define your menu items and add it to
redefined __main
[menu __main]
type: list
name: Main Menu
items:
__tune
__octoprint
__sdcard
my_super_menu
__control
__temp
__filament
__prepare
__test
Or you can fully define your own menu structure and use it.
under display section use menu_root: your_menu_root_elem attribute.
You have to be careful when redefining menus and have to be prepared to adjust your changes according to default menu changes.
NB! Any change in menu system or in default menu.cfg may break your config!
thanks mcmatrix, i try now!
Most helpful comment
I don't recommend to make changes in the default menu.cfg
Next time you update Klipper's codebase your changes may be overwritten.
But you can easily overwrite default menu items.
Just redefine items with the same name in your printer config.
For example, to hide Octoprint menu just redefine it with
enable: falseTo add something to the menu, you need to redefine and include your item.
For example, to add your menu to main, just define your menu items and add it to
redefined
__mainOr you can fully define your own menu structure and use it.
under display section use
menu_root: your_menu_root_elemattribute.You have to be careful when redefining menus and have to be prepared to adjust your changes according to default menu changes.
NB! Any change in menu system or in default
menu.cfgmay break your config!