It is useful and advisable to backup a working copy of your RPi image. For example, make a backup copy after setting up WiFi and update the library, the next time the wifi is not working, you can reformat the SD card and reinsert this backup copy to revert back to previous version. After this, your RPI get to connect back to WiFi right away like before. Here are the steps:
- Download Win 32 Disk Imager if none installed on your computer here
- Insert the SDCard into your computer (e.g. via card reader or SD card slot if your computer has one).
- Open Win 32 Disk Imager. Select a location and give a file name for the backup image.
- Select the right drive.
- Click Read.
- Once done, keep this backup copy safe. Please note that the size of the backup is the same size of your SD Card. SO please be mindful that it will take a considerable amount of disk space.
- Download SDFormatter if none installed here.
- Download Win 32 Disk Imager if none installed here or Etcher For Mac here.
- Use SDFormatter to format the SD card. Please be careful and make sure you select the correct drive letter.
- Use Win 32 Disk Imager or Etcher to re-image the backed up image into the SD card. I.e. select the file name, the drive letter of the SD card, and then click Write. Please be careful that the correct drive letter is selected. If you wish to install a fresh Raspbian OS, you can download it here.
- Once this is done, a new image has been rewritten on your SD Card!