Setting chamber temp via PRESETS gives 'Malformed command'

I’ve set a preset for preheating ASA: nozzle 240, bed 100, chamber 40
If I click on PRESETS → ASA, this is displayed on the console:

Malformed command ‘SET_HEATER_TEMPERATURE HEATER=heater_generic heater_chamber TARGET=40’
SET_HEATER_TEMPERATURE HEATER=heater_generic heater_chamber TARGET=40
SET_HEATER_TEMPERATURE HEATER=heater_bed TARGET=100
SET_HEATER_TEMPERATURE HEATER=extruder TARGET=240

So Klipper was unable to set the chamber temperature…
However, if I select a temperature from the dropdown at the right side to the ‘heater chamber’ line, the command issued is:

SET_HEATER_TEMPERATURE HEATER=heater_chamber TARGET=40

…and this works fine!
So why not when I choose a preset?
It’s obvious that the preset method gives a wrong heater name “heater_generic heater_chamber” since the name is only “heater_chamber”

How to fix this? Is it a bug?
I’ve got no macro’s doing something with temperature…


Printer Model: Home build CoreXY
MCU / Printerboard: SKR 1.3
Klipper version: v0.11.0-275-g8ef0f7d7
Mainsail version: v2.7.1
Moonraker version: v0.8.0-139-g3d9052d7
klippy.log (82.3 KB)

Hello @wd73_NL !

Have you tried to setup the preset the same way as you did manually?

SET_HEATER_TEMPERATURE HEATER=heater_chamber TARGET=40

@EddyMI3D, I don’t know what you mean?
I’ve just setup a preset for ASA :


Can I alter the way the commands are formed for this preset manually?
I see in the screen shot, the wrong name “heater_generic heater_chamber” is displayed…

Ah right, I added this in the custom G-code section of the preset:

SET_HEATER_TEMPERATURE HEATER=heater_chamber TARGET=40

That works, and I’ve unchecked the chamber temperature in the preset…
So it’s a bug then really?
Not to be able to set the chamber temperature in a normal fashion?

My heater declaration btw:

[heater_generic heater_chamber]
heater_pin: P2.4
sensor_type: Generic 3950 # NTC 100K beta 3950
sensor_pin: P0.25
control: watermark
max_delta: 2.0
max_power: 1
min_temp: 0
max_temp: 60

No.

The macro name is:

[heater_generic heater_chamber]

heater_generic tells Klipper, that the macro is one for heaters.
heater_chamber is it’s name. So when the name occurs, Klipper knows that it is a heater macro.

Does
SET_HEATER_TEMPERATURE HEATER="heater_generic heater_chamber" TARGET=40
work? Note the "

No, that does not work. I get:

The value ‘heater_generic heater_chamber’ is not valid for HEATER

What DOES work is:

SET_HEATER_TEMPERATURE HEATER=heater_chamber TARGET=40

Also with quotes (both single and double) does work:

SET_HEATER_TEMPERATURE HEATER=“heater_chamber” TARGET=40

Just a visual recap:

Perhaps a different way to explain your error.

If I know a person whose name is Fredrick, I do not call him “person Fredrick”. I just call him Fredrick.

Now you have a heater_generic whose name is heater_chamber. Do not call it “heater_generic heater_chamber.” Just use the name heater_chamber. So your commande would be

SET_HEATER_TEMPERATURE HEATER=heater_chamber TARGET=40

2 Likes

Well, if I understood @wd73_NL correctly, then the issue is not about building the command manually.
It is about using the built-in function in the web interface, which seems to be issuing the wrong command.

If my understanding is correct, then this would be a bug in Mainsail and should be reported to GitHub - mainsail-crew/mainsail: Mainsail is the popular web interface for managing and controlling 3D printers with Klipper. (ping @meteyou)

2 Likes

Well, if I understood @wd73_NL correctly, then the issue is not about building the command manually.
It is about using the built-in function in the web interface, which seems to be issuing the wrong command.

That is exactly the point!
And I didn’t think of it as a Mainsail bug when I posted it here on the group, so that’s my bad. I will post the bug for the Mainsail crew.

So indeed a bu, but not a Klipper bug… can be closed now

Yep, After rereading the whole discussion, I too see that @wd73_NL was using the presets correctly. Sorry @wd73_NL for the misunderstanding.

yeah. this looks like a bug in Mainsail. Thx for opening a issue in the mainsail github repo (this is my todo list). I will check it asap.

@Sineos i don’t know whats wrong with my settings here, but i didn’t received a ping from you…

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.