Posted on

Adding a fan to your Rasptendo

We are receiving a lot of comments and messages on how to install a cooling fan with your Rasptendo setup that we felt the need to do a post about it. Anyway, here it goes.

Almost all cooling fans that you can buy for the Raspberry Pi make use of Pin 4 (5V) and Pin 6 (Ground) and that they are packaged with the two wires attached together. Unfortunately, Pin 6 is occupied by Rasptendo’s board, thus the dilemma. Fortunately, there are lots of Ground pins in your Raspberry Pi (8 pins to be exact). Seems pretty straightforward, because it actually is, although you have to get your hands a little dirty.

One easy way is that you can buy female to male jumper wires so you won’t need to split the wires. You can buy these in your local electronics store for less than a dollar. Another way is just really splitting the wires.

A female to male jumper wire

The next step is connecting the fan’s ground wire to a ground pin in your Raspberry Pi. You can choose any ground pins in this image. I recommend Pin 39, it’s easy to see so it’s less error-prone.

Note: The ground wire in your fan is usually colored black

Posted on

Rasptendo Recalbox Support

Before this blog, the Rasptendo script works only for RetroPie, arguably the most popular emulation OS for Raspberry Pi. Since a lot of you is asking for Recalbox support, we decided to create a script for it. But before we start, there are just a couple of things that you need to know about Recalbox.

The first thing about Recalbox is that it is created using Buildroot, which makes it very minimal – which also makes it a little low with nice features such as the Debian’s* package management tool apt. The original script uses GPIOZero, a nice and easy Python module for controlling the GPIO. It is easily installed using apt. Since Recalbox doesn’t have this, this script won’t use the GPIOZero. The reason why we wanted to use GPIOZero instead of the “lower level” RPi.GPIO module is that because we wanted you to “hack” your Rasptendo. You can see the Python script at /opt/Rasptendo/halt_wake.py in your RetroPie. Feel free to do some configuration but make sure you know what you’re doing.

Secondly, Recalbox’s support for GPIO3 as a power button doesn’t work the same as much as typical Raspberry Pi OS. It doesn’t allow holding which means it shuts down your Pi simultaneously once you press it. But enough of the talking, here’s your script for Recalbox. (Remember to connect your Recalbox to the internet)

wget --no-check-certificate -O - "https://raw.githubusercontent.com/Argon40Tech/Super-Rasptendo-Case-Power-Switch/master/recalbox_install.sh" | bash

Don’t worry if the script runs too fast, it does what it does, but the script does not make use of GPIOZero (takes a little time to download) in exchange for a little more complicated Python script.

(*Note: Raspbian is Debian-based and RetroPie is built on top of Raspbian which makes RetroPie a “Debian-based operating system”)

Posted on

Hacking your Rasptendo: Configuring Rasptendo RESET button to Exit Emulator with Retrogame

The Rasptendo case is inspired by the SNES Classic including the retro looking POWER and RESET buttons.

In the SNES classic, the reset button takes you to the homepage, which is quite different in our case (pun intended). The Rasptendo RESET button’s default function is to issue a SOFT or HARD reset. We did this since going back to the homepage of RetroPie is fairly simple if you have the controller. Just press the Select + Start buttons simultaneously and it takes you there.

But if you want to have that nostalgic feeling of standing up and pressing the Reset button to change games, or you just want to impress your friends that your set up almost works like the real thing, we got you. The general idea of how this works is this, assign a GPIO to a key event using a virtual keyboard mapped into your GPIO then taking that key event as a signal for your RetroPie to exit emulator. Sounds complicated? Don’t worry, we’re taking you there step by step.

Step 1 – Set up Adafruit Retrogame

Making your GPIO a virtual keyboard is not an easy task. Luckily for us mere peasants, our lords and ladies from Adafruit created Retrogame which does all of the heavy lifting for us (about 99%?). To download this, type in your terminal,

sudo curl -f -s -o /usr/local/bin/retrogame https://raw.githubusercontent.com/adafruit/Adafruit-Retrogame/master/retrogame

then make retrogame executable

sudo chmod 755 /usr/local/bin/retrogame

Step 2 – Configure the RESET button as ESC key

Adafruit Retrogame has to use a configuration file to know what GPIO pins are mapped into the virtual keyboard.

In our case, we are going to use Pins 16 (GPIO23) and 14 (GND) since they are adjacent to each other.

Connect the RESET jumper wires in Pins 16 and 14.

Create the file /boot/retrogame.cfg and map the GPIO.

