DIY Raspberry Pi Zero Handheld Game Console (Part 1)

Here is the rewritten article in a well-structured format:

The Over-discharge Protection Circuit of Raspberry Pi Zero Handheld Console

================================================================================

I recently had the opportunity to work on a project that involved creating a handheld console based on the Raspberry Pi Zero. One of the key components of this project was an over-discharge protection circuit, which I will outline in detail below.

Design Overview

---------------

The over-discharge protection circuit is essentially a comparator configuration that turns on when the output voltage falls below a certain threshold. This triggers a set-reset flip-flop clone to turn on its output, which then activates the npn transistor and pulls the Gate of Iz 44n mFET to ground. This increases the drain-to-source resistance, turning off the Raspberry Pi and disconnecting the battery through a power switch.

To make this circuit more permanent and compact, I used a piece of perf board as big as the Raspberry Pi itself to create the circuit. I also created a schematic of the circuit and soldered the components onto the perf board.

Components and Connections

-------------------------

The over-discharge protection circuit consists of several key components:

* One OPM (Op-Amp)

* One set-reset flip-flop clone

* One npn transistor

* One Iz 44n mFET

To connect these components, I used a combination of wires and soldering. The output of the OPM turns on when the input voltage falls below a certain threshold, which triggers the set-reset flip-flop clone to turn on its output.

Solving the Power Issue

----------------------

However, this circuit had one major flaw: it didn't provide enough power for the Raspberry Pi Zero. To solve this issue, I used an IC called XL 1509 to step down the input voltage from 5 volts to 3.5 volts. This allowed me to connect a 3.5-inch rear-view monitor that only works with voltages above 6 volts.

Powering Up the System

----------------------

After installing the necessary components and configuring the Raspberry Pi Zero, I was able to power up the system using a battery pack. The over-discharge protection circuit worked well, but I encountered some issues with audio quality.

Audio Quality Issues

-------------------

The old Raspberry Pi B offered audio through a 3.5 mm jack, but the Raspberry Pi Zero does not have such a jack. To solve this issue, I had to change the GPIO audio output pins in the configuration file and connect them to a RC filter circuit, followed by a potentiometer wheel, and finally to an amplifier.

Testing the System

-------------------

After completing the modifications, I tested the system using a keyboard, Wi-Fi dongle, and monitor. The system worked well, but there was one major issue: the audio quality was only mono. This was because we needed the other audio GPIO for the controls, which we had to activate in the RecalBox configuration file.

Creating a More Convenient Schematic

--------------------------------------

To make the circuit more convenient and easier to understand, I created a new schematic that included all the components and connections. This made it easier to follow along with the project and understand how everything worked together.

Conclusion

----------

In conclusion, the over-discharge protection circuit was an essential component of my Raspberry Pi Zero handheld console project. By using an OPM, set-reset flip-flop clone, npn transistor, and Iz 44n mFET, I was able to create a compact and efficient circuit that protected the system from over-discharging.

Future Improvements

-------------------

In future projects, I plan to add more features and improvements to the system. This may include using a more advanced audio amplifier or adding additional sensors to enhance the overall user experience.

Stay tuned for part two of this project, where I will house all the components inside the case and bring this project to an end!

