<?xml version="1.0" encoding="UTF-8"?>
<rss  xmlns:atom="http://www.w3.org/2005/Atom" 
      xmlns:media="http://search.yahoo.com/mrss/" 
      xmlns:content="http://purl.org/rss/1.0/modules/content/" 
      xmlns:dc="http://purl.org/dc/elements/1.1/" 
      version="2.0">
<channel>
<title>Jean-Francois&#39;s blog</title>
<link>https://blog.jean-francois.im/</link>
<atom:link href="https://blog.jean-francois.im/index.xml" rel="self" type="application/rss+xml"/>
<description></description>
<generator>quarto-1.8.27</generator>
<lastBuildDate>Wed, 25 Mar 2026 00:00:00 GMT</lastBuildDate>
<item>
  <title>The Unreasonable Effectiveness of the Superpowers Claude Plugin</title>
  <dc:creator>Jean-François Im</dc:creator>
  <link>https://blog.jean-francois.im/posts/the-unreasonable-effectiveness-of-the-superpowers-claude-plugin/</link>
  <description><![CDATA[ 





<p>Since we’re now in the era of LLM-based code writing, I’ve been working on writing more code using Claude Code. Obviously, one can say “Hey Claude, I want to build a snake game. I think it would be funny if the snake ate hot dog emojis,” and it’ll probably write something half-decent, but when it comes to larger projects, that kind of one-shot prompt doesn’t work so well.</p>

<div class="no-row-height column-margin column-container"><div class="">
<p>To be fair, LLMs have been relatively decent at doing these one-shot prompts for simple projects in their training data for quite some time.</p>
</div></div><p>Obviously, the next step would be to improve one’s prompting skills. Write a design document, and have the LLM implement it. Maybe even have another LLM review the code.</p>
<p>The interesting thing is that Anthropic added the ability for Claude to have skills, which are basically Markdown files that contain instructions and prompts so that one can leverage the prompting ability of other people to do certain tasks. They’ve also added the ability to add plugins to Claude Code, which can contain multiple skills.</p>
<p>Given those two features, some <a href="https://github.com/obra/superpowers/graphs/contributors">pretty cool people</a> made the <a href="https://claude.com/plugins/superpowers">Superpowers Claude Code plugin</a> which adds skills like <a href="https://github.com/obra/superpowers/blob/3f80f1c769d8a172ee9803d049253f15fbe4895b/skills/brainstorming/SKILL.md">brainstorming</a> that are automatically invoked whenever one uses a prompt similar to the one in the introduction, at which point Claude will start asking questions to clarify what one wants to build.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/the-unreasonable-effectiveness-of-the-superpowers-claude-plugin/images/superpowers-screenshot.png" class="img-fluid figure-img"></p>
<figcaption>Claude Code screenshot</figcaption>
</figure>
</div>
<p>It’ll then proceed to draft a design which can then be iterated on through one or more review cycles, then draft an implementation plan, ask for a review, then code the whole thing automatically. Crazy, and after the implementation plan is approved, one can walk away from the computer and come back to something that works — at least if one has their permissions set correctly or runs with <code>--dangerously-skip-permissions</code>.</p>
<p>Obviously, the resulting code is only as good as the quality of the design, and you sometimes have to push back on design decisions that don’t work, but for turning random prompts into quick prototypes or funny snake games embedded in blog posts, it does work unreasonably well.</p>
<canvas id="snake-game" style="display: block; width: 100%; border-radius: 4px;">
</canvas>
<script src="snake.js"></script>



 ]]></description>
  <category>Claude Code</category>
  <category>LLMs</category>
  <guid>https://blog.jean-francois.im/posts/the-unreasonable-effectiveness-of-the-superpowers-claude-plugin/</guid>
  <pubDate>Wed, 25 Mar 2026 00:00:00 GMT</pubDate>