sudo nano /boot/retrogame.cfg

In the editor, enter the following

ESC 23

This means we are mapping GPIO23 (Pin 16) to ESC of the virtual keyboard.

Step 3 – Add a udev rule

The udev is Linux’s device management system that allows you to identify devices based on their properties. Creating a custom udev rule allows RetroPie to see key events generated by Retrogame. To do this, type

sudo nano /etc/udev/rules.d/10-retrogame.rules

In the editor, copy this line:

SUBSYSTEM=="input", ATTRS{name}=="retrogame", ENV{ID_INPUT_KEYBOARD}="1"

Step 4 – Start Retrogame on every boot

Open rc.local in your terminal editor,

sudo nano /etc/rc.local

Before the line exit 0, insert the following:

sudo /usr/local/bin/retrogame &

Step 5 – Edit RetroArch configuration file

Type,

sudo nano /opt/retropie/configs/all/retroarch.cfg

Look for the line,

input_exit_emulator = "escape"

If another button is assigned to it, change it back to "escape", otherwise leave it be.
Look again for the line,

input_enable_hotkey = "nul"

Change the "nul" value into "escape" and that’s it! Reboot your pi and the RESET button as exit emulator button should work.

Posted on

Install RetroPie in your Raspberry Pi and Play your First Retro Game

RetroPie is one of the emulators running on Raspberry Pi that lets you play your favorite childhood games including SNES, NES, Atari, etc. You can install it on top of an existing Raspbian OS or readily install it on your SD card with the RetroPie image.

This tutorial will teach you how to install RetroPie in your SD card for your Raspberry Pi 3.

 

Step 1 – Download the image

Go to:

https://retropie.org.uk/download/

and make sure to download the Raspberry Pi 2/3 version since you are going to install it on your Raspberry Pi 3.

 

Step 2 – Extract the file

After downloading the .gz file, extract the file using your favorite extraction tool. Remember the directory where you extracted the .img file.

 

Step 3 – Burn the image

There are several ways to do this but we recommend that you use Etcher. It is fast and utilizes a simple interface which makes burning images on SD cards a breeze.

Navigate to the extracted .img file and choose the SD card where you want to install RetroPie. Click Flash! and you’re ready for your first RetroPie boot up!

 

Setting up your first game

Now that you’ve already installed RetroPie, it’s time to play some games! First you need to configure your gamepad and install your chosen game ROMs. We don’t endorse piracy, you should only download ROM’s of games that you own.

 

Step 1 – Configure your gamepad controller

Connect your gamepad controller via USB. RetroPie will automatically detect your gamepad.

As the instruction says, hold any button to start configuring your controller.

Step 2 – Transferring ROMs

ROMs or Read Only Memory are the electronic versions of your old game cartridges. There are currently three main methods of transferring your game ROMs – via USB, via SFTP and via Windows Samba Shares.

 

via USB
  1. make sure your USB is formatted to FAT32
  2. create a retropie folder in your flash drive
  3. plug into your Raspberry Pi 3 and wait for about 10 seconds and plug it out
  4. plug your flash drive again to your computer and you’ll see that the retropie folder has been populated by 3 subfolders. Copy your ROMs in your into the roms/$CONSOLE subsubfolder. (e.g. put your Super Mario World game ROM in roms/snes)
  5. plug into your Raspberry Pi 3 again and wait for about another 10 seconds
  6. choose quit from the start menu
via SFTP
  1. Connect your Raspberry Pi 3 to your WiFi. Follow this guide if you are having trouble connecting.
  2. Download WinSCP for Windows or Cyberduck for Mac. Follow these connection settings:

* Protocol: SFTP
* IP Address: you RetroPie’s IP address, if you’re having trouble finding your IP Address, follow this guide here
* Username: pi
* Password: raspberry
3. Drop the files in ~RetroPie/roms/$CONSOLE folder where $CONSOLE is the corresponding console the ROM should be played.

via Samba Shares
  1. You can access Samba Shares depending on your OS

* On Windows, type \\RETROPIE in your computer folder
* On Mac, open finder, select “Go”, and then “Connect to Server”, input smb://retropie and hit “Connect”.
2. Drop the files in ~RetroPie/roms/$CONSOLE folder where $CONSOLE is the corresponding console the ROM should be played.

Step 3 – Play!

You will see something like this, depending on your transferred ROM.

Choose your game and enjoy!

Posted on

SETUP YOUR RASPTENDO CASE

You now have your new Rasptendo Case. Now it’s time for you to assemble and configure it along with your Raspberry Pi 3 to transform it into the Rasptendo retro gaming console.

