You always wanted to save your SD-Card from viruses, malware and Trojans. The solution to these is to make them write protected. As of now USB-device exist which can be made write-protected but are very rare to find and are expensive. For SD-cards they do have a write-protected switch but you can easily bypass it using OS tweaks. The sdlocker developed allows to truly write-protect any SD card by toggling the TMP_WRITE_PROTECT bit on the flash memory controller of the card itself. Together with a USB card reader, this write-protected card can then be used as a read-only USB drive.
The sdlocker is built around an Attiny 85 controller. The schematic is also been included along with the code on the website. The code is fully compatiable with avr gcc for those on linux system or you can even use avr dude which is a very famous programmer for the AVR series of controller. The good thing is that you ca edit the code based on your requirement and the level of security you require to protect from malwares.