M5Stack MultiApp Advanced Firmware



  • Using this app, M5Stack can run all included apps without reflashing/rebooting

    • This is the continued development of the original M5Stack MultiApp firmware
    • This project is made on PlatformIO IDE
    • With some minor work it can be adapted to other IDE's like VisualStudio+VisualMicro or Eclipse.
      This project use modifed M5Stack M5StackSAM and EspAudio libraryes from project local storage.
      image

    alt text

    Project Repository: https://github.com/botofancalin/M5Stack-MultiApp-Advanced

    Get it going fast

    • Flash your M5 with Precompiled firmware from this repository +The flashing instructions can be found on the Precompiled Firmware folder

    Installing and Compiling the firmware

    • First, you must install the necessary tools and prepare the IDE environment
    • Download (and unzip) this repository
    • Download and Install Visual Studio Code https://code.visualstudio.com/ or Atom: https://atom.io/
    • Install the PlatformIO Extension
    • Install ESP32 Framework on PlatformIO
    • Apply the PlatformIO Patch
      -- This Patch will fix ESP-IDF bug - ButtonA Problems when Wifi is connected
      --This Patch will allow to upload large firmwares into M5Stack by sacrificing some SPIFFS area
      --Open the MultiApp Project folder on AplatformIO
    • Click the BUILD button alt text
      --This will build and Flash the M5Stack connected to your PC USB
    • To use Local Ota to flash your M5Stack
      --The M5Stack must be connected to the same network as your PC
      --In the project "platformio.ini" file set "upload_port = [your M5StackIP]"

    The project include:

    • Applications
    • Dual Channel Oscilloscope
      -- Pin 35 Channel 1
      -- Pin 36 Channel 2
      -- Pin 26 Signal Generator
    • Oscilloscope Menu Structure:
      -- Stop / Run frame
      -- Sensitivity for each channel: 50mV, 100mV, 200mV, 500mV, 1V per Divizion
      -- Sample Rate: 0.3ms, 0.6ms, 1ms, 2ms, 5ms, 10ms, 20ms, 50ms, 0.1s, 0.2s, 0.5s, 1s, 2s, 5s, 10s per Divizion
      -- Channel mode for each channel: Normal, Inverted, Off
      -- Offset for each channel
      -- Trigger Switch: Trigger from Channel 1 or Channel 2
      -- Trigger Mode: Auto, Normal, Scan
      -- Trigger Level 0 - 100 %
      -- Trigger Edge: Rising (UP), Falling (DN)
      -- Internal Signal Generator mode: Wave signal, Square signal, Triangular Signal 1, Triangular Signal 2, Signal Generator OFF
      -- Exit Oscilloscope App
    • WebRadio
      -- Support Volume Adjustment
      -- Support Stations change on the fly
      -- Long press NEXT key to exit from Radio App
      -- Display Volume Level
      -- Display Data buffer state
      -- If the connection is lost or the buffer get empty, will try to recover the connection.
      -- If the connection can't be recovered, will connect to the next station on the list
      -- Can play MP3 streams
      -- Web Radio streams are stored on SD Card on "RadioStations.txt" file
      -- Support theoretically unlimited station list
      -- The stations must be defined on separate lines as follow: "StationName=StationLink;
    • WebServer with web based SD File manager
      -- Can run in the background once started
      -- You can use other apps when the webserver is running
      -- List SD Folders
      -- Create Folder
      -- Delete Folder
      -- Download files
      -- Upload Files
      -- Delete Files
      -- Display Files Content (images, text, etc...)
    • SD Browser that support
      -- Display Jpeg files on the screen
      -- Resize Jpeg to fit to screen size
      -- Play MP3 Files using Mp3 Player App
      -- Display File properties for the files that can't be open with included apps
    • Tools list
      -- Wifi Packet Monitor
      -- Wifi Scanner
      -- I2C Scanner
      -- DHT Sensor reader: Support any DHT sensor type
      -- Stopwatch
    • Games (just for fun)
      -- Space Shooter
      -- Flappy Bird
    • Return (to menu root)
    • System
    • System Informations
      -- CPU Frequency, Number of cores, Chip Revision, Flash Speed, Current Free RAM space, Wifi MAC address, Wifi IP Address, Wifi current Mode
      -- Minimum FREE heap (RAM) since the device was started, Flash Size, SPIFFS Size, SPIFFS used space, SD Card Type, SD Card Size, SD Card used space
    • Wifi Connection
      -- Can set the Wifi Connection on M5Stack by
      -- Wifi Smart Config
      -- Wifi WPS PushButton
      -- Wifi WPS PIN Code
      -- Wifi STA: Set Wifi to STATION (Reciever) mode
      -- Wifi AP: Set Wifi to ACCESS POINT (Sender) mode
      -- Wifi OFF
    • Display Backlight Settings
      -- Set and save Display backlight so the settings survive reboot and flash
    • Sleep
      -- Puth the device into Sleep mode
      -- The device can power back on by pressing ButtonB or reset key

    This Firmware also support:

    • Local OTA flashing
      -- Set the M5Stack IP as Upload Port on PlatformIO then you can flash the device over WIFI
    • Remote OTA Update
      -- Will check the server for new version at startup
      -- If a new version was found, will update to new version

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text

    alt text



  • There is lot of flash space left.
    I am waiting for suggestions what apps should i add to this firmware



  • M5Stack Weather Station was added to M5Stack MultiApp Advanced:
    http://forum.m5stack.com/topic/194/m5stack-multiapp-advanced-firmware

    alt text

    alt text

    alt text



  • Great project and work ..
    Can we record realtime data on SD card without streaming over Wireless at the same time...
    What is the maximum rate to record on local SD as oscilloscope with one-two signal ?

    Great multi-application ...
    Can it be a sd-card image to update too ?

    Good stuff and waiting for both Bluetooth and wifi ...

    Bravo
    Jp



  • What ? you need to log the data from oscilloscope to SD?
    Why??? is a basic Oscilloscope. Not a signal analyzer (good idea for a future app).

    WiFi is already used on the app for Webradio, Webserver, Weather, OTA, etc...

    About bluetooth... i didn't found any real usage for it on my app.
    So i didn't even think about it...
    As i know BLE and bluetooth serial can be easy implemented.



  • What ? you need to log the data from oscilloscope to SD?

    WiFi is already used on the app for Webradio, Webserver, Weather, OTA, etc...

    About bluetooth... i didn't found any real usage for it on my app.
    So i didn't even think about it...
    As i know BLE and bluetooth serial can be easy implemented.





  • Hello,

    Help, can not install to my M5STACK.

    0_1527704882236_97033212-19a2-46e5-ac00-12ef1239a5a5-image.png



  • read the Readme.txt from platformIO_Patch folder
    Apply the platformIO_Patch, then you can upload to your M5Stack.

    Or you can upload using the precompiled firmware.
    All this resources are included into repository.

    Also Please re-download the repository.
    I updated the code compatibility to latest PlatformIO Arduino-IDF update



  • @calin
    Thanks for help.
    I download the new version https://github.com/botofancalin/M5Stack-MultiApp-Advanced
    I apply the platformIO_Patch.
    Open project and Build: -> Error missing file: Min_spiffs.csv.csv
    0_1527792254221_c1edd517-dff2-4266-b535-adbe575d3bb5-image.png

    I try upload using the precompiled firmware.
    0_1527792379203_9e78bd48-e4b8-48ce-876e-74281921094a-image.png

    Press Reset button after Finish but M5stack do nothing.



  • @calin

    Yes, it works now.
    I update the platform espressif 32 to version 1.0.1
    0_1527796514516_6039ec1a-5597-42ca-9c43-4f1c45afef90-image.png



  • @freddyb, I'm having the same problem. how did you "update the platform espressif 32 to version 1.0.1"?



  • @pkourany open VsCode PlatformIO
    Go to Platforms.
    Make sure you have Espressif 32 platform installed.
    If not installed, go to Platforms-Enbedded and install it
    To update the platform, go to Platforms-Updates If you see it there, then you can update. If not, then is up to date.



  • @calin This is awesome! However, there is no longer a free API provided by weatherundeground , is it possible to change the weather provider to something free like openweather? Thank you!



  • @lastcaress I don't think they stopped the free subscriptions... i can add openweather support... but i need some free time for that...



  • @calin Thanks! They made the change recently, a couple of days ago



  • @calin, finally figured out you were referring to the command line. Got the updates done but code would still not run on M5Stack. I just updated again and espressif 32 is now v1.02. Everything compiles but I can't test on my M5 until tonight.



  • I've installed M5Stack MultiApp Advanced Firmware and need to connect to Wifi.
    I don't have WPS on my Wifi router, and tried SmartConfig. All it did was count to 120 and exit back to the Wifi menu.

    So I googled SmartConfig - and found the answer. You download an app to your phone, enter in your SSID and it broadcasts back to the Arduino. Very neat solution. Find out more at: http://www.iotsharing.com/2017/05/how-to-use-smartconfig-on-esp32.html



  • @calin Hi, any timeframe for when you may be able to change to OpenWeather? I have just done an overview video on YouTube and next want to review the individual Apps. It would be really neat if the weather App was working. Thanks.
    M5Stack MultiApp Advanced Firmware Installation Tutorial Guide



  • @1nformatica The weather app is currently working just fine with weatherunderground service.
    There was a compatibility problem with the latest IDF version but i fixed that last week.
    If you really whant to use the openweather, i can add the option for openweather till tomorrow... but i am not sure how the service quality is on that provider... and if they provide all the data used on this app



  • @calin From WeatherUnderground's web site "To improve our services and enhance our relationship with our users, we will no longer provide free weather API keys as part of our program. If you have been directed to download our Weather Underground free API key by a third party provider, please contact your vendor for resolution."