-
Notifications
You must be signed in to change notification settings - Fork 0
Software
The software is written C and uses the Arduino IDE. Each gate or dust collector in the system has its own Wemos D1 mini microcontroller. There is a main sketch where the WiFi network is set up using the painlessMesh code library. It sets a network that does not connect to the internet and does not require a WiFi router. Any gate that is opened tells all other gates to close and tell the dust collector to turn on.
One gets a choice which type of gate you will be using. These additional .h files include the code needed for that style of gate and the mechanism used to open the gate (or dust collector) Next there is a choice of .h files for buttons to open the gates or no button. Next there is a choice of .h files for current sensors that can detect if a power tool is being used.
// uncomment only one of the following four include statements. These move the blast gates
//#include "gateServo.h"
//#include "gateServoRatchet.h"
#include "gateRelay.h" //
//#include "gateStepper.h"
//#include "gateStepperA4988.h"
//#include "accelStepA4988.h"
//#include "collector.h"
// uncomment only one of the following include statements. These are the buttons or switches that trigger moving the blast gate (or turn on the dust collector)
//#include "triggerTemplate.h"
//#include "button.h"
#include "toggleButton.h"
//#include "noButton.h"
// uncomment only one of the following include statements. These are the current sensors that trigger moving the blast gate (or turn on the dust collector)
//#include "currentSensorACS712.h"
#include "noCurrentSensor.h"In the example above the file gateRelay.h has been included which is used with a pneumatic cylinder to open and close a sliding gate. The file toggleButton.h was added. This allows a button to toggle between the gate being open and closed using the button. A double click will turn the dust collector off. The file noCurrentSensor.h was added because this gate did not have a current sensor attached to automatically open the gate.
The setup allows for a mix and match approach. In a single wood shop there can be multiple different gate styles and different mechanisms for opening the gates. As prototypes are documented a separate page will be added for each one. These pages will include how to change the code for this option, wiring diagrams (Fritzing Breadboards), Parts lists with links and costs, pictures of the prototype and/or videos. Pictures of the gate installed in a shop when available. As time permits will will also list out what we tried that didn't work.