Debug

Run Application

Open Debug Console

To view the console output of your App,

  • Click the [ Debugger ], or open http://getvobot.com/dev/webrepl.html

  • Make sure the target is your Hub’s IP address (e.g., ws://192.168.1.15:8266)

  • Click [ Connect ], if everything goes well, you should see logs on the terminal section

Run the Sample App

To run this sample, click [ Reboot ].

The Hub then reboots, and your debug console will disconnect from the Hub for about 10 to 30 seconds.

Assume your Hub will always obtain the same IP address from your router/AP, the debug console will connect to Hub after a while. Then you will see logs on the terminal section again.

Crash Handling

In case some code caused a crash, you will not be able to proceed with the Hub Portal web page. However, WebRepl is always available.

You can try:

  • Recover the Hub Portal web server in the console:

    import uasyncio
    loop = uasyncio.get_event_loop()
    loop.run_forever()
    

    This will continue running from the exception breakpoint.

  • Or, upload a corrected app/__init__.py to the Hub via WebRepl, then reboot.

Using Host-based Simulation

Since embedded systems are harder to debug, we would like to enable the App programming by providing a host-based simulator. See Simulator for details.