# Build a Thermal Camera with Tufty 2350 and MLX90640 project

**URL:** <https://forums.pimoroni.com/t/build-a-thermal-camera-with-tufty-2350-and-mlx90640-project/29100>\
**Category:** Projects\
**Created:** [September 21, 2026, 4:14pm UTC](https://forums.pimoroni.com/t/build-a-thermal-camera-with-tufty-2350-and-mlx90640-project/29100 "2026-09-21T16:14:42Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![tryingtoohard](https://avatars.discourse-cdn.com/v4/letter/t/0ea827/32.png) [@tryingtoohard](https://forums.pimoroni.com/u/tryingtoohard)\
**Post date:** [September 21, 2026, 4:14pm UTC](https://forums.pimoroni.com/t/build-a-thermal-camera-with-tufty-2350-and-mlx90640-project/29100/1 "2026-09-21T16:14:42Z")

</div>

Apologies if this has been reported elsewhere but, if it has, I couldn’t find it. I’ve been doing the Pimoroni project [Build a Thermal Camera with Tufty 2350 and MLX90640 - Pimoroni](https://learn.pimoroni.com/article/build-a-thermal-camera-with-tufty-2350) and I ran into some software errors at the end which prevented it from running. With the help of Claude I have modified a few lines of code and got it working successfully. Great project!

The error message reported was:

> Error!  
> File “badgeware/\__init_\_.py”, line 32, in launch  
> File "/system/apps/thermal\_camera/\__init_\_.py, line 19, in   
> File "/system/apps/thermal\_camera/mlx90640.py, line 120, in \__init_\_  
> File "/system/apps/thermal\_camera/mlx90640.py, line 339, in \_extract\_parameters  
> File "/system/apps/thermal\_camera/mlx90640.py, line 754, in \_extract\_deviating\_pixels  
> File "/system/apps/thermal\_camera/mlx90640.py, line 765, in \_unique\_list\_pairs  
> TypeError, ‘set’ object isn’t subscribable

I seem to have a dead pixel so maybe that helped trigger the errors but anyway, Claude suggested amending the `def _unique_list_pairs` block in mlx90640.py to be  
`def _unique_list_pairs(self, input_list):`  
` input_list = sorted(input_list)`  
` for i, list_value1 in enumerate(input_list):`  
` for list_value2 in input_list[i + 1:]:`  
` yield list_value1, list_value2`

I then found the dead pixel was reporting -273 degrees which compressed the useful pixel readings to a point of being unuseful. Claude suggested two fixes in ` __init__.py`

1. Straight after the `try/accept` block, insert this

2. The second fix goes inside `update()`, in the `try:` block. Add the extra second line:

Maybe Pimoroni could review this and see if tweaks to the Github code are worthwhile?

Thanks, great project.
