Overview
You can build an IoT sensor for your 3D printer so you can be alerted if you’re out of filament. We think this is a great proof-of-concept that can help prevent failed prints.
This project uses an IR Optical Sensor that can detect whenever an object passes by the sensor. The breakout is mounted to a 3D printed bracket right above the 3D printer.
If nothing is detected, an LED buzzer alarm will be triggered letting you know your printer is out of filament.
An Adafruit QT Py ESP32-S2 reads the IR optical sensor and sends data to Adafruit IO whenever it detects missing filament.
The LED buzzer alarm is wired up to a Feather ESP32-S2 so it’s a separate device that can be in another room or workspace that’s away from the 3D printer.
This is great for CNC workshops and 3D printer farms that are in separate rooms away from operators.
This project uses Adafruit’s WipperSnapper, so there’s no code necessary -- making this really easy to set up and get going.
Just install the WipperSnapper firmware onto the Adafruit ESP32 dev board and add the Optical sensor from the Adafruit IO device page.
Page last edited July 03, 2024
Text editor powered by tinymce.
Circuit Diagram
The diagram below provides a general visual reference for wiring of the components once you get to the Assembly page. This diagram was created using the software package Fritzing.
Adafruit Library for Fritzing
Adafruit uses the Adafruit's Fritzing parts library to create circuit diagrams for projects. You can download the library or just grab individual parts. Get the library and parts from GitHub - Adafruit Fritzing Parts.
The diagram for the driver circuit is shown above on a FeatherWing Proto board.
The red LED is a stand-in for the alarm.
The circuit uses pin D10 of the Feather through a resistor to the left leg of the transistor (base) in order to toggle when the transistor opens or closes the middle leg (collector), which allows the alarm circuit to go to ground via the right leg (emitter).
The middle leg connects to the any Ground pin.
The right leg connects to the USB pin.
Page last edited July 03, 2024
Text editor powered by tinymce.
WipperSnapper Overview
Ok - you've connected your board to WipperSnapper. Now what?
This page will give you a quick tour of Adafruit IO WipperSnapper and its core features.
The Device List page provides a list of the devices you've connected to Adafruit IO WipperSnapper along with their connection status.
Think of it as a virtual inventory for your boards!
You can visit this page at any time by navigating to https://io.adafruit.com/wippersnapper.
Clicking on a device from the Devices List page will bring you to its device page. This page is an interface to configure and interact with anything physically connected to your device.
You may think of it as the state of your device at any given time.
When you register a device for the first time, this page will be empty, it's a clean slate!
A "component" in WipperSnapper denotes anything which is physically connected to your hardware.
This can include sensors, buttons, LEDs, NeoPixels, displays, and more!
When you click New Component, your hardware will automatically connect to and configure the component using the settings you specified. No coding required!
Additionally, a component also sets up a unique Adafruit IO feed to store the component's data stream on the web.
Nope! WipperSnapper remembers each component's configuration for each of your boards. The "state" of your board's configuration is saved to its device page.
When you re-connect a board to WipperSnapper, it will automatically re-configure every component listed on the Device Page. The most recent value stored on each component's feed will be sent to the device.
I do not see my the component I want to use listed in the component picker pop-up
We're actively working towards adding more components and component types to Adafruit Wippersnapper.
We also gladly take community contributions to Adafruit IO - You can add your own component by following this guide.
Page last edited July 03, 2024
Text editor powered by tinymce.
WipperSnapper Setup
What is WipperSnapper
WipperSnapper is a firmware designed to turn any WiFi-capable board into an Internet-of-Things device without programming a single line of code. WipperSnapper connects to Adafruit IO, a web platform designed (by Adafruit!) to display, respond, and interact with your project's data.
Simply load the WipperSnapper firmware onto your board, add credentials, and plug it into power. Your board will automatically register itself with your Adafruit IO account.
From there, you can add components to your board such as buttons, switches, potentiometers, sensors, and more! Components are dynamically added to hardware, so you can immediately start interacting, logging, and streaming the data your projects produce without writing code.
Sign up for Adafruit.io
You will need an Adafruit IO account to use WipperSnapper on your board. If you do not already have one, head over to io.adafruit.com to create a free account.
Install USB Driver
Install CP2104 / CP2102N USB Driver
Many ESP32 boards have a USB-to-Serial converter that talks to the chip itself, and will need a driver on your computer's operating system. The driver is available for Mac, Windows, and Linux.
Install CH9102 / CH34X USB Driver
Newer ESP32 boards have a different USB-to-serial converter that talks to the chip itself, and will need a driver on your computer's operating system. The driver is available for Mac and Windows. It is already built into Linux.
If you would like more detail, check out the guide on installing these drivers.
Add a New Device to Adafruit IO
Log into your Adafruit IO account. Click the New Device button at the top of the page.
After clicking New Device, you should be on the board selector page. This page displays every board that is compatible with the WipperSnapper firmware.
In the board selector page's search bar, search for the QT Py ESP32 Pico. Once you've located the board you'd like to install WipperSnapper on, click the Choose Board button to bring you to the self-guided installation wizard.
Follow the step-by-step instructions on the page to install Wippersnapper on your device and connect it to Adafruit IO.
If the installation was successful, a popover should appear displaying that your board has successfully been detected by Adafruit IO.
Give your board a name and click "Continue to Device Page".
You should be brought to your board's device page.
Feedback
Adafruit.io WipperSnapper is in beta and you can help improve it!
If you have suggestions or general feedback about the installation process - visit https://io.adafruit.com/support, click "Contact Adafruit IO Support" and select "I have feedback or suggestions for the WipperSnapper Beta".
Troubleshooting
If you encountered an issue during installation, please try the steps below first.
If you're still unable to resolve the issue, or if your issue is not listed below, get in touch with us directly at https://io.adafruit.com/support. Make sure to click "Contact Adafruit IO Support" and select "There is an issue with WipperSnapper. Something is broken!"
First, make sure that you selected the correct board on the board selector.
Next, please make sure that you entered your WiFi credentials properly, there are no spaces/special characters in either your network name (SSID) or password, and that you are connected to a 2.4GHz wireless network.
If you're still unable to connect your board to WiFi, please make a new post on the WipperSnapper technical support forum with the error you're experiencing, the LED colors which are blinking, and the board you're using.
Try hard-resetting your board by unplugging it from USB power and plugging it back in.
If the error is still occurring, please make a new post on the WipperSnapper technical support forum with information about what you're experiencing, the LED colors which are blinking (if applicable), and the board you're using.
"Uninstalling" WipperSnapper
WipperSnapper firmware is an application that is loaded onto your board. There is nothing to "uninstall". However, you may want to "move" your board from running WipperSnapper to running Arduino or CircuitPython. You also may need to restore your board to the state it was shipped to you from the Adafruit factory.
Moving from WipperSnapper to CircuitPython
Follow the steps on the Installing CircuitPython page to install CircuitPython on your board running WipperSnapper.
- If you are unable to double-tap the RST button to enter the UF2 bootloader, follow the "Factory Resetting a WipperSnapper Board" instructions below.
Uploading this sketch will overwrite WipperSnapper. If you want to re-install WipperSnapper, follow the instructions at the top of this page.
Moving from WipperSnapper to Arduino
If you want to use your board with Arduino, you will use the Arduino IDE to load any sketch onto your board.
First, follow the page below to set up your Arduino IDE environment for use with your board.
Then, follow the page below to upload the "Arduino Blink" sketch to your board.
Uploading this sketch will overwrite WipperSnapper. If you want to re-install WipperSnapper, follow the instructions at the top of this page.
Factory Resetting a WipperSnapper Board
Sometimes, hardware gets into a state that requires it to be "restored" to the original state it shipped in. If you'd like to get your board back to its original factory state, follow the guide below.
Page last edited July 03, 2024
Text editor powered by tinymce.
Action Setup
QT Py TCRT100 Component
In the QT Py Device Click on the big + icon to add the TCTR100 component.
In the drop down set the Breakout Pin to A1.
Set the Return Interval to On Change.
Feather Warning Light Component
In the Feather Device Click on the big + icon to add the Buzz 5v component.
In the drop down set the Buzzer 5V Pin to D10
Create New Action
Build the Actions to trigger the Warning Light
- Go to https://io.adafruit.com and click on Actions
- Click the New Actions button.
- Enter a Name and Description, then click Create
Reactive Trigger Setup
- Click on the Triggers block
- Drag the Reactive block and snap it to the Trigger section in the Action block
- In the Feed block select the TCRT1000 feed from the dropdown menu
- Under the Operator section, select "<" from the dropdown menu.
- In Values menu type 0
Action Setup
- In the Values menu type 1
- In the to section select Feather Buzzer 5V
Create New Action
Build the Actions to trigger the Warning Light
- Click the New Actions button.
- Choose Yes, use Blockly!
Reactive Trigger Setup
- Click on the Triggers block
- Drag the Reactive block and snap it to the Trigger section in the Action block
- In the Feed block select the TCRT1000 feed from the dropdown menu
- Under the Operator section, select ">" from the dropdown menu.
- In Values menu type 1
Action Setup
- In the Values menu type 0
- In the to section select Feather Buzzer 5V
Page last edited July 03, 2024
Text editor powered by tinymce.
3D Printing
3D Printed Parts
STL files for 3D printing will need to be oriented for print using either FDM or SLS machines.
Parts were tested using with PLA filament.
Original design source files may be downloaded using the links below
Page last edited July 03, 2024
Text editor powered by tinymce.
Assemble
Solder QT Py
Use a STEMMA JST PH wire to the QT Py.
Solder the red wire to the 5v pin to the QT Py.
Solder the black wire to the gnd pin.
Solder the white wire to the A1 pin.
Plug the cable into the port on the TCRT1000 STEMMA.
Mount QT Py
Pass the QT Py through the printed holder, with the USB port close to the edge. Insert at an angle with the STEMMA port first, then apply slight pressure to the USB port to press fit into place.
Mount TCRT
Pass the TCRT board through the printed holder and align the screw holes to the QT Py holder.
Fasten TCRT
Use two M2.5x5mm screws to mount the TCRT board to the holder.
Fasten one M2x5mm screw to join both printed holders together.
2020 Mount
Use two M2x12mm screws to attach the 2020 mount.
USB power
Plug a USB cable to power, most printers have a USB port on the side. You can use a right angle adapter to connect.
Mount to 2020 frame
The bar part mounts to a 2020 extrusion frame. Place the filament over the grooves on the guide part to install.
Build Warning Light Circuit
Follow the wiring on the Circuit Diagram page to build the driver for the warning light on a FeatherWing Proto board with socket Headers.
Mount to Warning Stand
Use M2x5mm screws to mount the FeatherWing Proto board to the standoffs on the stand part.
Mount Warning Light
Pass the wires on the warning light through the cutout on the stand print. Connect the Warning Light wires to the 2 pin terminal on the FeatherWing Proto board.
Align the screws on the warning light to the screw holes on the stand print. Use the included nuts to fasten the light to the stand.
Stack Feather to Proto board
Align and press the headers on the Feather to the FeatherWing Proto board. Use a USB C cable to power the Feather.
Page last edited July 03, 2024
Text editor powered by tinymce.