{"id":2032,"date":"2026-07-12T23:03:30","date_gmt":"2026-07-12T21:03:30","guid":{"rendered":"https:\/\/redero.fr\/?p=2032"},"modified":"2026-07-15T22:52:06","modified_gmt":"2026-07-15T20:52:06","slug":"apocalypse-nerding-2-openthedamnwindowcaller","status":"publish","type":"post","link":"https:\/\/redero.fr\/?p=2032&lang=en","title":{"rendered":"Apocalypse nerding #2: OpenTheWindowCaller"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Heatwaves are becoming increasingly difficult to manage, and I realized I needed a more precise way to measure the temperature in my apartment than my usual scale of \u00ab\u00a0how many dehydrated tears I cry at night.\u00a0\u00bb<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Time to engineer a thermal management system!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Hardware engineering (aka: shopping)<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A friend recommended some Zigbee temperature and humidity sensors from AliExpress. I didn&rsquo;t want to buy a Zigbee-to-BLE gateway, nor install any random smartphone app. All I really wanted was an alarm that would wake me up when it was time to open the windows during the night.<\/p>\n\n\n\n<figure data-wp-context=\"{&quot;galleryId&quot;:&quot;6a5fcf370323d&quot;}\" data-wp-interactive=\"core\/gallery\" class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-4 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf3706cdb&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf3706cdb\" class=\"wp-block-image size-large wp-duotone-unset-1 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"875\" height=\"754\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2004\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951984632947478452.jpg\" alt=\"\" class=\"wp-image-2004\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951984632947478452.jpg 875w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951984632947478452-300x259.jpg 300w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951984632947478452-768x662.jpg 768w\" sizes=\"auto, (max-width: 875px) 100vw, 875px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">~$20 Sonoff SNZB-02P Zigbee sensors. CR2477 battery powered. Stickers sold separately.<\/figcaption><\/figure>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf37072cc&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf37072cc\" class=\"wp-block-image size-large wp-duotone-unset-2 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"323\" height=\"356\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2262\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside.png\" alt=\"\" class=\"wp-image-2262\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside.png 323w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside-272x300.png 272w\" sizes=\"auto, (max-width: 323px) 100vw, 323px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">TI CC2530 and friends<\/figcaption><\/figure>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf3707da3&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf3707da3\" class=\"wp-block-image size-large wp-duotone-unset-3 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"323\" height=\"356\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2264\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside_2.png\" alt=\"\" class=\"wp-image-2264\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside_2.png 323w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/sensor_inside_2-272x300.png 272w\" sizes=\"auto, (max-width: 323px) 100vw, 323px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">Notice the PCB lump and compartment for the sensor IC<\/figcaption><\/figure>\n<\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The sensors are based on <a href=\"https:\/\/www.ti.com\/product\/CC2530\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">TI CC2530<\/a>, according to <a href=\"https:\/\/hackaday.io\/project\/187193-sonoff-snzb-02-diy\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">this teardown<\/a>, and complies with Zigbee standard, so it is possible to make a custom Zigbee-to-BLE gateway. The sensor chip is a Sensirion SHT40, the board has a kind of lump to keep the sensor away from electronics-generated heat, as seen in <a href=\"https:\/\/www.youtube.com\/watch?v=KJ1ZuVh4pLQ\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">this other teardown<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">While unsuccessfully trying to set up the build system for a Nordic Thingy:91, I remembered that I owned a board with nRF52, a buzzer, RGB LEDs and even its own thermal sensor, which was perfect for my application.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The board is called CoffeeCaller, I got mine at OSS2025 after harassing the board designer, and it is an <a href=\"https:\/\/github.com\/tiacsys\/ecad-coffeecaller\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">open-hardware<\/a> nRF52-based dev kit in the shape of a coffee cup (<a href=\"https:\/\/www.youtube.com\/watch?v=YgxnKGolpno\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">as presented here<\/a>).<\/p>\n\n\n\n<figure data-wp-context=\"{&quot;galleryId&quot;:&quot;6a5fcf3708648&quot;}\" data-wp-interactive=\"core\/gallery\" class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-6 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf37089de&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf37089de\" class=\"wp-block-image size-large wp-duotone-unset-5 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"629\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2005\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-1024x629.png\" alt=\"\" class=\"wp-image-2005\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-1024x629.png 1024w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-300x184.png 300w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-768x472.png 768w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-1536x944.png 1536w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/20260408112757_coffeecaller-nrf52840-3d-render-2048x1259.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">If only it was 4 or 6 layers \ud83d\ude1b<\/figcaption><\/figure>\n<\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">It was a good opportunity to try flashing the nRF52 with my $20 FTDI2232 board and OpenOCD, which turned out to work really well. The trick is to use a 270 \u03a9 resistor to hack two FTDI push-pull-only GPIOs into a tri-state one, because SWD requires a tri-state IO line. The complete hack is <a href=\"https:\/\/www.allaboutcircuits.com\/technical-articles\/getting-started-with-openocd-using-ft2232h-adapter-for-swd-debugging\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">detailed here<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I also occasionally use <a href=\"https:\/\/black-magic.org\/\">Black Magic Probe<\/a> on <a href=\"https:\/\/fr.aliexpress.com\/item\/1005008154652916.html\">STM32F103 eval kits<\/a> as cheap probes, but the nice thing with this FTDI is that you do not need to flash any firmware to it.<\/p>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf370908b&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf370908b\" class=\"wp-block-image size-large wp-duotone-unset-7 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"768\" height=\"1024\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/probe-768x1024.jpg\" alt=\"\" class=\"wp-image-2026\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/probe-768x1024.jpg 768w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/probe-225x300.jpg 225w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/probe.jpg 960w\" sizes=\"auto, (max-width: 768px) 100vw, 768px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Software engineering (aka: asking Claude)<\/h2>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full wp-duotone-default-filter\"><img loading=\"lazy\" decoding=\"async\" width=\"229\" height=\"158\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/BLE.png\" alt=\"\" class=\"wp-image-2340\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Once the hardware part was done, I asked my boyfriend for some Claude tokens to develop the firmware. It wasn&rsquo;t just laziness; I just could not have pulled off the Zigbee communication with the temperature sensors without it.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized wp-duotone-unset-8\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"696\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/tokens_parody.jpg\" alt=\"\" class=\"wp-image-2252\" style=\"width:460px;height:auto\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/tokens_parody.jpg 800w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/tokens_parody-300x261.jpg 300w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/tokens_parody-768x668.jpg 768w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Vibe coding is not the only dubious thing about this project. It turns out that the Nordic Zigbee stack, based on a proprietary blob named ZBOSS, is implemented in Nordic NCS v2.8.0 (Zephyr 3.7.99) and was removed from newer NCS releases.<\/p>\n\n\n\n<figure data-wp-context=\"{&quot;galleryId&quot;:&quot;6a5fcf3709477&quot;}\" data-wp-interactive=\"core\/gallery\" class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-11 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf37097a0&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf37097a0\" class=\"wp-block-image size-large wp-duotone-unset-9 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"768\" height=\"1024\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2001\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475046-768x1024.jpg\" alt=\"\" class=\"wp-image-2001\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475046-768x1024.jpg 768w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475046-225x300.jpg 225w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475046.jpg 960w\" sizes=\"auto, (max-width: 768px) 100vw, 768px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">Blue means the air is fresher outside than inside<\/figcaption><\/figure>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf3709ca9&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf3709ca9\" class=\"wp-block-image size-large wp-duotone-unset-10 wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"768\" height=\"1024\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2002\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475048-768x1024.jpg\" alt=\"\" class=\"wp-image-2002\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475048-768x1024.jpg 768w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475048-225x300.jpg 225w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5949710417699475048.jpg 960w\" sizes=\"auto, (max-width: 768px) 100vw, 768px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">Orange means the air is fresher inside than outside<\/figcaption><\/figure>\n\n\n\n<figure data-wp-context=\"{&quot;imageId&quot;:&quot;6a5fcf370a183&quot;}\" data-wp-interactive=\"core\/image\" data-wp-key=\"6a5fcf370a183\" class=\"wp-block-image size-large wp-duotone-dark-grayscale wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"473\" height=\"1024\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on--pointerdown=\"actions.preloadImage\" data-wp-on--pointerenter=\"actions.preloadImageWithDelay\" data-wp-on--pointerleave=\"actions.cancelPreload\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" data-id=\"2003\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951962217513160648-473x1024.jpg\" alt=\"\" class=\"wp-image-2003\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951962217513160648-473x1024.jpg 473w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951962217513160648-139x300.jpg 139w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/5951962217513160648.jpg 591w\" sizes=\"auto, (max-width: 473px) 100vw, 473px\" \/><button\n\t\t\tclass=\"lightbox-trigger\"\n\t\t\ttype=\"button\"\n\t\t\taria-haspopup=\"dialog\"\n\t\t\tdata-wp-bind--aria-label=\"state.thisImage.triggerButtonAriaLabel\"\n\t\t\tdata-wp-init=\"callbacks.initTriggerButton\"\n\t\t\tdata-wp-on--click=\"actions.showLightbox\"\n\t\t\tdata-wp-style--right=\"state.thisImage.buttonRight\"\n\t\t\tdata-wp-style--top=\"state.thisImage.buttonTop\"\n\t\t>\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewBox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\" \/>\n\t\t\t<\/svg>\n\t\t<\/button><figcaption class=\"wp-element-caption\">Who needs a pretty smartphone app when you have Nordic nRF Connect. #itworks<\/figcaption><\/figure>\n<\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The Zigbee and BLE communication was the hard part. The application itself is quite straighforward, it has:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>An alarm to warn when the outside temperature finally drops lower than inside,<\/li>\n\n\n\n<li>A button to disable said alarm,<\/li>\n\n\n\n<li>An LED changing color if the temperature is fresher outside than inside,<\/li>\n\n\n\n<li>A BLE Environment Sensing profile to read the temperature and humidity values from a smarphone<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">By chance, I have lots of heatwaves planned this summer to test my prototypes and refine its behaviour.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The project repository is here: <a href=\"https:\/\/github.com\/everedero\/CoffeeCaller\/tree\/temperature\/applications\/zigbee_temp\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">https:\/\/github.com\/everedero\/CoffeeCaller\/tree\/temperature\/applications\/zigbee_temp<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Then, with plenty of sleepless nights still ahead of me, I started wondering about the carbon footprint of the project.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full wp-duotone-unset-12\"><img loading=\"lazy\" decoding=\"async\" width=\"817\" height=\"606\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/compter_moutons.png\" alt=\"\" class=\"wp-image-2221\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/compter_moutons.png 817w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/compter_moutons-300x223.png 300w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/compter_moutons-768x570.png 768w\" sizes=\"auto, (max-width: 817px) 100vw, 817px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Babbling about Claude\u2019s carbon footprint <\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">I really wanted to know what the carbon footprint of developing this embedded application with an agentic LLM was.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">First I found a very nice-looking plugin: <a href=\"https:\/\/github.com\/gwittebolle\/claude-carbon\">https:\/\/github.com\/gwittebolle\/claude-carbon<\/a>, but I was told that installing Claude plugins was too much of a security risk. So instead I read the README and did a similar computation.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">First, we need some numbers, taken from a reseach paper here: <a href=\"https:\/\/arxiv.org\/abs\/2505.09598\">https:\/\/arxiv.org\/abs\/2505.09598<\/a><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td><strong>Model<\/strong><\/td><td><strong>Input (gCO2e\/Mtok)<\/strong><\/td><td><strong>Output (gCO2e\/Mtok)<\/strong><\/td><\/tr><tr><td>Sonnet<\/td><td>39<\/td><td>826<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Not all models are created equal so we apply a coefficient:<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td><strong>Model<\/strong><\/td><td><strong>Coefficient<\/strong><\/td><\/tr><tr><td>Fable<\/td><td>4<\/td><\/tr><tr><td>Opus<\/td><td>2<\/td><\/tr><tr><td>Sonnet<\/td><td>1<\/td><\/tr><tr><td>Haiku<\/td><td>0.5<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Also, agentic LLMs use caches to not recompute everything every time. It has cache-creation tokens that we count as inputs, and cache-read tokens that only cost a fraction of inputs (here we say 1\/10, I have no fancy paper to justify this, but people do 1\/8 or 1\/10).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The tokens per model and type can be retrieved in .claude in the local folder. I had Claude write a Python script to parse its data.<\/p>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>Token count details<\/summary>\n<pre class=\"wp-block-code has-small-font-size\"><code><code>\ninput_tokens: 153,754\noutput_tokens: 977,774\ncache_creation_input_tokens: 3,781,718\ncache_read_input_tokens: 105,842,653\ntotal tokens: 110,755,899<\/code>\n<code>by model:\n\nclaude-haiku-4-5-20251001:\ninput_tokens: 10,995\noutput_tokens: 35,981\ncache_creation_input_tokens: 347,815\ncache_read_input_tokens: 7,893,000\ntotal: 8,287,791\nclaude-opus-4-8:\ninput_tokens: 15,219\noutput_tokens: 130,155\ncache_creation_input_tokens: 245,769\ncache_read_input_tokens: 7,523,608\ntotal: 7,914,751\nclaude-sonnet-4-6:\ninput_tokens: 702\noutput_tokens: 366,911\ncache_creation_input_tokens: 755,367\ncache_read_input_tokens: 37,203,591\ntotal: 38,326,571\nclaude-sonnet-5:\ninput_tokens: 126,838\noutput_tokens: 444,727\ncache_creation_input_tokens: 2,432,767\ncache_read_input_tokens: 53,222,454\ntotal: 56,226,786<\/code><code>\nestimated carbon footprint total: 1,484.3 gCO2e<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Script <a href=\"https:\/\/github.com\/everedero\/misc_scripts\/blob\/main\/token_count.py\">here<\/a><\/p>\n<\/details>\n\n\n\n<p class=\"wp-block-paragraph\">So I produced 1.5 kg of CO2 equivalent (CO\u2082e).<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In order to make sense of this, let\u2019s find some interesting comparisons in <a href=\"https:\/\/www.carbonfootprintof.com\/\">https:\/\/www.carbonfootprintof.com\/<\/a>:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>37 hours of watching video streaming<\/li>\n\n\n\n<li>3 km by plane<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">But wait! What about the hardware?<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>Off-the-shelf BLE to Zigbee gateway<\/td><td>~2 to 8 kg CO\u2082e<\/td><\/tr><tr><td>Sonoff SNZB-02P temperature\/humidity sensor<\/td><td>1 to 3 kg CO\u2082e<\/td><\/tr><tr><td>Assembled custom PCB board, 50 x 50 mm, no display or battery (produced by 5)<\/td><td>~0.3 to 1.4 kg CO\u2082e<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">It would seem that a custom PCB board + vibe-coded firmware (1.4 kg + 1.4 kg) is approximately the same carbon impact as buying the off-the-shelf solution (between 2 and 8 kg). That is, if you conveniently forget that you usually have to order 5 boards, not 1. And, if you already have the hardware, it is more interesting to use it instead of buying new, even if you have to involve Claude.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">My takeaways<\/h2>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized wp-duotone-unset-13\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"680\" src=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/destroy_everything-1024x680.png\" alt=\"\" class=\"wp-image-2328\" style=\"aspect-ratio:1.5059077992056003;width:485px;height:auto\" srcset=\"https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/destroy_everything-1024x680.png 1024w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/destroy_everything-300x199.png 300w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/destroy_everything-768x510.png 768w, https:\/\/redero.fr\/wp-content\/uploads\/2026\/07\/destroy_everything.png 1052w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">From a carbon-footprint perspective, is using Claude a disaster?<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I still have no idea, but crunching the numbers helped me put things in perspective. My whole weekend project, shopping gizmos in China and vibe-coding included, is less than a steak or 30 km by (gasoline) car.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This is not counting all the other environmental side-effects of the AI race right now, like water, land use, etc. But on an individual level, my Claude usage is probably not the biggest contributor to my carbon footprint.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If in doubt about carbon footprints, you can play the least fun online game ever made: <a href=\"https:\/\/nosgestesclimat.fr\/en\/empreinte-carbone?mtm_kwd=InfoGouv\" target=\"_blank\" rel=\"noreferrer noopener nofollow\">https:\/\/nosgestesclimat.fr\/en\/empreinte-carbone<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I made a system for thermal management in case of heatwave. Actually, the IA robots did most of it. Then I had seconds thoughts and did some carbon footprint calculations.<\/p>\n","protected":false},"author":1,"featured_media":2042,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[49],"tags":[131,95,47],"class_list":["post-2032","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog_en","tag-apocalyse","tag-hardware-en","tag-zephyr-en"],"_links":{"self":[{"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/posts\/2032","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/redero.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2032"}],"version-history":[{"count":125,"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/posts\/2032\/revisions"}],"predecessor-version":[{"id":2348,"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/posts\/2032\/revisions\/2348"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/redero.fr\/index.php?rest_route=\/wp\/v2\/media\/2042"}],"wp:attachment":[{"href":"https:\/\/redero.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2032"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/redero.fr\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2032"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/redero.fr\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2032"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}