Skip to content

Sensor Installation Instructions

Material Foundry edited this page Feb 17, 2024 · 11 revisions

This wiki is deprecated, new documentation here.

This page contains instructions on how to install the firmware onto the Material Plane sensor.
Depending on what hardware you have, you will need to follow a different guide:
For the beta kit sensor, follow this guide.
For the DIY sensor, follow this guide.
After following one of those guides, please continue to the configuration guide.

Beta Kit Sensor

  1. Download and install version 1.8.19 of the Arduino software
  2. Download and install the USB drivers
  3. Download and install the ESP32 filesystem uploader
  4. Add v1.0.6 (v2.0.0 is currently not supported) of the ESP32 boards to Arduino. To do so, follow this guide
  5. Download the latest sensor release from here and extract the .zip file
  6. Open Sensor.ino, go to the 'userSettings.h' tab, and make sure that at 'HW_VERSION', only 'HW_BETA' is defined (uncommented)
  7. Click 'Tools', 'Board', 'ESP32 Arduino', and then select 'Node32s'
  8. Again under 'Tools', click 'Port', and select the correct serial port
  9. You should now be able to upload the code to the ESP32, by pressing the 'Upload' button (top-left, the arrow pointing to the right), wait for it to compile and finish uploading
  10. (Firmware v2.0.2+ only) Upload the webserver files by clicking the 'Tools' menu, and then clicking 'ESP32 Sketch Data Upload'. Make sure the serial monitor is not open.

DIY Sensor

  1. Download and install version 1.8.19 of the Arduino software
  2. Download and install the USB drivers
  3. Download and install the ESP32 filesystem uploader
  4. Add v1.0.6 (v2.0.0 is currently not supported) of the ESP32 boards to Arduino. To do so, follow this guide
  5. Download the latest sensor release from here and extract the .zip file
  6. Open Sensor.ino, go to the 'userSettings.h' tab, and make sure that at 'HW_VERSION', only 'HW_DIY_BASIC' or 'HW_DIY_FULL' is defined (uncommented), depending on what variant you've made
  7. If necessary, change the pins for the I2C bus for the IR sensor, the LEDs (FULL sensor only) and USB_ACTIVE (FULL sensor only)
  8. Click 'Tools', 'Board', 'ESP32 Arduino', and then select the ESP32 board that you have
  9. Again under 'Tools', click 'Port', and select the correct serial port
  10. You should now be able to upload the code to the ESP32, by pressing the 'Upload' button (top-left, the arrow pointing to the right), wait for it to compile and finish uploading
  11. (Firmware v2.0.2+ only) Upload the webserver files by clicking the 'Tools' menu, and then clicking 'ESP32 Sketch Data Upload'. Make sure the serial monitor is not open.

Configuration

After installing the firmware on the microcontroller, you have to configure it.
If for some reason the sensor won't react properly, try running 'ClearEeprom.ino' that's provided in the sensor folder, and try again.

Firmware v2.0.2+

This way of configurating is still a bit buggy, so if you run into any issues during this process, you can use the fallback method.
If WiFi has not been configured yet, the sensor will create an open access point called "[name]", where name is the configured DNS name of the sensor (by default this is "materialsensor"). Connect to that access point using your computer or other device (if using a phone, you might have to disable data for the next steps to function).
You can now use a browser to browse to the webserver at "http://[name].local" ("http://materialsensor.local", by default). If you don't add "http://" in front, your browser might automatically add "https://", which will not work. If you try to navigate to any other site, it should redirect you to this page. If this doesn't work, try a different browser or device, or use the fallback method.
One the webpage has fully loaded, go into the "Network" tab, and in the "Access Points" section, press the "Scan" button. This will scan for nearby access points, which should fill the selector below the button (this might take a few seconds). Select your access point, fill in the password (if any) in the "Password" field, and click "Connect".
The sensor should now be connected to your access point, so you can connect your computer or other device back to that access point as well. The sensor webpage is still available on "[name].local" ("materialsensor.local", by default) for further configuration.

Firmware v2.0.1/ Fallback Method

  1. Open the Arduino Software
  2. Set the correct port under 'Tools'
  3. Open the 'Serial Monitor' in the top-right
  4. In the 'Serial Monitor', in the bottom right, set the line-ending to 'Both NL & CR' and set the baud to '250000'
  5. Send the `GET STATUS` command (type it into the textbox in the top, and press enter or press 'Send'
  6. You should now see a list of settings. Make sure that 'Hardware Version' is correct
  7. We now want to connect the sensor to your WiFi. You can get a list of WiFi stations it can see by sending the `SCAN WIFI` command
  8. To connect to your WiFi station, send the following command: `SET WIFI SSID "[SSID NAME]" "[PASSWORD]"` (do not include the square brackets). The sensor should then attempt to connect to the internet. If it's successful, it'll print the IP address of the sensor, write this down, since you'll need it to connect the sensor to Foundry
  9. Send the `GET STATUS` command again and test if 'Connected' is set to 'True'. You can use this command, or `GET WIFI IP` to get your IP address, in case you need it at a later stage

Clone this wiki locally