# 03 -  USB code upload

Uploading is done with Visual Studio Code (VS) using the PlatformIO tab

[![image-1648136519736.png](https://pvrouteur.apper-solaire.org/uploads/images/gallery/2022-03/scaled-1680-/image-1648136519736.png)](https://pvrouteur.apper-solaire.org/uploads/images/gallery/2022-03/image-1648136519736.png)

During your 1st Upload, you must connect your TTGO or ESP32 to your PC with a USB cable

Thanks to VS you will load in the microcontroller the firmware and the HTML pages of the router

There are 2 uploads to do:

- one for the firmware (the system code)
- one for the filesystem (configuration files and website)

![](https://pvrouteur.apper-solaire.org/uploads/images/gallery/2022-06/image-1654844236864.png)

Then you can directly upload the code remotely with the /update page of the router