WEBVTTKind: captionsLanguage: enwhen it comes to single board computers I think we can all agree that the Raspberry Pi zero offers the most attractive price performance size ratio so it's no wonder that it gets used in dozens of different projects my favorite one though is a handheld gaming console because who doesn't love retro gaming and in this two-part video series I will present you my take on the popular project so that you can easily create it as well let's get started for starters we need a 8 GB micro SD card which are firstly formatted to its standard settings then I downloaded the recal Box operating system from the GitHub page unzipped it at the root directory of the SD card and finally plug the SD card in the the P now it is time for power but such a 5vt charger is not portable and the micro USB cable is bulky so we might as well use the breakout pins pp1 for 5 volts and pp6 for ground for portable power I went with four classical anal Loop nickel metal hydride AA batteries that will later be placed inside the integrated battery compartment of my handheld when fully charged those have a voltage of roughly 1.4 volts and will be almost completely discharged at a voltage of 1.2 volts and since all of them will be placed in serus we are basically working with voltages between 5.7 volts and 4.8 volts which does partly exceed the USB standard voltage so I connected the Raspberry Pi to my lapen power supply to check whether it would work correctly with the given voltage range which it did because the utilized dcdc converter the p230 6 works with a maximum voltage of 6.5 volt but how can we prevent the batteries from over discharge you may ask for that I added a Max 667 voltage regulator I see after the main power switch which has a very low Dropout voltage and thus can generate a voltage of 4.5 volts by adjusting its set potenti cheter this voltage then Powers the mCP 602 rail to rail up amp and also directly connects to one non-inverting input as a reference voltage by adding a poent chameter to the inverting inputs I scaled the 4.8 volt minimum battery voltage to a value of 3.8 volts which means once the battery voltage falls under 4.8 volts the output of the OPM turns on since this is basically a comparator configuration the activated outputs then connects to the set pin of a set reset flip-flop clone which was created with another OPM and thus turns on his output as well and holds it high even when the battery voltage increases again this flip-flop outputs now finally activates the npn transistor and thereby pulls the Gate of Iz 44n mfed to ground which now increases its drain to Source resistance and thus turns off the rasbery pi and only after disconnecting the battery here through the power switch another power up is possible since this over discharge protection circuit worked pretty well I created a schematic of it and used a piece of perf board as big as the Raspberry Pi itself to create the circuit more permanently and most importantly as small and flat as possible and now that we have power we need a display for that I got myself a 3.5 in rear view monitor which sadly only works for voltages above 6 volts which means our battery voltage is too low but luckily after I slowly and care carefully remove the case of the LCD I realized that the circuit uses a XL 1509 IC to step down the input voltage to 5 volts so I removed this IC and solded the input wire directly to the output pin 2 and best of all it did work even with voltages from 4.8 volt to 5.7 volts but for the first PowerUp of the system a HDMI compatible screen is still mandatory after the installation was completed I switched the system to Rasberry Pi B because I could plug in my keyboard and Wi-Fi dongle simultaneously without having a USB hub laying around I used the keyboard to enter the network settings and typed in the exess information for my network after establishing a connection I started the software win SCP and locked into the p as a root user with the password recalbox route then I opened the command prompt and entered this command which enables me to edit the configuration file in the boot directory of the system there I added the hash symbol to all lines that include the word HDMI and activated over scan as well as the sdtv outputs before saving the changes in addition to that we also need to edit the recall box configuration file by simply changing the global. video mode to default now with those changes the Raspberry Pi zero can output its video signal through composite video cable and thus we can use the small RAR view LCD next is the audio which the old raspberry pip B offered through a 3.5 mm Jack but the zero type does not have such a jack instead we need to change the gpio audio output pins in the configuration file connect pin 13 to a RC filter circuit followed by a PO in chameter wheel and then finally to the P 8 403 audio amplifier since the IC works with voltages from 2.5 to an absolute maximum of 6 volts we can simply connect it to the battery voltage it's plus output to a light switch which connects to a speaker and a 3.5 mm Jack for headphones and finally the negative outputs to the other side of the speaker and Jack after powering up the system the audio quality was acceptable so I sold the passive component to perfboard and tested it out again but as you might already have noticed the sound is only mono not stereo the reason for that is that we need the other audio gpio for the controls which we firstly need to activate in the recal Box configuration file but only for player one after rebooting the system the controller acts according to this given representation of the gpos so it is basically an act of connecting the individual inputs to ground to achieve the described action later on though I will be using a perf board with coer strips on which the conductive material of the buttons will press in order to connect the input to ground and thus activate the action and just like that the general structure of the Raspberry Pi handheld was complete and already works like a charm but for your convenience I created a more easier to follow overall schematic of the system as well stay tuned for part two in which I will house all the components inside the case and bring this project to an end until then don't forget to like share and subscribe that would be awesome stay creative and I will see you next timewhen it comes to single board computers I think we can all agree that the Raspberry Pi zero offers the most attractive price performance size ratio so it's no wonder that it gets used in dozens of different projects my favorite one though is a handheld gaming console because who doesn't love retro gaming and in this two-part video series I will present you my take on the popular project so that you can easily create it as well let's get started for starters we need a 8 GB micro SD card which are firstly formatted to its standard settings then I downloaded the recal Box operating system from the GitHub page unzipped it at the root directory of the SD card and finally plug the SD card in the the P now it is time for power but such a 5vt charger is not portable and the micro USB cable is bulky so we might as well use the breakout pins pp1 for 5 volts and pp6 for ground for portable power I went with four classical anal Loop nickel metal hydride AA batteries that will later be placed inside the integrated battery compartment of my handheld when fully charged those have a voltage of roughly 1.4 volts and will be almost completely discharged at a voltage of 1.2 volts and since all of them will be placed in serus we are basically working with voltages between 5.7 volts and 4.8 volts which does partly exceed the USB standard voltage so I connected the Raspberry Pi to my lapen power supply to check whether it would work correctly with the given voltage range which it did because the utilized dcdc converter the p230 6 works with a maximum voltage of 6.5 volt but how can we prevent the batteries from over discharge you may ask for that I added a Max 667 voltage regulator I see after the main power switch which has a very low Dropout voltage and thus can generate a voltage of 4.5 volts by adjusting its set potenti cheter this voltage then Powers the mCP 602 rail to rail up amp and also directly connects to one non-inverting input as a reference voltage by adding a poent chameter to the inverting inputs I scaled the 4.8 volt minimum battery voltage to a value of 3.8 volts which means once the battery voltage falls under 4.8 volts the output of the OPM turns on since this is basically a comparator configuration the activated outputs then connects to the set pin of a set reset flip-flop clone which was created with another OPM and thus turns on his output as well and holds it high even when the battery voltage increases again this flip-flop outputs now finally activates the npn transistor and thereby pulls the Gate of Iz 44n mfed to ground which now increases its drain to Source resistance and thus turns off the rasbery pi and only after disconnecting the battery here through the power switch another power up is possible since this over discharge protection circuit worked pretty well I created a schematic of it and used a piece of perf board as big as the Raspberry Pi itself to create the circuit more permanently and most importantly as small and flat as possible and now that we have power we need a display for that I got myself a 3.5 in rear view monitor which sadly only works for voltages above 6 volts which means our battery voltage is too low but luckily after I slowly and care carefully remove the case of the LCD I realized that the circuit uses a XL 1509 IC to step down the input voltage to 5 volts so I removed this IC and solded the input wire directly to the output pin 2 and best of all it did work even with voltages from 4.8 volt to 5.7 volts but for the first PowerUp of the system a HDMI compatible screen is still mandatory after the installation was completed I switched the system to Rasberry Pi B because I could plug in my keyboard and Wi-Fi dongle simultaneously without having a USB hub laying around I used the keyboard to enter the network settings and typed in the exess information for my network after establishing a connection I started the software win SCP and locked into the p as a root user with the password recalbox route then I opened the command prompt and entered this command which enables me to edit the configuration file in the boot directory of the system there I added the hash symbol to all lines that include the word HDMI and activated over scan as well as the sdtv outputs before saving the changes in addition to that we also need to edit the recall box configuration file by simply changing the global. video mode to default now with those changes the Raspberry Pi zero can output its video signal through composite video cable and thus we can use the small RAR view LCD next is the audio which the old raspberry pip B offered through a 3.5 mm Jack but the zero type does not have such a jack instead we need to change the gpio audio output pins in the configuration file connect pin 13 to a RC filter circuit followed by a PO in chameter wheel and then finally to the P 8 403 audio amplifier since the IC works with voltages from 2.5 to an absolute maximum of 6 volts we can simply connect it to the battery voltage it's plus output to a light switch which connects to a speaker and a 3.5 mm Jack for headphones and finally the negative outputs to the other side of the speaker and Jack after powering up the system the audio quality was acceptable so I sold the passive component to perfboard and tested it out again but as you might already have noticed the sound is only mono not stereo the reason for that is that we need the other audio gpio for the controls which we firstly need to activate in the recal Box configuration file but only for player one after rebooting the system the controller acts according to this given representation of the gpos so it is basically an act of connecting the individual inputs to ground to achieve the described action later on though I will be using a perf board with coer strips on which the conductive material of the buttons will press in order to connect the input to ground and thus activate the action and just like that the general structure of the Raspberry Pi handheld was complete and already works like a charm but for your convenience I created a more easier to follow overall schematic of the system as well stay tuned for part two in which I will house all the components inside the case and bring this project to an end until then don't forget to like share and subscribe that would be awesome stay creative and I will see you next time