Seeing as how difficult (and expensive) it is these days to get one’s hands on an NES Classic, an arguably better alternative is to turn a Raspberry Pi into an emulation box. The setup for this is surprisingly easy. Along with the Pi, a micro SD card (8GB as a recommended minimum), a micro USB power adapter (be sure to chose one with the correct voltage), a USB or Bluetooth controller, and a case are what’s needed. The setup also requires a keyboard, and the device needs to be connected to a display through an HDMI output. Audio can either be passed through the HDMI connection, or through the 3.5mm audio jack.
As a convenience, a Linux distribution called RetroPie is designed specifically with emulation in mind. Download it from the official website, and install it to the SD card with the following command:
dd if=/path/to/retropie.img of=/dev/sdX bs=1M conv=fsync
Be sure that the SD card is not mounted when executing the command.
After it is complete, connect all the peripherals to the Pi (SD card, USB devices, HDMI), then plug in the power adapter. The device should automatically boot up, and resize the partition to accommodate the available space. The controller will then be configured via user input. It is recommended at this point to perform updates to the device through the configuration menu. Once completed and rebooted, ROMs can be loaded onto the device following this guide. Files can be added automatically via a USB drive, through SFTP, or even a Samba share. If ever terminal access is required directly on the device, pressing F4 will pull it up.