</item>
<item>
  <title>Building a Simple Air Quality Monitor</title>
  <dc:creator>Jean-François Im</dc:creator>
  <link>https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/index.en.html</link>
  <description><![CDATA[ 





<p>During the terrible wildfires that we had in California in 2020, it was possible to know how good or bad the outside air quality was through <a href="https://www.purpleair.com/map">PurpleAir’s excellent sensor network</a>.</p>
<p>However, having all the windows closed due to the poor air quality outside, I was wondering about the air quality inside as well. While it’s definitely possible to get pre-made devices — such as <a href="https://www2.purpleair.com/products/purpleair-pa-i-indoor">PurpleAir’s indoor air quality sensor</a>, <a href="https://www.iqair.com/us/air-quality-monitors/airvisual-series">IQAir’s indoor air quality sensor</a>, or even <a href="https://www.aliexpress.com/wholesale?SearchText=air+quality+monitor">something cheapo from AliExpress</a> — building my own is much more interesting:</p>
<ul>
<li>It’s a fun project while being stuck at home during the pandemic</li>
<li>It’s cheaper than a commercial unit, so I can put one upstairs and one downstairs</li>
<li>It’s a good excuse to learn more about electronics</li>
<li>With control over the firmware, it’s possible to do all kinds of things, such as logging the data over serial port or even sending the data over Wi-Fi to a <code>gen_tcp</code> <a href="https://github.com/jfim/air-quality-server">server written in Elixir</a>; once the data is on a more powerful computer, it can be logged to CSV to analyze in R, or one can make a fancy display with Phoenix’s LiveView</li>
<li>Did I mention it’s fun?</li>
</ul>
<p>It’s also a pretty simple project; since all of the parts in the build have passive components included, the project is literally just buying parts, soldering them, putting the parts on a breadboard, and flashing the firmware. As such, a careful beginner could assemble this relatively easily.</p>
<p>Since it’s always a good idea to have an idea of what one is getting into before starting a project, the unit costs should be relatively low — less than USD$10 for just temperature and humidity to less than USD$70 for CO<sub>2</sub>, PM1.0/2.5/10.0 and tVOC depending on the cost of sensors — although getting the basic electronics tools required for this might add a bit to this. Time wise, this project can be completed in a few hours, with about an hour or two for each of the phases of this project — shopping, soldering, assembling, and installing the firmware — although one can tinker with the software for a while.</p>
<p>If you follow the instructions in this post, you’ll have this assembly on a breadboard, with data that can be read over the serial port or sent over Wi-Fi to a server of your own for further processing. It is powered through a USB port on your computer or any decent USB charger. This is what it looks like:</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/breadboard.jpg" class="img-fluid figure-img"></p>
<figcaption>Everything assembled on a breadboard</figcaption>
</figure>
</div>
<p>Since this is customizable, one could also opt for a very minimal version with a single sensor, such as this one.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/mini-breadboard.jpg" class="img-fluid figure-img"></p>
<figcaption>A cute miniature sensor</figcaption>
</figure>
</div>
<p>And this is an example of a display that one can build (will be explained in a follow up post):</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/display.jpg" class="img-fluid figure-img"></p>
<figcaption>Laptop and eInk display</figcaption>
</figure>
</div>
<p>Since this is a learning project for me, I also started designing my first PCB for this, as well as an enclosure that can be 3D printed; in theory, the whole thing should fit within a pretty compact package.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/assembly.png" class="img-fluid figure-img"></p>
<figcaption>Solidworks PCB assembly</figcaption>
</figure>
</div>
<p>Neither the PCB nor the enclosure are finished, but once they’re ready and tested, I’ll post the files here.</p>
<section id="the-hardware" class="level2">
<h2 class="anchored" data-anchor-id="the-hardware">The hardware</h2>
<p><a href="https://www.airgradient.com/diy/">Air Gradient’s DIY sensor</a> has a relatively similar BOM with an interesting combination of sensors. However, I wasn’t too much of a fan of their design; their build uses an older version of the Plantower particle sensor which is much larger, the CO<sub>2</sub> sensor is soldered upside-down such that the CO<sub>2</sub> permeable membrane faces the PCB instead of ambient air, all of the sensors are soldered directly to the PCB so that they can’t be reused/replaced, and their PCB seems a bit too large to place on a windowsill or other narrow location. I also didn’t care too much about the OLED display.</p>
<p>As such, this is the BOM that I have for this project, which is slightly different:</p>
<ul>
<li>WeMos D1 mini (ESP8266 board)</li>
<li>SenseAir S8 CO<sub>2</sub> sensor</li>
<li>Plantower PMSA003-A particle sensor</li>
<li>SHT31 temperature and humidity sensor board</li>
<li>SGP30 tVOC sensor</li>
</ul>
<p>All of the hardware isn’t necessary, so if you don’t care about CO<sub>2</sub> or particle counting, you can take that out of the build, it’ll still work.</p>
<section id="potential-modifications" class="level3">
<h3 class="anchored" data-anchor-id="potential-modifications">Potential modifications</h3>
<p>If you’re planning on just following the instructions in the rest of this post, you can skip this section.</p>
<p>It <em>might</em> be possible to use <a href="https://store.particle.io/collections/dev-kits/products/argon-kit">Particle’s Argon board</a> instead of the WeMos D1 mini; I haven’t tried it, but it would have the advantage of having the charging hardware for LiPo batteries and integration with their IoT platform. They also have <a href="https://docs.particle.io/air-quality-monitoring-kit/">an air quality monitoring kit that has a different set of sensors</a>, for the soldering averse.</p>
<p>Another thing that I might change is replacing the SenseAir S8 CO<sub>2</sub> sensor with a different CO<sub>2</sub> sensor such as Sensirion’s SCD30; while the S8 works, the datasheet specifies that the average current usage is 30 mA with a peak of 300 mA, which seems to exceed the max 500mA at 5V that a USB port offers by default, leading to a bit of a voltage drop every few seconds. If the voltage drops too low, it seems that the SenseAir S8 returns erroneously high readings; if that’s the case, using a different USB power source and shorter USB cables may help.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/5v-rail-scope.jpg" class="img-fluid figure-img"></p>
<figcaption>5V rail voltage drop due to the SenseAir S8</figcaption>
</figure>
</div>
<p>Alternatively, since the SenseAir S8 CO<sub>2</sub> is the most expensive part of this whole build, it could be replaced by the eCO<sub>2</sub> approximation done by the SGP30. It won’t be as accurate, but depending on your use it might be “good enough.”</p>
</section>
<section id="shopping-list" class="level3">
<h3 class="anchored" data-anchor-id="shopping-list">Shopping list</h3>
<p>If like me you didn’t have anything that could be used to make electronics at home, here is a shopping list. These items can be bought from a local electronics distributor (eg. Mouser, DigiKey, AdaFruit, SparkFun, etc.) or AliExpress.</p>
<ul>
<li>The parts that you want for your sensor:
<ul>
<li>WeMos D1 mini <img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/wemos-d1-mini.jpg" class="img-fluid"></li>
<li>SenseAir S8 CO<sub>2</sub> sensor (if you want a CO<sub>2</sub> sensor) <img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/senseair-s8.jpg" class="img-fluid"></li>
<li>Plantower PMSA003-A particle sensor (if you want a sensor for PM1.0/2.5/10.0, good keywords for this on AliExpress are “PMSA003” or “Plantower dust sensor”) Other Plantower sensor models such as the PMS7003, PMS6003, PMS5003, PMS3003, and PMS1003 /should/ also work but will be larger. The letter after the model name refer to the orientation of the airflow in the sensor; if you’re not building a PCB and case, it doesn’t really matter which one you get. You’ll want to make sure that your sensor comes with a little rainbow colored cable, so that you can solder a connector to it as in this picture. <img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/plantower-pmsa003.jpg" class="img-fluid"></li>
<li>If you want to avoid having to strip and solder wires, which is a bit finnicky, there is a breakout board that will give you male pin headers that’s available (search for “G7 adapter” on <a href="https://www.aliexpress.com/store/1725971">double lung electronic</a>’s AliExpress shop).</li>
<li>SHT31 module (also referred as SHT3X, if you want a sensor for temperature and humidity, good keywords for this on AliExpress are “SHT30,” “SHT31,” should be a small purple board) <img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/sht31.jpg" class="img-fluid"></li>
<li>SGP30 module (if you want tVOC sensing, and an approximate CO<sub>2</sub> sensing, good keywords for this on AliExpress are “SGP30” and “GY-SGP,” should be a small blue board) <img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/sgp30.jpg" class="img-fluid"></li>
</ul></li>
<li>A micro USB cable</li>
<li>A soldering iron: I got a Hakko FX888D but any soldering iron should do</li>
<li>Some solder: I used Kester 24-6337-0018 leaded Sn63Pb37 rosin activated solder, but any leaded rosin solder should do. You probably want to get solder wire that is relatively thin to make it easier to solder these parts.</li>
<li>A fume extractor; breathing solder fumes isn’t good for your health, I got the Aven 17701</li>
<li>Some flux if you’re planning on soldering the wires from the particle sensor: I got a small bottle of Kester 959T flux from <a href="https://www.cmlsupply.com/">CMLsupply.com</a></li>
<li>A few 2.54mm male pin headers</li>
<li>Needle nose pliers to break off the male pin headers cleanly</li>
<li>Small wire cutters to cut and strip the particle sensor wires</li>
<li>A breadboard and jumper wires; I got a cheap one off AliExpress and regretted it, it had a short in it. Make sure it is wide enough if you’re using the SenseAir S8 CO<sub>2</sub> sensor, as that sensor is too wide to fit on a single breadboard.</li>
<li>A basic multimeter for continuity testing; if you have an oscilloscope or a logic analyzer handy, they might help with debugging if you encounter issues, but I wouldn’t buy them solely for this project</li>
</ul>
<p>If you’re getting parts off AliExpress, arm yourself with some patience as it’ll take a while for everything to arrive.</p>
</section>
</section>
<section id="assembling-everything" class="level2">
<h2 class="anchored" data-anchor-id="assembling-everything">Assembling everything</h2>
<p>With all of the parts needed, what’s required is to solder the appropriate pin headers to the various module boards. For electronics beginners, you’ll want to search for <a href="https://duckduckgo.com/?q=how+to+solder+electronics">how to solder electronics</a> before starting to solder this.</p>
<p>If you’re not too sure about your soldering skills, solder the SHT31 module and the WeMos D1 mini first, as they’re the easiest parts to solder. You can then assemble the sensor to check that everything works, then come back to do the more expensive components.</p>
<section id="soldering" class="level3">
<h3 class="anchored" data-anchor-id="soldering">Soldering</h3>
<p>For the SHT31 module, you want to solder the pins such that the SHT31 sensor (the tiny chip with the little hole in the middle) faces up when placed on a breadboard.</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/sht31.jpg" class="img-fluid"></p>
<p>For the WeMos D1 mini, you want to solder the pins pointing below, as shown in this picture.</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/wemos-d1-mini.jpg" class="img-fluid"></p>
<p>For the Plantower particle sensor, you’ll want to cut the rainbow cable in half, strip the wires, and solder some pins to the wires. You want to make sure to solder the VCC, GND, RX and TX wires. You can solder the RST and SET wires, but they’re not used in this build.</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/plantower-pmsa003.jpg" class="img-fluid"></p>
<p>For the SenseAir S8 CO<sub>2</sub> sensor, you’ll want to put the pins so that the pins stick out towards the body of the sensor. To do so, take some of the pin sockets from the WeMos D1 mini and place them on your breadboard. Break off two sections of pin headers (4 and 5 pins respectively), place them in the pin sockets, then place the S8 and solder away. The result should look like this.</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/senseair-s8.jpg" class="img-fluid"></p>
</section>
<section id="assembling" class="level3">
<h3 class="anchored" data-anchor-id="assembling">Assembling</h3>
<p>Now that you have the parts that you need soldered, you need to put them on a breadboard according to this schematic.</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/sensor-schematic.png" class="img-fluid"></p>
<p>For the rest of us, this means that all of the 5V pins should be connected to the 5V pin on the WeMos D1 mini, all of the 3.3V pins should be connected to the 3.3V pin on the WeMos D1 mini, all of the grounds should be connected together, SCL and SDA should be connected to the SCL and SDA pins on the WeMos D1 mini, and the RX and TX pins from the other sensors should be connected to the pins indicated on the diagram.</p>
<p>For electronics beginners, you’ll want to search for <a href="https://duckduckgo.com/?q=how+to+use+a+breadboard">how to use a breadboard</a> before starting to assemble this on a breadboard.</p>
<p>In my case, I’ve used the left side of the breadboard for 3.3V and the right side of the breadboard for 5V; both grounds should be connected together.</p>
<p>If you’re using the CO<sub>2</sub> sensor, you’ll want to put some pin sockets on the breadboard so that you can put the sensor in the pin sockets. The pins on the S8 are not very well labeled, so you’ll want to refer to the <a href="https://duckduckgo.com/?q=senseair+s8+datasheet">SenseAir S8 datasheet</a>, page 3. With the PCB pointing away from the breadboard, the pins on the left from the top are G+, G0, OC, and PWM; on the right, starting from the top, they’re DVCC, RX, TX, RT, and CAL.</p>
<p>If you do it right, it should look like this:</p>
<p><img src="https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/images/breadboard.jpg" class="img-fluid"></p>
<p>To make sure that everything works right before plugging in the USB cable, use your multimeter on the continuity testing setting. For electronics beginners, you’ll want to search for <a href="https://duckduckgo.com/?q=multimeter+continuity+testing">multimeter continuity testing</a> to learn how to do this. Make sure that all of the pins are connected as expected:</p>
<ul>
<li>All of the pins labeled GND/G0 should be connected to the G pin on the WeMos D1 mini</li>
<li>The 5V pin should be connected to the G+ pin on the S8 and the VCC pin of the Plantower</li>
<li>The 3V3 pin should be connected to the VIN pin of the SHT31 and SGP30</li>
<li>The SCL and SDA pins should be connected to the D1 and D2 pins of the WeMos D1 mini, respectively (eg. SCL connected to D1, SDA connected to D2)</li>
<li>The RX and TX pins of the particle sensor should be connected to the D5 and D6 pins of the WeMos D1 mini, respectively</li>
<li>The RX and TX pins of the CO<sub>2</sub> sensor should be connected to the D0 and D7 pins of the WeMos D1 mini, respectively</li>
<li>There should not be any other connections than the ones listed above</li>
</ul>
</section>
</section>
<section id="the-software" class="level2">
<h2 class="anchored" data-anchor-id="the-software">The software</h2>
<p>I’ve created a <a href="https://github.com/jfim/air-quality-monitor-firmware">PlatformIO project and put it on GitHub</a>. If you’re using the D1 mini, you can probably use it as is; I use the PlatformIO extension from VS Code. Make sure that you also have the <a href="https://www.wemos.cc/en/latest/ch340_driver.html">CH340 driver installed from the WeMos site</a>, as you’ll need it to flash the firmware using USB.</p>
<p>You can configure the project by editing the <code>platformio.ini</code> file, which tells PlatformIO which sensors to use and how to build and flash the firmware.</p>
<p>The first time that you flash the firmware, you’ll want to do it over USB, as the D1 mini isn’t running the software that would allow flashing it over the air yet. You’ll also want to have the <code>ENABLE_SERIAL_DEBUGGING</code> option enabled to make sure that you can get readings from the sensors.</p>
<p>Flash the firmware using PlatformIO and open the serial monitor; you should be seeing output similar to the one below. If everything looks good, then you can remove the serial debugging option.</p>
<p>Based on what you want to do, you can leave the air quality monitor attached to a computer and have it log data over the serial port; it’ll emit a single line every second or so that contains all of the sensor readings.</p>
<p>Alternatively, you can enable the network settings to have it connect to 2.4GHz Wi-Fi and send its data over a TCP socket. It’ll emit the same data as over the serial port, but it’ll do so over the network so that you can have multiple sensors that log data to a server. This also enables over the air flashing, so that you can update the firmware on the D1 mini without having to unplug it, plug it into a computer, then put it back into place.</p>
<p>If you want to go that route, the first time that you’ll boot the sensor, it’ll create an unsecured AP. Connecting to that AP shows a page that allows you to configure the Wi-Fi network to connect to, which will be remembered.</p>
<p>I have made <a href="https://github.com/jfim/air-quality-server">a simple server in Elixir</a> that will save the data every few minutes to a CSV file, and rotate the files such that there is one file per day. This should allow you to start playing with the sensor data in your favorite data science environment.</p>
</section>
<section id="conclusion" class="level2">
<h2 class="anchored" data-anchor-id="conclusion">Conclusion</h2>
<p>This was a pretty fun project! I still need to finish the PCB and case, but I’ve been running these air quality monitors for a few months now and it’s been pretty interesting to look at the data.</p>
<p>I’ll write a subsequent post that talks about the things I have learned about indoors air quality by monitoring the air quality at my place.</p>
<p>If you build your own air quality monitor, feel free to reach out; I’ll be happy to hear about how you built your own and what you’ve learned from it!</p>


</section>

 ]]></description>
  <category>Projects</category>
  <category>Electronics</category>
  <category>Air Quality</category>
  <guid>https://blog.jean-francois.im/posts/building-a-simple-air-quality-monitor/index.en.html</guid>
  <pubDate>Sat, 08 May 2021 00:00:00 GMT</pubDate>
</item>
</channel>
</rss>
