171 lines
6.3 KiB
Markdown
171 lines
6.3 KiB
Markdown
# WiFlash
|
|
|
|
Uses a GPIO to control a lighting console over OSC, whilst also controlling an LED strobe light with DMX data received over sACN.
|
|
|
|
This software is designed for the ESP32, but will probably be usable on other Espressif platforms,
|
|
|
|
![example](assets/wiflash_schem.png)
|
|
|
|
## Flashing
|
|
|
|
The WiFlash firmware needs to be initially flashed onto the ESP32.
|
|
|
|
### Arduino IDE Requirements
|
|
* [Arduino IDE](https://www.arduino.cc/en/software)
|
|
|
|
> Refer to the [Getting Started](https://www.arduino.cc/en/Guide/) page for Installation instructions.
|
|
|
|
* [Arduino core for ESP32](https://github.com/espressif/arduino-esp32)
|
|
> - Start Arduino and open Preferences window.
|
|
- Enter `https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json` into *Additional Board Manager URLs* field. You can add multiple URLs, separating them with commas.
|
|
- Open Boards Manager from Tools > Board menu and install *esp32* platform (and don't forget to select your ESP32 board from `Tools > Board` menu after installation).
|
|
|
|
* [Arduino ESP32 Plugin](https://github.com/me-no-dev/arduino-esp32fs-plugin) - Arduino plugin which packs sketch data folder into SPIFFS filesystem image.
|
|
> Follow the install instructions in the link.
|
|
|
|
|
|
* [ArduinoOSC](https://github.com/hideakitai/ArduinoOSC) - OSC subscriber / publisher for Arduino
|
|
* [NeoPixelBus](https://github.com/Makuna/NeoPixelBus) - A library to control one wire protocol RGB and RGBW leds.
|
|
* [ESPAsyncWebServer](https://github.com/me-no-dev/ESPAsyncWebServer) - Async HTTP and WebSocket Server for ESP Arduino.
|
|
> Install from the Arduino library manager.
|
|
|
|
|
|
* [WiFlash for ESP32](https://git.company235.com/kevin/wiflash)
|
|
> - Unzip the downloaded file.
|
|
- Open `wiflash_esp32.ino` in Arduino.
|
|
- Select your ESP32 board from the `Tools > Board` menu.
|
|
|
|
### Uploading
|
|
1. Use the upload button in Arduino to compile your changes and upload the software to your ESP32 device.
|
|
1. Use `Tools > Esp32 Sketch Data Upload` to build and upload the SPIFFS partition.
|
|
|
|
### Troubleshooting
|
|
| Problem | Try |
|
|
| :- | :- |
|
|
| Arduino shows compiler errors. | Make sure you have the correct board type selected in the `Tools > Board` menu. |
|
|
| Errors during upload. | Make sure that you have the correct port selected in the `Tools > Port` menu. |
|
|
| Unable to upload SPIFFS | Make sure the serial monitor window is closed. |
|
|
|
|
|
|
## Configuring
|
|
|
|
1. Connect to the default access point:
|
|
* SSID: WiFlash
|
|
* Password: technologyismagic
|
|
1. Open a web browser and navigate to [http://wiflash.local](http://wiflash.local)
|
|
|
|
### Status
|
|
|
|
Here you can observe the current state of the device.
|
|
|
|
### Configuration
|
|
|
|
This tab lets you configure the device settings.
|
|
|
|
> __Reset your configuration to defaults by connecting pin A1 to GND during boot-up.__
|
|
|
|
#### WiFi
|
|
Change these to enter your own SSID and WEP/WPA2 password.
|
|
|
|
#### Network
|
|
Enter your own IP configuration.
|
|
|
|
#### OSC Button
|
|
Set the value of `host` to be the IP address of the OSC server.
|
|
|
|
Change the pressed and released values to suit your setup. These examples will send `GOTO LIST 99 CUE 1` when the button is pressed, and `GOTO LIST 99 CUE 2` when the button is released. Check the [Hog 4 OSC mappings](https://www.highend.com/pub/support/controllers/documents/HTML/en/sect-osc_mappings.htm) manual page for additional inspiration.
|
|
|
|
#### Strobe
|
|
Set the sACN Universe and DMX Address for the strobe device.
|
|
|
|
#### LED Pixel Strip
|
|
Set the sACN Universe and DMX Address for the LED pixels.
|
|
|
|
### Hardware
|
|
These values on this tab need to match the hardware setup.
|
|
|
|
|
|
## Reference
|
|
|
|
###### Hog4 fixture profile:
|
|
[Import from XML](728%20Fixtures%20Wiflash%20rev%200.xml)
|
|
|
|
#### DMX Mapping
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Chan</th>
|
|
<th>Command</th>
|
|
<th>DMX Range</th>
|
|
<th>Value Range</th>
|
|
<th>Resolution</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td>1</td>
|
|
<td>Intensity Coarse</td>
|
|
<td rowspan=2>0 - 65535</td>
|
|
<td rowspan=2>0 - 100%</td>
|
|
<td rowspan=2>15 bit<br/>2.4kHz PWM</td>
|
|
</tr>
|
|
<tr>
|
|
<td>2</td>
|
|
<td>Intensity Fine</td>
|
|
</tr>
|
|
<tr>
|
|
<td>3</td>
|
|
<td>Duration</td>
|
|
<td>0 - 255</td>
|
|
<td>0.02 - 0.5s</td>
|
|
<td>0.004s</td>
|
|
</tr>
|
|
<tr>
|
|
<td>4</td>
|
|
<td>Rate</td>
|
|
<td>0 - 255</td>
|
|
<td>0.5 - 25Hz</td>
|
|
<td>0.1Hz</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
## Credits
|
|
|
|
While not the first device of this class to be constructed, this version is credited to:
|
|
|
|
- Concept & electronics: Phil Abeyta
|
|
- System design & firmware: Kevin Matz
|
|
|
|
## Copying
|
|
This Software is released under the MIT License.
|
|
|
|
Copyright © 2020, Kevin Matz
|
|
|
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
of this software and associated documentation files (the "Software"), to deal
|
|
in the Software without restriction, including without limitation the rights
|
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
copies of the Software, and to permit persons to whom the Software is
|
|
furnished to do so, subject to the following conditions:
|
|
|
|
The above copyright notice and this permission notice shall be included in all
|
|
copies or substantial portions of the Software.
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
SOFTWARE.
|
|
|
|
## Additional copyrights
|
|
|
|
| Library | Copyright | License |
|
|
| :- | :- | :-: |
|
|
[WiFlash](https//git.company235.com/kevin/WiFlasher) | Copyright © 2020 Kevin Matz | [MIT](https//git.company235.com/kevin/WiFlasher/src/branch/master/LICENSE) |
|
|
[NeoPixelBus](https//github.com/Makuna/NeoPixelBus) | Michael Miller| [LGPL 3.0](https//github.com/Makuna/NeoPixelBus/blob/master/COPYING) |
|
|
[ESPAsyncWebServer](https//github.com/me-no-dev/ESPAsyncWebServer) | Copyright © 2016 Hristo Gochkov | [LGPL 2.1](http//www.gnu.org/licenses/lgpl-2.1.html) |
|
|
[arduino-esp32](https//github.com/espressif/arduino-esp32) | Copyright © 2015 Ivan Grokhotkov | [LGPL 2.1](https//github.com/espressif/arduino-esp32/blob/master/LICENSE.md) |
|