# Extremal hotend temperature noise

**URL:** <https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064>\
**Category:** General Discussion\
**Created:** [February 12, 2024, 2:46pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064 "2024-02-12T14:46:14Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 2:46pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/1 "2024-02-12T14:46:14Z")

</div>

### Basic Information:

Printer Model: Hbot  
 MCU / Printerboard:MKS Eagle  
[klippy (2).log](https://klipper.discourse.group/uploads/short-url/hvFRjQ5hs2Bami8UBV4IgH9cM9u.log) (1.4 MB)

`klippy.log`

_Fill out above information and_ **_in all cases attach your_ `klippy.log` _file_** (use zip to compress it, if too big). _Pasting your_ `printer.cfg` _is **not** needed_  
_ **Be sure to check our “Knowledge Base” Category first. Most relevant items, e.g. error messages, are covered there** _

### Describe your issue:

When printer idle temperature become stable.  
After print start it become very unstable.  
If i set up small smooth time (1 second or less) it will turn off with min\_extrude\_temp.  
And it seems it take wrong readings without any smoothing  
I find similar problem [Temperature not remaining stable for a few seconds · Issue #842 · Klipper3d/klipper · GitHub](https://github.com/Klipper3d/klipper/issues/842) but i dont know how use it with my mcu  
First i think that sensor is bad and setup marlin - temperature is stable with it.

…

---

<div class="post-metadata">

**Author:** ![EddyMI3D](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/eddymi3d/32/1981_2.png) [@EddyMI3D](https://klipper.discourse.group/u/EddyMI3D)\
**Post date:** [February 12, 2024, 3:35pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/2 "2024-02-12T15:35:02Z")

</div>

Hello @pterodaktil !

What happened to the klippy.log?

The printer.cfg is missing.

Did you delete it?

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 3:40pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/3 "2024-02-12T15:40:53Z")

</div>

I am newable here so it was my mistake - log was very big. let me take new one  
[klippy (3).log](https://klipper.discourse.group/uploads/short-url/geO2crguwZERrQ9F3BpmPB8WaNH.log) (176.4 KB)  
In this log i just set temperature and after it a just move had.  
When priner is idle PID works exelent, but when head begin move - all become very ugly.

 ![Screenshot_1](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/b/b53d6df9ec1b54f584bfa537260082980d620f87.png)  
If i turn off smoothing it can fall temperature for more then 100C

---

<div class="post-metadata">

**Author:** ![mykepredko](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/mykepredko/32/2085_2.png) [@mykepredko](https://klipper.discourse.group/u/mykepredko)\
**Post date:** [February 12, 2024, 4:05pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/4 "2024-02-12T16:05:53Z")

</div>

What kind of temperature sensors are you using? (Thermistor: NTC/PTC or Thermocouple)

If you’re getting results like that when the printer is motion, I would suggest you start with looking at the output of your power supply followed by wiring.

---

<div class="post-metadata">

**Author:** ![EddyMI3D](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/eddymi3d/32/1981_2.png) [@EddyMI3D](https://klipper.discourse.group/u/EddyMI3D)\
**Post date:** [February 12, 2024, 4:07pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/5 "2024-02-12T16:07:36Z")

</div>

You may also check all connectors that go to the hotend.  
It may be a broken cable too.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 4:15pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/6 "2024-02-12T16:15:02Z")

</div>

I plug termistor directly to mcu - problem still here.  
If i turn off smoothing it can fall for 100 Degrees with termistor Trianglelab T-D500  
If i plug PT1000 - temperature sensor can set for few thousends degrees  
If i turn off smoothing it seems like this.  
temperature fall for one report and next is ok  
But pid controller recive wrong data and make it unstable

 ![Screenshot_3](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/3/315d846cdb98ea199e9a7fdc99a1923167dd68e8.png)

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [February 12, 2024, 4:18pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/7 "2024-02-12T16:18:07Z")

</div>

The drop you are showing in the screenshot directly above is indicative of a defect in the temperature measurement.  
According to the laws in our part of the universe, no temperature can drop or rise in such a split second.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 4:30pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/8 "2024-02-12T16:30:11Z")

</div>

I understand it  
in logs without smoothing it seems like this

```auto
Stats 9141.3: gcodein=0 mcu: mcu_awake=0.001 mcu_task_avg=0.000005 mcu_task_stddev=0.000004 bytes_write=15283 bytes_read=27888 bytes_retransmit=9 bytes_invalid=0 send_seq=907 receive_seq=907 retransmit_seq=2 srtt=0.000 rttvar=0.000 rto=0.025 ready_bytes=0 upcoming_bytes=0 freq=168004107 heater_bed: target=0 temp=47.4 pwm=0.000 Host: temp=49.0 Mainboard: temp=36.3 sysload=0.64 cputime=387.481 memavail=5882796 print_time=82.282 buffer_time=0.000 print_stall=0 extruder: target=200 temp=200.9 pwm=0.188
Stats 9142.3: gcodein=0 mcu: mcu_awake=0.003 mcu_task_avg=0.000008 mcu_task_stddev=0.000009 bytes_write=16983 bytes_read=28273 bytes_retransmit=9 bytes_invalid=0 send_seq=938 receive_seq=938 retransmit_seq=2 srtt=0.000 rttvar=0.000 rto=0.025 ready_bytes=0 upcoming_bytes=0 freq=168004118 heater_bed: target=0 temp=46.8 pwm=0.000 Host: temp=49.0 Mainboard: temp=36.6 sysload=0.64 cputime=387.563 memavail=5881036 print_time=86.706 buffer_time=0.939 print_stall=0 extruder: target=200 temp=98.7 pwm=1.000
Stats 9143.3: gcodein=0 mcu: mcu_awake=0.003 mcu_task_avg=0.000008 mcu_task_stddev=0.000009 bytes_write=17350 bytes_read=28587 bytes_retransmit=9 bytes_invalid=0 send_seq=949 receive_seq=949 retransmit_seq=2 srtt=0.000 rttvar=0.000 rto=0.025 ready_bytes=0 upcoming_bytes=0 freq=168004119 heater_bed: target=0 temp=47.1 pwm=0.000 Host: temp=49.0 Mainboard: temp=36.4 sysload=0.75 cputime=387.583 memavail=5894468 print_time=86.706 buffer_time=0.000 print_stall=0 extruder: target=200 temp=200.9 pwm=0.179

```

200,9- 98.7 - 200.9

I think good solution is - outlier or median filter. when it take readings

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [February 12, 2024, 4:37pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/9 "2024-02-12T16:37:04Z")

</div>

> [@pterodaktil](#):
>
> I think good solution is - outlier or median filter. when it take readings

Uhm…no.  
A proper solution is to use good quality temperature sensors that a FREE of defects.  
Again, such sharp drops usually mean that you have a HARDWARE defect.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 4:43pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/10 "2024-02-12T16:43:11Z")

</div>

As i see in /klipper/klippy/extras/adc\_temperature.py  
it take 8 samples with 0.001 second interval and take average  
I think that it show something like this  
200-200-200-0-0-200-200-200  
And in this case it become 150

But if we will take median it will be 200

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [February 12, 2024, 5:17pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/11 "2024-02-12T17:17:56Z")

</div>

> [@pterodaktil](#):
>
> And in this case it become 150
> 
> But if we will take median it will be 200

This is probably the reason why dinosaurs are extinct…

---

<div class="post-metadata">

**Author:** ![EddyMI3D](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/eddymi3d/32/1981_2.png) [@EddyMI3D](https://klipper.discourse.group/u/EddyMI3D)\
**Post date:** [February 12, 2024, 5:37pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/12 "2024-02-12T17:37:34Z")

</div>

Yapp.

Fixing hardware issues by software never was/is/will be a good idea

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 6:01pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/13 "2024-02-12T18:01:16Z")

</div>

I observe a relationship between speed and bursts.  
If you set the speed to 100 instead of 200, the splashes disappear.  
What do I need to change?

PS  
Can we softly limit the power on engines?  
Here it seems to me that the problem is the derivative of power with respect to time. The iron cannot cope with the increasing load and a drawdown occurs at the reference voltage of the thermocouple.

---

<div class="post-metadata">

**Author:** ![mykepredko](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/mykepredko/32/2085_2.png) [@mykepredko](https://klipper.discourse.group/u/mykepredko)\
**Post date:** [February 12, 2024, 6:35pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/14 "2024-02-12T18:35:24Z")

</div>

Your wiring.

You have a hardware problem, most likely your wires have started breaking due to mechanical fatigue.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 6:38pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/15 "2024-02-12T18:38:49Z")

</div>

I checked the wiring. I don’t see any problems.  
With the motors turned off and the head moving manually  
no problem.  
Only at high speeds when the engines are moving.

---

<div class="post-metadata">

**Author:** ![mykepredko](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/mykepredko/32/2085_2.png) [@mykepredko](https://klipper.discourse.group/u/mykepredko)\
**Post date:** [February 12, 2024, 6:41pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/16 "2024-02-12T18:41:24Z")

</div>

It’s most likely internal and not visible.

Try flexing the wires as much as possible.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 7:13pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/17 "2024-02-12T19:13:34Z")

</div>

I checked using the following method: with the motors turned off, I moved my head as sharply as possible with my hands. There are no drawdowns.  
When moving the head at low speeds with motors (100mm/s), there are also no drawdowns. Drawdowns occur when moving with motors at speeds above 150 mm/s

---

<div class="post-metadata">

**Author:** ![EddyMI3D](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/eddymi3d/32/1981_2.png) [@EddyMI3D](https://klipper.discourse.group/u/EddyMI3D)\
**Post date:** [February 12, 2024, 7:37pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/18 "2024-02-12T19:37:45Z")

</div>

What @mykepredko meant is:

- Grab the wire harness at the point where it enters the hotend assembly and bend it.
- The same at the other end of the wire harness.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 7:44pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/19 "2024-02-12T19:44:32Z")

</div>

I tried connecting the thermocouple with a separate wire. The result is the same.  
I tried moving my head with my hands when the hotend was hot - no splashes.  
Splashes occur only with rapid movements of the motors.

---

<div class="post-metadata">

**Author:** ![pterodaktil](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@pterodaktil](https://klipper.discourse.group/u/pterodaktil)\
**Post date:** [February 12, 2024, 7:46pm UTC](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064/20 "2024-02-12T19:46:40Z")

</div>

And one more strange thing - installed Marlin (native firmware  
for the printer).  
I set the PID parameters, selected manually and everything was according to the textbook on automatic control theory.

 ![image](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/7/74cf7fed0c27089e9de35f64ad8f1699bf1cabb7.png)  
And head movements do not affect temperature readings

[Next page](https://klipper.discourse.group/t/extremal-hotend-temperature-noise/14064.md?page=2)
