I’ve got temperature management of the MPU6050 working using my protopi.
Circuitry is identical to that shown previously:
Load is a 50Ω SMD resistor. The MOSFET is a BS170, and the 100k is just one I had knocking around from a project 15 years ago (more in that in a few weeks).
Here’s the physical build with the 50Ω resistor attached to the MPU6050 with thermal tape and the red and black wires connecting it back to MOSFET.
Here’s the code.
This has worked pretty well but with a few compromises:
- I had to use a 50Ω resistor as the next lowest in the series was 10Ω; that limits the current, and hence heating effect of the resistor
- Probably as a result, the system couldn’t attain the desired temperature of 40°C – lowering the target to 30°C worked as the graph shows.
- It took five minutes for the temperature to stabilize at 30°C, partly because of the lower heating power of the 50Ω resistor, but also I suspect because the breakout and breadboard were sinking heat away from the MPU-6050.
Still proof of concept was successful. There were various changes I had to make to the exiting PID code that I’ll have to merge in with qc.py carefully, but hopefully that means I can calibrate her at a constant temperature.