senseshift / senseshift-firmware

Open-source firmware for VR accessories. Build your own DIY haptic vest, gloves, and more!
https://senseshift.github.io/
GNU General Public License v3.0
94 stars 10 forks source link

Flash firmware without PlatformIO #6

Open leon0399 opened 1 year ago

leon0399 commented 1 year ago

Using PlatformIO and PlatformIO IDE is not as straightforward as using Arduino IDE, so an alternative is required

As proposed, WebFlash API may be used to achieve a more effortless firmware flashing experience. Using newly-created openhaptics.github.io it is possible to create a WebFlash-based page. To achieve this following steps are required:

Original issue As project is developed using PlatformIO IDE, it is not that user-friendly, especially for entry-level developers, so it will be easier for most of people to configure and flash it using Arduino IDE Need to investigate how [Marlin](https://github.com/MarlinFirmware/Marlin) IDE is made this happen. They also use PlatformIO and flash it with Arduino IDE
sanjay900 commented 1 year ago

The other option would be to just build one of those web interfaces that uses webserial to program it, then users could have a one-click upload from chrome? Since you already have it building the various environments, it should be easy enough to just have a web tool that flashes those builds

Projects like Tasmota go this route, and it makes for a really nice user experience Tasmotas: https://tasmota.github.io/install/

Should be easy enough to provide something like that via Github Pages?

leon0399 commented 1 year ago

The other option would be to just build one of those web interfaces that uses webserial to program it, then users could have a one-click upload from chrome?

Since you already have it building the various environments, it should be easy enough to just have a web tool that flashes those builds

Projects like Tasmota go this route, and it makes for a really nice user experience

Tasmotas: https://tasmota.github.io/install/

Should be easy enough to provide something like that via Github Pages?

Thank you for great idea! I've found an article on this: https://blog.toit.io/flash-your-esp32-from-the-browser-using-web-serial-5eccb1483b9c

I can easily create website for this 🙂

sanjay900 commented 1 year ago

The only thing is that this only works with chrome / edge since firefox do not intend on implementing things like the web serial API, but thats easy enough to deal with

leon0399 commented 1 year ago

I also found @SlimeVR use using same approach but also seems like can build firmware on-demand for different features

https://github.com/SlimeVR/SlimeVR-Firmware-WebBuilder

sanjay900 commented 1 year ago

That would probably be a super nice way to go about it, cause then people could customise how their pins are bound or how many motors they are using and things like that