The Rasptendo Package Box comes with

  • Rasptendo Case
  • 2 male to female USB extender
  • POWER and RESET Button PCB Board
  • 6 labeled female to female jumper wires
  • 2 male GPIO header
  • Installation guide
  • heat sink

The POWER button issues a safe shutdown command to your Raspberry Pi to prevent damage to your SD card. For the RESET button, you can have two (2) options – one for the soft reboot, and one for the hard reset.

Option 1 for the RESET button issues a soft reboot, which is the safe way (for your SD Card) of rebooting. It’s the same as issuing a sudo reboot in the terminal. It’s especially useful when you transfer ROMs via WiFi and you have to reboot for the RetroPie to discover the newly transferred games. The minor downside to this option is that if your Raspberry Pi hangs (which happens rarely), the button won’t work. That is why we have the second option – which is the hardware reset. It’s useful when your Raspberry Pi hangs a lot – but if it does, then that game is probably not intended to be played in your Raspberry Pi. But we’re giving you the option by the way. You have to keep in mind that Option 2 is only a slightly better version of unplugging and plugging the power source to your pi, which means it’s still a little risky for your SD card.

Step 1 (Skip when opting to Option 1)

  1. Solder the 2 male GPIO header to the P6 headers (labeled RUN) on your Raspberry Pi 3 board.

Step 2

  1. Insert the 2 male to female USB extender to your Raspberry Pi 3. Mount the other end of the extender to the USB slot in the case. Attach the heat sink to the Pi’s CPU.
  2. Without the Micro SD card inserted, screw your Raspberry Pi 3 at the 3 screw points at the bottom of Rasptendo Case (see illustration below)

Step 3

  1. Connect the other end of POWER SW jumper wires to the pins in the PCB labeled POWER. Connect the other ends at Pins 5 (GPIO3) and 6 (GND).
  2. Connect the RESET SW jumper wires to the pins in the PCB labeled RESET.
    Option 1. (NO SOLDER) Connect the other ends to Pins 13 (GPIO27) and 14 (GND).
    Option 2. Connect the other ends to the P6 headers (the ones you soldered labeled RUN)
  3. Connect the POWER LED+ jumper wire in the PCB labeled LED+. Connect the other end in Pin 8 (GPIO14).
  4. Connect the POWER LED- jumper wire in the PCB labeled LED-. Connect the other end in Pin 9 (GND).
  5. Screw the top component of the Rasptendo Case to its base.

Step 4

  1. Insert your Micro SD Card in your laptop, then download the image of RetroPie in https://retropie.org.uk/download/. Make sure to download the Raspberry Pi 2/3 version since you are going to install it on your Raspberry Pi 3.
  2. After downloading the .gz file, extract the file using your favorite extraction tool. Remember the directory where you extracted the .img file.
  3. Download the Etcher software and install. Click Select image then navigate to the extracted .img file. Click Select drive then choose the SD card. Click Flash! then wait for the process to finish.

Step 5

Now that you have assembled your Rasptendo game console, it’s time to install and configure some files for the POWER and RESET buttons to work. Fortunately, you can do this via online with a one line install using wget and bash in the Terminal.
1. Connect your Rasptendo console to a monitor and a keyboard before powering your Raspbery Pi.
2. Connect your Rasptendo to the internet. You may access the internet via LAN or via WiFi. (To configure your WiFi via Terminal follow this tutorial.)
3. Access the Terminal of your RetroPie by pressing F4 upon boot up.

In the Terminal, type the following command:

wget -O - "https://raw.githubusercontent.com/Argon40Tech/Super-Rasptendo-Case-Power-Switch/master/install.sh" | sudo bash

This will run a command that will automatically configure your Raspberry Pi 3 to access the Rasptendo Console POWER button. Your Raspberry Pi will automatically reboot in order for the changes to take place.

Step 6

After your Raspberry Pi has rebooted, test the Power button by holding it for a second. The LED will start blinking followed by your Raspberry Pi shutting down. You can turn on your pi by pressing the Power button again.

POWER
Raspberry Pi State Action Function
ON long press (>= 1 s) shutdown
ON short press (<1 s) nothing
SLEEP short/long press wakes Pi
RESET
Raspberry Pi State Action Function
Option 1 Option 2
ON short/long press soft reboot hard reboot
SLEEP short/long press nothing wakes Pi

If you encountered problems installing or you want to install manually, refer to a more detailed instruction from our GitHub page.