Getting Started | Raspians https://raspians.com/ All About Softwares Wed, 26 Feb 2025 02:00:30 +0000 en-US hourly 1 https://wordpress.org/?v=6.7.1 https://raspians.com/wp-content/uploads/2022/02/cropped-favicon-32x32.png Getting Started | Raspians https://raspians.com/ 32 32 30 Raspberry Pi Commands You Need To Know https://raspians.com/raspberry-pi-commands/ https://raspians.com/raspberry-pi-commands/#respond Tue, 23 Jan 2024 03:12:13 +0000 https://raspians.com/?p=3345 Read More]]> 30 Raspberry Pi Commands You Need To Know

While Raspberry Pi offers a desktop GUI interface, many prefer using the command-line for faster performance. If you’re one of those people, you must know some useful Raspberry Pi commands to make your life easier. This set of commands will help you manage the Raspberry Pi through the Terminal.

Also, if you are setting up Raspberry Pi without a monitor or Ethernet cable, learning these commands will help you a lot. So without any delay, let’s check out the 30 best Raspberry Pi commands you should know in 2021.

Here, we have included both basic and advanced commands for Raspberry Pi. Based on your expertise level, go through the list and put these commands to good use. Just expand the table below and check out the complete list of commands.

30 Essential Raspberry Pi Commands

1. Update Raspberry OS

sudo apt-get update 
sudo apt-get upgrade

These two commands allow you to update the Raspberry OS, both the desktop GUI and Terminal-based interface, to the latest build.In addition, they also updates existing packages, dependencies, and repositories.

If you have just set up a Raspberry Pi for the first time, make sure to run these commands one by one to get the latest version of the software.

30 Raspberry Pi Commands You Need To Know

2. Access Raspberry Pi Configuration

sudo raspi-config

Following the update commands, the command sudo raspi-config stands as an incredibly useful tool for Raspberry Pi users. This command grants access to the essential settings and configurations of your device. With it, you can activate the GUI interface, enable the VNC server for remote Raspberry Pi access, modify the screen resolution, activate SSH, and much more.

3. Network Configuration Details

ifconfig

Since networking is one of the most common applications for the Raspberry Pi, it’s crucial to be familiar with all the network configuration details. Enter the command mentioned above in the Terminal to quickly gather essential information such as Ethernet and Wi-Fi details, including IP address, MAC address, and more.

4. Open and Edit a Text File

sudo nano "filename"

or

sudo nano "filepath"

While it might appear straightforward, this command is actually one of the most frequently used when managing system files on the Raspberry Pi. If you need to edit the repository or add a new client to /etc/hosts, this command opens the file in the Nano editor. Remember, Nano operates primarily through keyboard commands; mouse usage is not supported.


You Might Like: Meet The Raspberry Pi 5


5. Restart Your Raspberry Pi

sudo reboot

This command is a quick and efficient way to reboot your Raspberry Pi. Simply execute it in the Terminal, and your Raspberry Pi will automatically shut down and then power itself back on, all within a matter of seconds.

6. Power Off Raspberry Pi

shutdown -h now

This command provides a straightforward method to power off your Raspberry Pi. Additionally, it offers the flexibility to schedule a shutdown. By replacing ‘now’ with a specific time, such as ’02:15′, you can set your Raspberry Pi to shut down at that exact time. It’s important to note that the Raspberry Pi operates on a 24-hour clock format.

7. Find a File

find / -name "filename"

The find command is arguably one of the most efficient tools for Raspberry Pi users. It enables you to swiftly search for a file throughout the entire system and reveals its location. This functionality can save a considerable amount of time that would otherwise be spent manually searching for a specific file.


You Might Like: Using Color Sensors


8. Run a Script

chmod a+x "filename".sh 
./"filename".sh

Occasionally, when you download a script file (with a .sh extension) and attempt to run it on your Raspberry Pi, you might encounter a “Permission denied” message in the Terminal. This happens because the script file hasn’t been granted executable permissions. To resolve this, use the first command to change the script’s properties to executable. After doing so, execute the second command to run the script, and it should function smoothly without any permission issues.

9. List Files and Directories

ls

The ls command, while basic, is an essential tool for Raspberry Pi users. It enables you to swiftly view the files and folders within the current directory. As you become more familiar with the Raspberry Pi, you’ll likely find yourself using this command quite frequently.

10. View Background Tasks

htop

In my opinion, htop stands out as one of the most useful commands for Raspberry Pi users. It’s akin to Windows’ Task Manager but operates within a Terminal-based interface. This command allows you to monitor various system metrics such as RAM usage, CPU load, the number of background tasks, uptime duration, and much more. A particularly valuable feature of htop is its ability to display the CPU temperature, which is crucial for managing Raspberry Pi’s performance. Additionally, it provides the Process ID (PID) for each task, enabling you to terminate any process using the kill command.

raspberry pi commands

11. Install a Program

sudo apt-get install "programname"

To install an app or utility on your Raspberry Pi, simply use the provided command. Substitute programname with the actual package name of the program you wish to install and press enter. The app will be promptly installed on your system.

12. Scan the Local Network

sudo apt-get install nmap 
nmap -sn 192.168.1.0/24

The nmap command is particularly useful for identifying the IP addresses of all devices connected to your local network. This command is especially beneficial if you’ve set up Pi-hole on your Raspberry Pi. To scan your local network, nmap is the tool to use. However, keep in mind that it doesn’t come pre-installed with Raspberry Pi OS, so you’ll need to install it first, using the installation command mentioned earlier.

13. Find the IP Address of Raspberry Pi

hostname -I

Knowing the IP address of your Raspberry Pi is crucial since it’s used in various scenarios, such as setting up VNC Connect or SSH connections. Simply execute the aforementioned command, and you’ll instantly receive the IP address of your Raspberry Pi.


You Might Like: Creating A Raspberry Pi Airplay Receiver


14. Download a File

wget "URL"

wget ranks as one of my favorite commands for the Raspberry Pi. It’s a built-in downloader for Linux-based operating systems. To use it, just type wget followed by the URL of the file you want to download and press enter. The file will be downloaded and saved in the current directory you’re in. It’s a remarkably convenient and efficient tool, don’t you think?

30 Raspberry Pi Commands You Need To Know

15. Check Raspberry OS Version

cat /proc/version

To find out which version of Raspberry Pi OS you are using, as well as to obtain detailed Linux information, simply run the command mentioned above. This will promptly provide you with the necessary details. Knowing your current OS version is particularly useful for downloading the appropriate packages and dependencies tailored to your system.

16. Check Current Directory

pwd

pwd is a straightforward command for Raspberry Pi users to determine their current directory. When navigating through numerous directories and subfolders, it’s easy to lose track of your exact location. By typing pwd in the Terminal, you can quickly find out the path of the directory you’re currently in.

17. Check Hardware Information

lscpu 
cat /proc/meminfo 
cat /proc/partitions

On the Raspberry Pi, you can access detailed hardware information using the commands mentioned above. The lscpu command is useful for gathering information about the CPU cores, such as their number, architecture, and speed. The meminfo command provides insights into the memory, including total RAM and available memory. Lastly, the partitions command gives information about the SD card size, detailing the storage capacity and partition layout of your Raspberry Pi’s primary storage medium.

18. Start GUI from Command Line on Raspberry Pi

startx

If you’re working in a command-line interface on your Raspberry Pi and wish to switch to the GUI desktop interface, the startx command is what you need. It’s important to remember, though, that this command requires the Raspberry Pi Desktop OS to be installed on your board. If you have the Lite OS version installed, the startx command won’t be effective. In my opinion, startx stands out as one of the best Raspberry Pi commands, particularly for power users who frequently switch between command-line and graphical interfaces.


You Might Like: How To Use Steam On Your Raspberry Pi


19. Create Directory

mkdir "foldername"

To create a new directory within the current folder on your Raspberry Pi, utilize the mkdir command followed by your desired folder name. This command will instantly create the specified directory. Afterwards, you can confirm its creation by using the ls command to view the contents of the current folder, including the newly created directory.

20. Delete Files or Folder

rm "foldername"

or

rm "filename"

The rm command is a standard Linux command used to delete files or folders directly from the Terminal. To use it, simply type rm followed by the name of the file or folder you wish to delete. This command provides a quick and efficient way to manage your file system on the Raspberry Pi.

21. Check Files by Extension

cat *.txt

To sort files based on their file extensions, such as TXT, PDF, etc., on a Raspberry Pi, the cat command can be used, although it’s primarily designed for displaying the contents of files. For sorting files, you might want to use a combination of commands like ls and grep. For example, ls | grep '.txt' would list all files with the ‘.txt’ extension. The cat command is great for concatenating and displaying file contents, but for sorting files by extension, ls and grep are more effective.

22. Elevated Permission

sudo su

On the Raspberry Pi, encountering a “Permission denied” message indicates a lack of necessary privileges to modify or access a particular file. To overcome this, you can enter the elevated permission mode by typing sudo su and pressing enter. This grants you superuser access, allowing you to execute commands without facing permission-related errors. Remember to use this elevated access responsibly, as it gives you the ability to make significant changes to the system.

23. Change File Ownership

sudo chown pi:root "filename"

A significant number of files are usually owned by the ‘root’ user. If you try to access these files without suitable permissions, an error is likely to occur. To remedy this situation, you have the option to alter the file ownership to the ‘pi’ user. This action demands the use of a specific command, which is particularly crucial when managing system files and folders via the Terminal. Altering the file ownership to ‘pi’ effectively provides you with the required permissions for these files.


You Might Like: Raspberry Pi VS Jetson Nano


24. Secure Shell

ssh pi@[IP Address of Raspberry Pi]

To connect to your Raspberry Pi’s terminal from another device on your local network, you can utilize the SSH command. This command works across various platforms, including Command Prompt, PowerShell, Linux Terminal, and Mac Terminal. Start by including your Raspberry Pi’s IP address in the command. When prompted, type ‘yes’ to proceed. Then, you’ll need to enter the password, which typically defaults to ‘raspberry’. This process allows you to remotely access your Raspberry Pi’s terminal with ease.

25. Extract Files

unzip "filename"

The unzip command is incredibly handy on the Raspberry Pi, providing a simple solution for extracting files. Regardless of the file’s size, simply type unzip followed by the filename, and the contents will be extracted right into your current directory. This utility makes managing compressed files straightforward and efficient.

26. Extract TAR Files

tar -cvzf "filename".tar.gz

Raspberry Pi OS comes equipped with the native capability to extract TAR files. By using the command provided and specifying the actual filename, you can easily extract the contents of the TAR file on the spot. This built-in feature simplifies the process of handling TAR archives in the Raspberry Pi environment.

27. Search for Text Within Files

grep "keyword" *.txt

The grep command is an exceptionally powerful tool on the Raspberry Pi, enabling you to search for specific keywords within various file types. Simply replace ‘keyword’ in the command with the actual term you’re searching for, and it will scan through all TXT files in the current directory for that keyword. This command is versatile enough to be used with other file formats too; just substitute TXT with PDF or any other file extension to tailor your search.

28. Change Password of Raspberry Pi

passwd

To update the default password on your Raspberry Pi, simply type in passwd and press enter. You’ll first need to input the current password, followed by your new chosen password. Once you’ve completed these steps, your Raspberry Pi’s password will be successfully changed.

29. Upgrade Raspberry Pi OS Distribution

sudo apt-get dist-upgrade

If there’s a new update available for Raspberry Pi and you wish to upgrade to the latest build, execute the aforementioned command. Be prepared for this process to take some time, so patience is key while your Raspberry Pi updates to the newest version.

30. Remove a Package

sudo apt-get remove "packagename"

To uninstall a program or package from your Raspberry Pi, use the remove command followed by the name of the package. This action will promptly remove the specified program or package from your system.

Final Thoughts

Mastering these 30 essential commands can significantly enhance your experience with the Raspberry Pi. From basic file management to system updates, and from network configuration to security enhancements, each command offers a unique function that contributes to the efficient and effective use of this versatile device.

Whether you’re a beginner learning the ropes or a seasoned user looking to streamline your workflow, these commands provide the foundational knowledge necessary to navigate and optimize your Raspberry Pi’s potential. Embrace these tools, and you’ll find yourself unlocking new levels of productivity and innovation with your Raspberry Pi.

]]>
https://raspians.com/raspberry-pi-commands/feed/ 0
The Guide To Raspberry Pi 4 RAM: Everything You Need To Know https://raspians.com/the-guide-to-raspberry-pi-4-ram/ https://raspians.com/the-guide-to-raspberry-pi-4-ram/#respond Thu, 23 Feb 2023 15:15:44 +0000 https://raspians.com/?p=2630 Read More]]> As one of the most popular single-board computers, the Raspberry Pi 4 has garnered a reputation for its versatility and robustness in various applications, including home automation, media centers, and small-scale server hosting.

However, to fully harness the power of this popular little device, it is critical to understand the specifications, especially the amount of RAM it possesses.

In this article, we explore the question, “How much RAM does a Raspberry Pi 4 have?” and provide a comprehensive answer that will hopefully assist you on your journey to getting the most out of your Raspberry Pi.

Raspberry Pi 4 RAM

How Much RAM Does The Raspberry Pi 4 Have?

The Raspberry Pi 4 is actually quite unique in the world of single-board computers because it allows consumers the choice of a range of RAM capacities. Other previous Raspberry Pi models were generally fixed at one RAM value that could not be changed. 

However, the Raspberry Pi 4 can actually be purchased with four different memory capacities. You can choose from a 1, 2, 4, or 8GB unit, depending on how much RAM you actually need.

Luckily, the price difference between each of these units is not actually too significant, so you don’t have to think too closely to choose the perfect one. The 1GB model is around $35, while the 4GB model is around $50.

However, this does not mean that you should simply opt for the largest option just because it is relatively cheap, as there are still plenty of reasons to buy a Raspberry Pi 4 with less RAM.

It all comes down to how much RAM you need and how you plan to use the Raspberry Pi 4.

What Is RAM?

Before we take a look at the potential benefits of each Raspberry Pi model, let’s take a minute to briefly go over exactly what RAM is. RAM simply refers to ‘Random Access Memory’ and is a vital part of creating a computer that runs efficiently. 

RAM is a temporary memory bank where your computer can store data that it needs quick and frequent access to without needing to return to the long-term (and slower to access) memory banks.

Think of it as your hard drive (or SD card in this case) being a filing cabinet for all your long-term storage, while RAM is like your work desk where you have everything you need frequently right at hand.

RAM is particularly important if you want to run several of applications and programs simultaneously.

Let’s say you wanted to edit a Word document that you had already saved, when you open the document it would move a copy over to the RAM so that your computer can quickly render your edits without having to write and rewrite your hard drive.

The RAM is also crucial when it comes to displaying information from your computer, as it helps the computer to render the visual aspects of applications and programs.

How Much RAM Do You Need From Your Raspberry Pi 4?

Now that we know how important RAM is in making a computer run optimally, we should take a look to find out how much RAM you need from your Raspberry Pi 4.

If you plan to use the Raspberry Pi 4 directly as a computer, and you plan to interface with it using a monitor and keyboard, then you should aim to grab a model with at least 4GB and preferably 8GB.

The reason for this is that some of the RAM will need to be dedicated to rendering everything on screen and ensuring that everything works smoothly on a visual level.

The 2GB variant of the Raspberry Pi 4 would also be adequate for interfacing via a screen and input device like a keyboard, but you will need to make sure that you are using fewer applications.

As well as this, you will also have to make sure that the resolution of your screen is not too high. If the resolution of the screen is high, the Raspberry Pi 4 will need to dedicate more of its RAM to rendering everything on the screen in high resolution. 

If you are planning to use your Raspberry Pi 4 for something a little more simple, or you simply aren’t planning on interfacing with the unit via a screen or an input device, then the Raspberry Pi 1GB model should be more than enough and will save you a few extra dollars.

For example, if you planned to use the Raspberry Pi 4 as a remote WIFI access point, then you would be just fine with the 1GB model because it does not need to dedicate any resources to rendering anything that is happening onto a screen.

But for more complex tasks such as gaming or web hosting, choosing a model with a higher memory capacity would be a wise choice.

buy raspberry pi accessories

To Wrap Up

The Raspberry Pi 4 is a very flexible model because it allows users an option of different RAM capacities to suit their specific needs.

Of the four available capacities, the 8GB option obviously offers the most capacity and processing ability, but this does not mean that the 1 GB model does not have some benefits of its own. The 1GB model is more affordable and is perfect for building smaller computers to handle small problems discreetly in the background.

If you found this guide helpful, you might like our posts on How To Set Up A Media Server, How To Backup Your Raspberry Pi, and Can A Raspberry Pi Run Windows 10?

For more insight into the Raspberry Pi 4’s RAM, check out the video below by Robotics Back End. As always, don’t forget to check out the FAQs just after the video.

Frequently Asked Questions

Is 1GB Of RAM Enough For The Raspberry Pi 4?

If you just want your Raspberry Pi 4 to perform some very simple tasks, then you could be well served by the 1GB model which offers enough to perform simple tasks without needing a screen.

Can A Raspberry Pi 4 Replace A PC Or Mac?

If your computing needs are simply web browsing and document editing, a Raspberry Pi 4 would work just fine for you. When it comes to more complex tasks such as video editing, or heavy application use, there is nothing like a well-set-up PC or Mac.

Can You Upgrade The RAM On The Raspberry 4?

Unfortunately, though Raspberry Pi computers are highly customizable the Raspberry Pi 4 model can not be upgraded when it comes to RAM.

The reason for this is that the RAM of the unit is soldered directly into the unit, which means that it is impossible to remove it and replace it with a larger RAM capacity.

]]>
https://raspians.com/the-guide-to-raspberry-pi-4-ram/feed/ 0
How To Build A Robust Raspberry Pi Dashboard https://raspians.com/raspberry-pi-dashboard/ https://raspians.com/raspberry-pi-dashboard/#respond Tue, 21 Feb 2023 00:08:36 +0000 https://raspians.com/?p=2123 Read More]]> A great Raspberry Pi dashboard allows you to get the most out of your raspberry pi device and create an unbeatable user experience when it comes to tasks such as easy home automation or displaying pages and video.

It is a bit of an intermediate task, but we will take you through it step by step in the guide and make it as easy and as intuitive as possible for you.

How To Build A Raspberry Pi dashboard

How To Build A Robust Dashboard With Raspberry Pi:

Before We Get Started

Here’s a bit of ‘light reading’ to get you started 😉 It would definitely be beneficial for you to become more familiar with these guides to make the process a little easier:

If you aren’t already familiar with the Raspberry Pi, we also recommend you acquaint yourself with it before moving on.

As far as basic Raspberry Pi skills go – you will need to know how to access the command terminal with SSH, burn an operating system to SD card, and connect your device to a network.

The Hardware And Parts You’re Going To Need

For this project, you will need the following:

  • Raspberry Pi
  • LED Backpacks
  • Breadboard
  • Sharp knife
  • Male/male jumper wires
  • USB Wi-Fi Dongle
  • Wire
  • Stepper and DC Motor HAT
  • Electrical tape
  • 5V 2amp supply for power
  • Buck converter or 3.3V regulator
  • Soldering tools
  • Chalkboard foamboard or dry-erase foamboard
  • Female/female jumper wires

Testing And Assembly

You’re going to need to test the HAT and LED backpacks before you start assembling. Simply follow these guides to test them once they are assembled: 

You can then go through this guide and install the Python LED backpack library, then test it using the Raspberry Pi backpacks. 

Assembling The Dashboard

  1. Build or write the dashboard using your chalk or dry eraser (don’t use permanent markers, as you will want to update and change labels.
  2. Trace out every display’s shape, then cut out the corresponding hole in the board. 
  3. Tape the displays and motor to the dashboard, being careful not to tape over delicate parts.
  4. Check your foamboard to see if your foamboard is less than ¼ inch thick, you can poke a hole in it to fit the stepper gauge through. If not, you will need to cut a hole.
  5. If you have standoffs, use them to cover the Raspberry Pi HDMI port. Use electrical tape to cover the HDMI port if you don’t have standoffs to hold the motor HAT. 
  6. Carefully solder the wires or headers onto the GND, SCL, SDA, 5V, and 3.3V pins to allow the 12C bus and LED to connect.
  7. Press the motor HAT onto the Raspberry Pi’s GPIO.
  8. Using the same method you used when testing, wire the auto gauge steppers and motor HAT terminals together.
  9. Now, connect the power supply (5V) to the motor HAT’s negative and positive power terminals.
  10. Connect the SCL header, clock, SCL pin, SDA pin, and data to the Raspberry Pi SDA header.
  11. ***You can power ~1-3 LED backpacks straight from the Pi by connecting each backpack to the GND negative power and the positive to the 3.3V power. 
  12. If you’re using the 1.2” 7-segment backpack, connect it to the 5V.
  13. ***Use a dedicated 3.3V power supply if you are using more than 3 backpacks, as the Pi won’t have enough power to run it correctly.  
  14. The dashboard should now be assembled, and you will need to check through everything to ensure it is in good working order. Carry out tests to make sure you don’t run into any problems.
  15. Now, you will need to label your dashboard with your chosen metrics. 

The Software

Now, you will need to start installing the correct software. However, you will first need to make sure of two important things:

  1. Your Raspberry Pi runs the newest Jessie Lite or Raspbian Jessie operating system
  2. The Raspberry Pi is connected to the internet via a wireless network connection (this is important as software dependencies can be installed).

You should also ensure that you read over the aforementioned guides to know your way around Raspberry Pi, as you will need to know how to do a few things. 

Once these have been checked, you can move on to the software installation process. 

Installing The Software

Now you will need to install the necessary software. We will go through this process step-by-step and provide the coding for you to input. 

Install the dashboard software to the Pi terminal from GitHub and run this command:

sudo apt-get update

sudo apt-get install -y git build-essential curl python-pip python-smbus python-dev

git clone https://github.com/adafruit/Pi_Physical_Dashboard.git

cd Pi_Physical_Dashboard

sudo pip install -r requirements.txt

Once you run the final command, you should see pip print telling you that the installation has been successful and is being cleaned up. This message should start with this: Requirement already satisfied (use – – upgrade to upgrade): requests in /usr/lib/python2.7/dist-packages

You will notice that the software is installed in the /home/pi/Pi_Physical_Dashboard folder. You can run it with its main.py Python script.

Before doing this, it should be configured. 

Configuring

Configuring

Configure the dashboard software by editing its config.ini file within a text editor. You can use the nano editor on the Pi itself by inputting this command in the Pi_Physical_Dashboard folder: 

nano config.ini

Once inside, you will see lines beginning with # – these are comments that explain the configuration. 

This is an example of a seven-segment widget configuration:

# Example of a seven segment display called ‘cpu’.  The type is SeveSegmentWidget,

# the I2C address of the device is specified as 0x74, and the number of digits

# to show after the decimal point is set to 0.

#[cpu]

#type = SevenSegmentWidget

#address = 0x74

#decimal_digits = 0

To enable the widget, you just need to remove the comments by simply inputting this:

# Example of a seven segment display called ‘cpu’.  The type is SeveSegmentWidget,

# the I2C address of the device is specified as 0x74, and the number of digits

# to show after the decimal point is set to 0.

[cpu]

type = SevenSegmentWidget

address = 0x74

decimal_digits = 0

In this case, the widget has the name cpu, a type, and several sets of seven-segment display-specific options. You can scroll through the configuration file and notice numerous widget types (such as AutoGaugeWidget or AlphaNum4Widget).

Add your own widget configuration to the config.ini. An example of this would look like the following:

[foo]

type = SevenSegmentWidget

address = 0x72

[bar]

type = AutoGaugeWidget

motor_id = 1

Now, you need to save your configuration by pressing Ctrl-o, enter, and Ctrl-x. This will also exit you from the nano

Using It

After configuration, you will be able to check everything out. Run the program by finding the Pi_Physical_Dashboard file, and type in the following command: 

sudo python main.py

Don’t be alarmed when you notice all the automotive gauges have been moved to the left – this is normal! 

If the Dashboard Doesn’t Check The Output

You should check if you can find a reason for the dashboard to be failing if it doesn’t look right. Check through the codes to make sure no mistakes were made. 

Take a look at the 12C address for each widget to ensure that it has been input correctly. You can easily use i2cdetect to do this and see if you get the address that you are expecting. 

Ensure The Server Is Working Correctly

Access the server widget from the web browser to check on it. Simply open your browser and go to http://raspberrypi:5000/widgets (or where “raspberrypi” is, input the name you gave your Pi”. 

If that fails, you will need to check the router and look at the IP address. It should be assigned to the Pi. The widgets should be in a JSON format like the following: 

{

“widgets”: [ 

{

“description”: “Seven segment LED backpack widget. Can display simple numeric values\n in the range of -999.\n”,

You can now set the widget value by making an HTTP POST request here at http://raspberrypi:5000/widgets/widget_name. 

The request can be made in the form of a curl command, which you might need to install. Once installed, you can set the value of the widget by using a command like this one: 

curl -d value=55 http://raspberrypi:5000/widgets/cpu

If the widget value doesn’t update, double-check to ensure you’re using the correct widget name. You should also see if a helpful error message is printed out to help you figure out the issue.

**Please be aware that every widget will have a different range of values set. Check these values before making any changes. 

Below are some examples of what values set with curl might look like:

# Set an alphanumeric widget called foo to have a value COOL:

curl -d value=COOL http://raspberrypi:5000/widgets/foo

# Set a bicolor bargraph widget called bar to be 35% illuminated:

curl -d value=35 http://raspberrypi:5000/widgets/bar

# Set a bicolor bargraph widget called bar to be 75% illuminated red:

curl -d value=475 http://raspberrypi:5000/widgets/bar

# Set an auto gauge widget called gauge to be at 35%:

curl -d value=35 http://raspberrypi:5000/widgets/gauge

This should sort out any issues you might be having!

buy raspberry pi accessories

Final Thoughts

As you can see – building a dashboard for your Raspberry Pi requires a few steps and some familiarity with the Raspberry OPi, however, is definitely worth learning how to do as it can help you keep track of everything, make awesome displays, operate your connected devices and generally make your RPi experience more streamlined and enjoyable. Hopefully, this article has helped you – good luck!

]]>
https://raspians.com/raspberry-pi-dashboard/feed/ 0
How to Store Data in Raspberry Pi https://raspians.com/how-to-store-data-in-raspberry-pi/ https://raspians.com/how-to-store-data-in-raspberry-pi/#respond Mon, 07 Nov 2022 04:44:36 +0000 https://raspians.com/?p=1604 Read More]]> How to Store Data in Raspberry Pi

There’s a lot of information out there on how to store data in Raspberry Pi, but not all of it is comprehensive. 

This is why in this guide, we will walk you through everything you need to know about storing data in your Pi, the different methods you can use, and how to choose the right storage option for your needs.

So, let’s dive right in!

Does Raspberry Pi Have Storage?

First things first, if you’re new to SBCs (Single Board Computers), you may be wondering how to save data in Raspberry Pi and whether or not it even has inbuilt storage.

Unfortunately, the Raspberry Pi doesn’t have any onboard storage, which means you can’t store data directly on the board.

But don’t worry! 

Even though it doesn’t have its own dedicated storage, the Raspberry Pi can still use external storage devices to save data. We’ll go over the different storage options you can use with your Pi later on in this guide.

How to Store Data on Raspberry Pi

Let’s move on to how to actually store data on the device.

As we’ve just mentioned, since the Pi doesn’t have any internal storage, you’ll need to use external storage solutions to save data on your Pi. 

The most common external storage methods used with the Raspberry Pi are:

Let’s take a closer look at each of these storage options:

1.) SD Cards

sd card storage for raspberry pi

SD cards are one of the most popular storage solutions for Raspberry Pi (see also ‘Raspberry Pi Models Comparison: Which Pi is Right for My Application?’). They’re small, portable, and relatively inexpensive, which makes them perfect for use with the Pi.

In terms of capacity, standard SD cards can range from 2 GB to 32 GB. If you need more storage than that, you can also get SDXC cards that have storage capacities of up to 2 TB.

One thing to keep in mind with SD cards is that they’re not the most reliable storage option. They’re prone to corruption and data loss, so it’s important to make regular backups of your data if you’re using an SD card as your primary storage solution.

2.) USB Flash Drives

usb flash drive storage for raspberry pi

Another popular storage option for the Raspberry Pi is a USB flash drive. USB flash drives are larger and more expensive than SD cards, but they’re also much more reliable.

In terms of capacity, USB flash drives can range from a mere 8 GB all the way up to 1 TB. Some manufacturers also produce USB flash drives with a whopping 2 TB capacity!

One thing to keep in mind with USB flash drives is that they’re not as portable as SD cards. They’re larger and require a USB port to use, which means you can’t just take them with you on the go like you can with an SD card. 

Plus, because they poke out from the side of the Pi, they can be more susceptible to damage and might not fit in a Pi case as snugly as an SD card would.

To save data in Raspberry Pi using a USB stick, just follow these steps:

  • Connect the USB flash drive to your Raspberry Pi (see also ‘How To Connect Raspberry Pi To Laptop’).
  • Format the USB flash drive using the FAT32, exFAT, or another Pi-supported file system (see also ‘What Is NFS?‘). 
  • Now, find out where the USB drive is mounted. If you’re going to use the Terminal, follow this tutorial, and if you’re going to use Python, try this guide instead.
  • Finally, use Python or any app to collect data and store it in the USB drive.

Top Tip: Remember, formatting will erase all data already on the SD card, so be sure to back up anything you don’t want to lose! 

Here’s a great video walkthrough on this method:

3.) External HDDs

If you need even more storage than what an SD card or a USB flash drive can provide, you can also use an external hard drive. These are especially useful if you intend on using your Pi as a NAS box or media server due to its huge storage boost.

External hard drives are larger and more expensive than both SD cards and USB flash drives, but they’re also the most reliable and expansive storage options.

In terms of capacity, external hard drives can range anywhere from 500 GB to a whopping 10 TB. 

And the best part?

Most modern ones are usually a convenient case of just plug-and-use, especially if you’re using newer versions of the Pi. The external HDD should mount automatically and can be used to store data in your Raspberry Pi with little to no effort.

4.) Cloud Storage

If you don’t want to store your data on a physical storage device, you can also use cloud storage. 

Cloud storage is a service that allows you to upload and store files on a remote server. This means you can access your files from anywhere in the world, as long as you have an internet connection.

There are a number of different cloud storage services to choose from, but some of the most popular ones are Microsoft Azure, Amazon AWS, and Seafile & Nextcloud.

Unfortunately, the biggest drawback of cloud storage is that it increases the power requirement of the Pi and also limits the Pi’s installation location (it can never be too far away from the WiFi). 

To use cloud storage with your Raspberry Pi, you’ll need to:

  • Sign-up for an account with a cloud storage provider.
  • Set up the device to communicate with the server using the provider’s preferred method (usually via an HTTP API).
  • Finally, connect to the server and start storing your Pi’s data in the cloud.

5.) NAS (Network Attached Storage)

The last option for storing data on your Raspberry Pi is to use a NAS (Network Attached Storage) device.

NAS devices are external hard drives that connect to your home network and can be accessed by any computer or mobile device on that network.

This makes them ideal for sharing large amounts of data between multiple devices or for backing up data from all your devices to a single location. 

The only drawback is that NAS storage systems require a stable and reliable data connection 24/7. A temporary loss of connection while accessing files may lead to data being corrupted.

To use a NAS with your Raspberry Pi to store data as you would with any other file locally, you’ll need the following: 

  • A router with an Ethernet connection (wireless will work, but it’s usually much slower).
  • An external hard drive or a dedicated NAS device connected to the router.
  • The appropriate communication protocol for your Network Attached Storage installed on your Pi (usually this is SMB).
  • The NAS is properly mounted into your device’s file system.

Here’s a complete guide on how to access your NAS drive on your Raspberry Pi.

buy raspberry pi accessories

The Takeaway: How to Store Data in Raspberry Pi

As you can see, there are a number of different ways that you can store data in Raspberry Pi (see also ‘How To Install Chrome On Raspberry Pi‘). Which method you ultimately choose will depend on your specific needs and requirements.

If you just need to store a small amount of data, then an SD card or USB flash drive will probably suffice.

But if you need more storage space, or if you need to share data with multiple devices, then you might want to consider using an external hard drive or NAS device.

And if you need to access your data from anywhere in the world, then cloud storage might be the best option for you.

]]>
https://raspians.com/how-to-store-data-in-raspberry-pi/feed/ 0
Raspians Resources & Gear Hub https://raspians.com/raspians-resources-gear-hub/ https://raspians.com/raspians-resources-gear-hub/#respond Mon, 10 Oct 2022 05:49:00 +0000 https://raspians.com/?p=4249 Read More]]> Raspians Resources & Gear Hub


From home automation, wifi-extenders, investing hubs and home audio through to alarms, display screens, robotics and retro gaming – the projects you can put together with your Raspberry Pi gear are simply phenomenal.

When it comes to figuring out what you can do with a Raspberry Pi, you’re really only limited by your knowledge, equipment and imagination!

Luckily, I can help you with getting the best equipment and giving you the ‘know-how’, but as for how far your imagination goes – that’s up to you.

The list below showcases my favourite places to get Pi-gear, my recommendations for some of the best courses as well as a few more bonus recommendations for your Pi journey.


RASPBERRY PI GEAR:

  • Sunfounder: The theatre of dreams for Raspberry Pi gear lovers! Everything you could ever want, in one place. Free shipping, free returns and a discount on your first order!
  • Pi Supply– Pioneers of the ‘Maker Movement’, Pi Supply have over 800 top-rated Raspberry Pi products and add-ons, many of which they’ve created themselves!

RASPBERRY PI LEARNING:

  • Tech Explorations: The mother of all learning resources for not only the Raspberry Pi, but also countless other avenues of electronics, software, programming and robotics.
  • Raspi-Config: Axel, a state-certified computer scientist with over 15 years of experience, will skillfully take you through 25 video lessons ranging from the basics of the Raspberry Pi and introductory software projects to exciting hardware projects and home automation. 

There you have it. Not only are these the brands and resources that I use for my Raspberry Pi work, but if you choose to use any of them via these links – you’ll be helping me keep this website going (at no extra cost to you!) So thank you!

]]>
https://raspians.com/raspians-resources-gear-hub/feed/ 0
How To Create A Raspberry Pi SD Card Image https://raspians.com/how-to-create-a-raspberry-pi-sd-card-image/ https://raspians.com/how-to-create-a-raspberry-pi-sd-card-image/#respond Wed, 05 Oct 2022 02:32:49 +0000 https://raspians.com/?p=1308 Read More]]> Making a backup image of your Raspberry Pi SD card can be very useful. After all, your data and system OS are on this tiny and fragile piece of plastic, which isn’t very safe.

Even if you don’t plan on ever using your backup, it’s always a good idea to have one in case something happens to your original SD card.

Luckily, creating a Raspberry Pi SD card image copy is really simple and only takes a few minutes. 

In this guide, we’ll show you the step-by-step process of how to create a Raspberry Pi SD card image on major platforms like Windows, Linux, and macOS.

So, let’s get started!

How To Create A Raspberry Pi SD Card Image

Why You Should Consider Creating A Raspberry Pi SD Card Image

Before we get into the process of creating a Raspberry Pi SD card image copy, it’s important to understand why you should even bother doing this in the first place.

  • For starters, a Raspberry Pi SD card image backup is an exact copy of your current SD card. This means that if something happens to your SD card like it gets corrupted or damaged, you can simply restore the image and be back up and running in no time.
  • Another reason to create a backup image is if you plan on making major changes to your Raspberry Pi system (see also ‘Backup your Raspberry Pi: How To Save And Restore Files‘). This way, if something goes wrong, you can always revert back to a previous version by restoring the image.
  • Lastly, having a backup image can be useful if you want to clone your current Raspberry Pi setup. For example, if you want to create an identical system but with a larger SD card, you can use the image backup to do this quickly and effortlessly.

Now that we’ve gone over some of the reasons why you should create a Raspberry Pi SD card image, let’s get into the actual process.

How To Create Raspberry Pi SD Card Image

The first thing you need to know is that the process of creating a Raspberry Pi SD card image is different for every OS.

So, make sure to follow the set of instructions for the system you’re going to be using to make an image of Raspberry Pi’s SD card.

Windows

Because Windows is the most popular operating system out there, let’s start with this OS first.

The process for creating a Raspberry Pi SD card image on Windows is actually pretty simple. 

  1. To get started, all you need is a free program called Win32DiskImager which you can download for free from SourceForge.
  1. Once you’ve downloaded and installed the program, launch it and insert your SD card into your computer (you might need a USB adapter if your computer doesn’t have an in-built SD card slot). Make sure you’ve formatted your new Raspberry Pi SD card first.
  1. Then, find the drive partition which corresponds to your SD card and take note of the partition letter (you’ll need this later in step 5).
  1. Now, open Win32DiskImager and choose a name and the location for your image. Just make sure you have free space on your disk where you’re going to create the backup.
  1. Next, choose the device/drive partition you want to create a backup image of.
  1. Click on “Read” to initiate the copying process. This process can take anywhere between a few minutes to a couple of hours depending on the amount of data you’re backing up.
  1. Wait till the process is finished and voila! You’re done creating a Raspberry Pi SD card image on Windows.

The video below is a great walkthrough on how to do this:

Linux

If you’re running a Linux-based operating system, the process is a little more complicated. However, it’s still pretty straightforward and only requires a few commands.

First, open up a terminal window and find out which device your SD card is (see also ‘How To Format A Raspberry Pi SD Card‘). To do this, type in the following command:

  • sudo fdisk -l

This will list all of the drives and partitions on your computer. Look for the entry that corresponds to your SD card. 

On Linux, if you’re using a USB adapter, this could be something like “/dec/sdX.” But if your PC already has an in-built SD card reader it might be named something like “/dev/mmcblkX.”

Now after finding out the device name for your SD card, we can get started on creating the image.

To do this, type in the following command in the terminal, replacing X with your device name:

  • sudo dd bs=4M if=/dev/sdX of=/home/Myimage.img

Just don’t forget to replace the destination (of for output file) and device name (if for input file) while typing in the command. 

This process might take a while to complete depending on the size of your SD card. But once it’s done, you’ll have an image file on your desktop that you can use to restore your Raspberry Pi SD card.

MacOS

If you’re using a Mac, the process is similar to Linux as it’s based on Unix. However, there’s a slightly different command that you need to use.

Instead of using the “sudo fdisk-I” command that we used in the Linux terminal, here, we will need to use “diskutil list” because fdisk doesn’t work in the same way in macOS.

Other than that, the rest of the process is the same as mentioned above in the Linux part, so be sure to follow the same steps if you’re using a Macbook to create Raspberry Pi SD card images.

buy raspberry pi accessories

Final Thoughts

As you can see, the process of creating an image of your Raspberry Pi SD card is pretty simple no matter which operating system you’re using.

Just be sure to use the correct commands or programs for your OS and you’ll be able to create an image file without any issues.

And make sure to keep the backup in a safe location like an external hard drive or keep multiple copies so you always have it ready to restore your Raspberry Pi SD card anytime you want.

So if something goes wrong or you just want to start from scratch, you can easily do so without having to go through the hassle of setting up everything all over again!

]]>
https://raspians.com/how-to-create-a-raspberry-pi-sd-card-image/feed/ 0
How To Stop Raspberry Pi From Sleeping? https://raspians.com/how-to-stop-raspberry-pi-from-sleeping/ https://raspians.com/how-to-stop-raspberry-pi-from-sleeping/#respond Thu, 18 Aug 2022 02:25:43 +0000 https://raspians.com/?p=870 Read More]]> The Raspberry Pi can be used for many different purposes, such as a WiFi extender, media center, or even as a remote control for robots and to play games. 

But what do you do if you want to keep it on all the time even when you’re not using it?

Here are some top tips on how to stop Raspberry Pi from sleeping.

How To Stop Raspberry Pi From Sleeping?

What Is Raspberry Pi Sleep Mode?

The Raspberry Pi doesn’t have a sleep mode like the ones we often see on more complete operating systems like Windows and macOS. 

Instead, the Pi has a feature called “Screen Blanking” which simply shuts off your display and substitutes it with an empty screen. 

But, unlike the sleep modes, we often see in our laptops and desktops, during screen blanking, the hardware for the Pi is still on and the HDMI cable and ports remain supplied with power. 

How Do I Turn Off Screen Blanking On Raspberry Pi?

Suddenly facing a completely blank screen while using your Raspberry Pi can interrupt your work and can be annoying. 

Luckily, newer releases of the Raspberry operating system allow users to change their Raspberry Pi sleep settings and screen blanking defaults very easily. 

Here are 3 quick and easy ways to disable Raspberry Pi sleep mode/screen blanking:

  1. Disable The Setting Through The Desktop 

Here’s how to disable Raspberry Pi from sleeping and prevent its screen from blanking through the desktop UI:

  • First, start your Raspberry Pi and get into the Configuration menu. You can open this menu by clicking on the Raspberry icon present in the left corner of the screen. 
  • Next, move to the Preferences menu and click on the Raspberry Pi configuration option. 
  • Once the Raspberry Pi Configuration menu is opened, tap on the Display tab. 
  • You should be able to see the “Screen Blanking” option there. Select the “Disable” option and then click “Ok” to continue with the process.
  • When you exit the Raspberry Pi Configuration, the system will ask you to reboot it to implement the changes. 
  • Just accept and wait for your computer to restart (see also ‘How to Restart Raspberry Pi Remotely‘). Now your Raspberry Pi should function smoothly without screen blanking even during periods of inactivity.
  1. Disable Screen Blanking Through The Terminal

If instead, you’d like to utilize the terminal interface to stop Raspberry Pi from going to sleep, this method can also be used to get the same results. Here’s how:

  • Start by typing sudo raspi-config in the command terminal. This should bring up a command line interpretation of the Preferences settings.
  • Use the arrow keys to select the Display Options submenu and press enter.
  • After entering the submenu, move over to the “Screen Blanking” setting and press the enter key.
  • Select the “No” option on the next screen when asked if you’d like to enable screen blanking and then hit enter once again.
  • Lastly, finish saving the settings and reboot your device for your new settings to take effect.
  1. Use A Screensaver 

Finally, the last option you have to stop your Raspberry pi screen from sleeping is to use a screensaver to trick your device into thinking your system isn’t idle even when you’re not using it. 

Xscreensaver is one that works perfectly for the Pi and can be installed through the Add/Remove tool in the desktop interface. 

Simply go to the Preferences section and select “Add Software”. Then type xscreensaver in the search box and press enter. Look for the software titled “xscreensaver” and download it. 

Alternatively, you can also simply download it through the terminal by typing Sudo apt install xscreensaver

After installing and rebooting your device for the changes to take effect, you’ll be able to find the xscreensaver module in the Preferences options and should be able to run it whenever you want to avoid screen blanking.

The quick video below is a great walkthrough on exactly how to do this:

How Do I Wake Up My Raspberry Pi 4?

If your device tries to hibernate or sleep, the most sure-fire way to fix the issue is to simply turn your Raspberry Pi off and reboot it (see also ‘How To Reboot Raspberry Pi‘). However, this is something we’d like to use as a last resort.

Most of the time, if your display has suddenly gone completely blank, you may be able to wake it up with a few button presses on the keyboard. Any key should do the trick, but the “spacebar” and “escape” keys are usually recommended.

What To Do When The Raspberry Pi Screen Isn’t Turning On?

Now, if you’ve properly set up your Raspberry Pi and the screen still isn’t turning on, there are a couple of things you can do to fix the issue.

Check the power supply first. If it’s not getting enough power, it won’t be able to run the screen. Make sure that all the cables are plugged in correctly and that the power source is working.

If the power supply is fine, then the next thing to check is the SD card. It’s possible that the card isn’t inserted properly or that it’s corrupted. Try removing the card and reinserting it. If that doesn’t work, try using a different SD card.

If you’ve tried all of that and the screen still isn’t turning on, then there could be an issue with the screen’s HDMI cable. Try unplugging it and plugging it back in. If that doesn’t work, try using a different HDMI cable.

Finally, if none of the above works, then there could be an issue with the Raspberry Pi itself.

Consider getting it checked by a professional to see if there’s an issue with the hardware or simply replace the device if you own an extra Pi.

How to Solve The Raspberry Pi “Currently Cannot Show Desktop” Error?

Arguably, one of the most frustrating errors, especially when you have something important to do on your Raspberry Pi. 

Let’s have a look at a few ways to solve this issue:

  1. Change Screen Resolution

Although it’s possible that the Raspberry Pi “Currently Cannot Show Desktop” problem could be due to some internal fault, sometimes this error might pop up because your Pi’s display settings don’t match your current display’s native resolution.

To fix this, consider connecting to another monitor temporarily and try changing the resolution in the configuration settings to see if it makes a difference. Sometimes, shifting to the highest possible or the display’s native resolution is the only way to solve this issue.

Alternatively, you can also connect your Pi through an ssh connection then run raspi-config and change the resolution settings. Just make sure your Pi has the ssh interface as “enabled” before using this method.

  1. Free Up Space in Root Partition

Another reason why your Raspberry Pi might not be responding could be because you have run out of disc space. Type in the command df – h in the terminal to assess the storage space in every partition.

Check whether your partition root has space or is filled with your data. If later is the case, consider cleaning up the root partition to make some extra space or simply move to a larger microSD card. 

buy raspberry pi

That’s It!

I hope that’s helped you troubleshoot a few issues and get you back on track!

Don’t hesitate to reach out with any questions or comments 🙂

]]>
https://raspians.com/how-to-stop-raspberry-pi-from-sleeping/feed/ 0
How to Start Raspberry Pi In Safe Mode? https://raspians.com/how-to-start-raspberry-pi-in-safe-mode/ https://raspians.com/how-to-start-raspberry-pi-in-safe-mode/#respond Thu, 04 Aug 2022 03:30:15 +0000 https://raspians.com/?p=804 Read More]]> Most tech-enthusiasts know that the Raspberry Pi is a cost-effective, debit-card-sized computer that can help you learn to code and explore programming in computer languages like Python and Java, or do simple things like connecting to your PC or television.

However, sometimes, your Raspberry Pi might not boot up properly, or it may start acting up. That’s when you need to know how to start the Raspberry Pi in safe mode.

In this guide, we will show you everything you need to know about starting your Raspberry Pi in safe mode. We will also take a look at what safe mode is, what it does, why you might need to boot in safe mode, and what to expect along the way.


So, let’s get right into it!

how to start a raspberry pi in safe mode

What Is “Safe Mode” In Raspberry Pi?

Before we jump into the guide, let’s first take a look at what safe mode is and what it does.

Numerous operating systems, including Android, macOS, and Linux, implement safe mode, and Raspberry Pi is no exception. 

In simple words, safe mode is a diagnostic boot-up option for the raspberry pi that starts the operating system with minimum functionality. This can be extremely useful if you’re trying to troubleshoot or fix operating system issues or glitches with your raspberry pi.

However, it’s worth noting that, in safe mode, the raspberry pi will boot up with the default settings. So, if you’ve made any system changes, they will be reverted back to the defaults.

Why Boot Raspberry Pi In Safe Mode Anyway?

If you fail to start your raspberry pi or it crashes unexpectedly, malware, glitches, or viruses may be to blame. 

Luckily, using your device in safe mode offers a quick and efficient way to identify and fix most boot-up problems. 

For example, if you’re having issues with the graphical interface, starting in safe mode will revert the settings back to the defaults and this may fix the issue.

Similarly, if you’re having issues with a specific program or piece of hardware, starting in safe mode can also help you to isolate and locate the issue.

Yes, a few applications may not work as efficiently after booting your system in safe mode, and your system may get slower; but you’ll be able to remove corrupted files for good and fix your setup fairly quickly. 

How To Start Raspberry Pi In Safe Mode? 

You can start your raspberry pi in safe mode via four different methods. We’ll explain each one in detail below, and you can go with the method that you find the easiest.

Method 1

The first method requires you to start directly into bash. 

1.) Unplug the device and take out the card 

2.) Mount it on your PC

3.) Open the drive and add  init=/bin/bash by editing the existing command (Note: Make sure you add the space before init

4.) Insert the card back into your device and start it. You may notice that the command line is not visible at this point. However, pressing enter should make it pop up. 
Your card may not be writable. However, you can simply remount it as writable by using: mount -o remount,rw /dev/mmcblk0p2 /

5.) Now get to the bottom of the issue and disconnect the pi after exiting the bash session

6.) Reinsert the card in your PC and remove the command typed in step 3 

There you go! You have successfully booted your device in safe mode. If method 1 feels intimidating or doesn’t work for some reason, you can try the following methods.

Method 2

Those who have updated their Raspberry pi can follow a quick method to start the device in safe mode. 

This involves simply inserting the card into another device and putting an empty file named “ssh” inside the boot partition.

Note that this is the only partition you’ll be able to find on a Windows PC. 

Method 3

Traditionally, adding “S” at the end of the command line helps get into safe mode. This works by informing init about the run level “S” or “single user” mode. You’ll find the command line in /boot/cmdline.txt

Method 4

Here’s another way to boot your Raspberry pi in safe mode. 

1.) Mount the card to your macOS or Window SD card reader 

2.) Type init=/bin/sh by editing the cmdline.txt file 

3.) Enter “su” when the prompt shows up to log into the device in safe mode 

raspberry pi safe mode

What To Expect After Booting Raspberry Pi In Safe Mode? 

When you boot raspberry pi in safe mode, the system loads minimal services and drivers to keep the system from acting up. 

Therefore, you may not be able to access all system functions. Here’s what to expect after starting your device in safe mode:

  • Depending on your settings, you may not be able to access the networking option
  • The audio may get disabled
  • There is a good chance you’ll only be able to see videos with low resolution

What To Do After Starting Your Raspberry Pi In Recovery Mode? 

Once you boot your system in safe/recovery mode, here are a few steps you should consider taking: 

  • You can run an antivirus application if you think a virus is affecting your computer’s performance. This will allow you to easily remove malware, which can otherwise be challenging to achieve when the device is refusing to boot up normally. 
  • If your computer was acting strangely after installing a new program, now is your chance to uninstall it. 
  • If you sense your system’s drivers are unstable, the safe mode in Raspberry Pi allows you to update them. 
  • If your computer keeps crashing after taking all the essential steps, its hardware may have an issue. This would require you to take it to a professional technician for help. 

How To Know If Your Raspberry Pi Is Booting

By checking out the LEDs, you can easily determine if your raspberry pi is booting correctly (see also ‘How To Dual Boot Raspberry Pi‘). 

Look at the green and red LED lights on your device. The green signifies activity, and the red indicates power. 

Three green lights on raspberry pi indicate Ethernet status – if linked. 

What To Do When You Can’t Start Raspberry Pi In Safe Mode?

If you follow all the steps correctly, you should be able to successfully boot your system in safe mode. 

If, however, you fail to start raspberry pi in safe mode for any reason, the two most common culprits could be: 

  • Maybe you typed the wrong command line. Make sure you edit the command line appropriately and type the correct version to start it in safe mode.
  • An underlying hardware issue with your device may be contributing to the problem. Check your raspberry pi’s components to figure out if something is out of place or have it looked at by a professional.
buy raspberry pi

Hopefully, this article has fixed your Raspberry Pi problems and you’re now ready to explore some of the amazing projects available to the humble Pi! Check this video out to get inspired:

]]>
https://raspians.com/how-to-start-raspberry-pi-in-safe-mode/feed/ 0
How To Partition A USB Drive https://raspians.com/how-to-partition-a-usb/ Wed, 16 Feb 2022 16:37:58 +0000 https://raspians.com/?p=255 Read More]]>
How To Partition A USB

If finding out how to partition a USB has been a problem of yours, that’s what we’re here for. 

The process is actually fairly simple when it comes down to it, but to get through everything is where the issue starts! 

Not to worry, though, as every question you could possibly have about how to partition a USB is within this article to make your life much easier and more stress-free.

How To Partition A USB Flash Drive?

If you want to store data on multiple devices, then you should consider using a USB drive. This is because they are very portable and can easily fit into your pocket or bag. They also come in various sizes, from 4 GB to 128 GB, depending on your requirements.

However, if you want to transfer files between two computers, you might run into some issues. 

For example, if you try to copy a file from one computer to another, it won’t always work. In such situations, you might need to use a tool called Partition Magic. It will allow you to create partitions on the USB flash drive so that you can store different types of data on it.

In this article, we will show you how to partition a USB drive. We will start by explaining what partitions are, and why you would need them.

Then, we will explain how to create one with Partition Magic. After that, we will discuss how to format the new partition.

What Are Partitions?

A partition is an area where you can store information. You can think of it as a folder for storing data. If you have a hard drive, there is only one partition. 

However, when you put a USB flash drive inside your computer, you can create several partitions on it. Each partition has its own name, size, and location.

The main reason for creating these partitions is to store different kinds of data in separate areas.

For example, you could have one partition for documents, one for music, and one for videos. This way, you don’t have to keep all your important documents together. 

Instead, you can place them in their respective folders. It will become clear how easy it is to USB drive partition your drive. Make sure you have enough disk space.

Why Do I Need To Create Partitions On A Flash Drive?

Why Do I Need To Create Partitions On A Flash Drive

There are many reasons why you might want to create partitions on a USB flash drive. One of the most common ones is to make sure that you can access all the data stored on it. 

When you connect a USB flash drive to a computer, Windows automatically creates a single partition on it. However, this partition doesn’t contain any space for other files. Therefore, you cannot add more files to it.

You can solve this problem by creating additional partitions on the USB flash disk. These partitions can be used to store different types of data. For example, you can create a partition for pictures, a second one for movies, and the third one for music.

Another reason why you might need to create partitions on a flash drive is if you want to install the software. There are certain programs that require at least three partitions.

For example, the popular program Paragon Hard Disk Manager requires at least three partitions.

Finally, you may want to create partitions on your USB flash drive if you want to back up your data. This way, you can save copies of your data in multiple locations. Your disk utility is the most important thing. 

Partition Magic: How To Create And Format Partitions With Partition Magic

The first thing you should do after connecting your USB flash drive to your computer is to download and install Partition Magic. Once installed, open the application and click “New”. Make sure to connect to the right USB port. 

The next screen will ask you to select the type of partition you want to create. Click “Primary Master” and then press Next, using the enter key.

Now, you will see a window asking you to choose the number of partitions you want to create. Select the number you want and then press Next.

Now, you will see another window asking you to specify the starting point of each partition. Select the beginning address of the first partition and press Next.

When you finish specifying the addresses, click Finish.

Now, you will see a message informing you that the operation was successful. Click OK to close the window.

After clicking OK, the application will start formatting the selected drive. Wait until it finishes before disconnecting the USB flash drive from your computer. Once done, you can use the drive normally. And there are your USB partitions done.

How To Use Gparted Live CD To Create Partitions On Your USB Flash Drive

If you don’t feel like installing Partition Magic or using the live CD version of Gparted, you can also use the latter method to format your USB flash drive.

The only difference between these two methods is that when you use the live CD version of the tool, you won’t be able to access the files stored on the drive.

To begin with, insert the USB flash drive into your computer. You will now see an icon on your desktop indicating that there is a new device connected. Right-click on the icon and select “Eject”.

Next, remove the USB flash drive from the computer and plug it into your laptop again. Then, right-click on the icon on your desktop once more and select “Open File Explorer”.

In the left pane of the file explorer, navigate to the folder where you saved the GParted live CD. Double-click on the.iso file and wait for the program to load. When finished, click “Run”.

You will now see a window prompting you to select the language you would like to use during installation. Press Enter to accept the default option.

You will now see a window asking you whether you would like to install all updates automatically. Click Yes to proceed.

Next, you will see a list of packages that have been downloaded by the installer. Scroll down to find the package named “GParted” and double-click on it.

A window will pop up informing you that the package has been successfully installed. Click Close to exit the installer.

On the main menu, click on “Live CD Mode” and then click “Start Installation”.

Your system will reboot and boot into the live CD environment. In this mode, you can perform any operations you need to without affecting the operating system. Click on the “Install GParted” button to start the installation process.

Wait until the installation completes and then click on the “Finish” button to return to the main menu. From here, click on “Exit” to end the session.

buy raspberry pi

Final Thoughts

Creating partitions on your USB flash drive is one of the most important things you can do if you plan on storing data on it. 

It allows you to store multiple files in different folders and makes it easier to transfer them back and forth between computers.

If you are planning to buy a new USB flash drive, make sure to choose one that supports FAT32 file systems. This way, you can create as many partitions as you want.

However, if you already own a USB flash drive, you should always check its manufacturer’s specifications before using it. Some devices may not support certain file systems, which means you might run into problems later on. 

Also, make sure that the size of the storage space you decide to allocate to each partition matches the actual capacity of the drive. Otherwise, you could end up wasting valuable space.

If you still have trouble creating partitions on your USB flash drives, try downloading the latest version of Gparted Live CD. It is available at no cost and works just fine.

https://www.youtube.com/watch?v=1bEiFWSLjsk
]]>
How To Connect To The Internet On Your Raspberry Pi Via An Ethernet Cable https://raspians.com/how-to-connect-to-the-internet-on-your-raspberry-pi-via-an-ethernet-cable/ Wed, 16 Feb 2022 16:33:02 +0000 https://raspians.com/?p=338 Read More]]> So you’ve got yourself your shiny new Raspberry Pi, congratulations. And now you’ve got it, you get to explore all that it has to offer.

How To Connect To The Internet On Your Raspberry Pi Via An Ethernet Cable

The first thing you might want to do is connect your Pi to the internet. This guide focuses on how to connect your Raspberry Pi to the internet via an Ethernet cable.

Raspberry Pi Overview

To make sure we’re all on the same page, let’s run over the basics of the Raspberry Pi.

The Raspberry Pi is a device that can fit in your pocket. It’s as big as the standard smartphone, give or take a few inches, and it definitely doesn’t have the same price tag.

The Pi is designed to connect to any big screen such as a monitor for a PC/MAC or a television set (see also ‘How To Fix Screen Tearing‘). When plugged in, you can use a basic computer mouse and a basic computer keyboard to navigate your Pi.

So, what’s it for? Well, multiple things.

You can code, and program, and this is what the Pi was initially intended for. Popular programs like Scratch and Python (see also ‘How To Install Python Libraries‘) were the perfect platforms for such tasks.

But it grew and grew, and now you can use it as a media center, a desktop (with slightly lesser function), you can use it as a gaming device or server (see also ‘How To Install Spigot‘), as a remote control, and even stream videos.

Ethernet And Their Cables Overview

To understand Ethernet, you need to understand the bigger picture.

Ethernet, in a nutshell, is an avenue for communication from a device, such as a computer, to a network. It is a connection portal.

Let’s run with the computer as an example. The computer wants to connect to a certain network, say your home network.

To do this, it needs some way of transferring data between the two. Sometimes this can be wireless, other times this is Ethernet. More specifically, an Ethernet cable.

An Ethernet cable is an actual cable. This is how the data goes from one to the other. The only other relevant term here is ‘protocol’. A protocol is the words that govern a network. In other words, it’s how they communicate with one another.

Ways To Connect Raspberry Pi To The Internet

There are a few ways that you can connect your Raspberry Pi to the internet.

  1. Use an Ethernet Cable.
  2. With newer Pi models, you can connect to the internet via a Wi-Fi connection.
  3. With newer Pi models, you can connect to the internet via a mobile hotspot.

How To Connect Your Pi With An Ethernet Cable

So if you choose to connect your Pi to a network by using an Ethernet cable to get an internet connection, you need to know what you’re doing.

We have broken it down in to easy to manage steps. Follow each step to the letter, and you will successfully connect your Raspberry Pi to a network via an Ethernet cable.

  1. You will need something called a USB-Ethernet Adapter.

A USB-Ethernet Adapter provides a connection port for when the device is lacking.

If one device has a USB port but no Ethernet port, and the other has an Ethernet port, a USB-Ethernet Adapter is what you need to connect the two.

  1. You will also need something called a Crossover Cable or a Crossover Adapter in order to engage the wired connection.

Crossover Adapters are handy little things that connect two separate electronic devices together succinctly.

  1. Join the dots. Plug in the USB-Ethernet Adapter to the Crossover Adapter. Connect the Ethernet adapter port to the Pi port.
  2. You’re done. Your Pi via Ethernet connection is now live. You have a stable and secure internet connection. An Ethernet is one of the better ways of connecting to any network via your Pi. You can protect your IP address, and even save yourself from hackers.

Using A Wired Network V.S. A Wireless Network: Tips And Tricks

Wired networks are considered faster than a wireless networks. But, they can sometimes still be slow. If you are struggling with a poor connection, there are some things that you can try to speed it up.

Of course, this list is not exclusive and there are more methods to dig into. These are just some top tips and tricks.

  1. Anything that is connected to the network will affect the speed of the network.
    If you are trying to use one particular device while other devices are also accessing the network, think about shutting them down.
    That way, your device will be the only one accessing the network and therefore, hopefully, get a faster connection.
  2. You can change providers. This is overlooked by many people.
    You get stuck in a rut with a company, and it’s too much hassle to switch. But it doesn’t have to be a hassle. You can research the fastest speeds in your area and act accordingly.
    You never know, you might even find a better deal than your current commitment.

Ethernet Advantages

The advantages of Ethernet, there are a few noticeable things to highlight.

  • Faster

Ethernet is generally considered faster than a WiFi connection.

  • Dependable

The Ethernet cable is a direct cable into the internet. That makes it more dependable than any other form of network connection that you might come across.

  • Secure

Any data that is transferred through an Ethernet connection, is inaccessible except for one method. The only way that you can gain access to that data is by literally being in the same room as the Ethernet cable and physically attaching to it.

Ethernet Disadvantages

Like anything, there are disadvantages as well.

  • Nondeterministic
  • Not as many deals

Summary

And that’s a wrap.

To connect your Raspberry Pi to the internet via an Ethernet connection, there are a few extra purchases that you’re going to have to make.

These are a USB-Ethernet Adapter and a Crossover Adapter. This is, of course, alongside the Ethernet cable that you will need.

Once you are in possession of these two devices, you can then proceed to make that all important Ethernet connection. You may find your overall connection speed increases and is more reliable by a noticeable degree.

You may also find an increase in overall connection security with an Ethernet connection. This is because it is much harder to hack than a Wi-Fi network.

]]>
How to Configure Controller RetroPie https://raspians.com/how-to-configure-controller-retropie/ Wed, 16 Feb 2022 10:06:47 +0000 https://raspians.com/?p=459 Read More]]> RetroPie is a free, open-source software project that allows users to play classic video games on their computers. It was originally developed by Team Xecuter in 2009 as an alternative to the commercial emulators available at the time, which were often difficult or impossible to install on many systems.

The project has since been taken over by the community and continues to be actively maintained. Popular RetroPie games include Super Mario Bros., Contra, Metroid, Tetris, Doom, Pac-Man and more.

These games have withstood the years and continue to be loved by the public.

If you are here, you probably need to figure out how to configure controller RetroPie. Fear not – we have all the answers. Let’s check out the answer below.

How to Configure Controller RetroPie

Configuring Controller RetroPie

To do controller configuration, you first need to download the latest version of RetroPie from its official website.

Once you’ve installed RetroPie, you’ll need to make sure your controller is connected to your computer before continuing. If it isn’t already, plug it into your USB port and turn it on.

You will need to hold down any button on the game pad or keyboard, then the name should appear in the bottom corner. It should then open onto the configuration menu.

This will open up the input devices menu. Scroll down until you see “Controller”. Select it and press the OK button. This should bring up a new window where you can select your controller. Press the OK button again to confirm.

Now, let’s go back to RetroPie and click on the Settings icon (the gear). A new window should pop up asking for permission to access your system settings. Allow it to proceed.

Now that you’re in the settings menu, scroll down until you see “Controllers” and then click on it. In the next window, you’ll want to select the controller you just plugged in. Press “Ok” when finished and close the window. That’s basically all there is configuring controllers.

The Concept of the RetroPad

RetroPad is not a physical thing, and it does not have physical buttons. When you are configuring your controller in EmulationStation, the setup script for the RetroPie automatically begins to configure RetroArch with the same controls.

RetroArch controls the actual emulation program RetroPie uses. You will use a virtual joystick and four keys as input while playing through these games (see also ‘How Does Parsec Work?‘). These virtual buttons work exactly like they would if you were using your physical controller.

The RetroPad  does not exist as a physical thing, but is actually a concept that exists in RetroArch only. 

These RetroPads have an ABXY layout much like a Super Nintendo Entertainment System controller, as well as four shoulder buttons and dual analog sticks, just like a Sony DualShock.

When configuring, you do not need to map every button on the RetroPad to a real world button that you have. It doesn’t matter if the controller you are using has fewer buttons on it than a DualShock, as the RetroPad will also have fewer buttons.

What if RetroPie Doesn’t Recognize My Controller?

If RetroPie doesn’t recognize your controller, you will first need to establish that there are no hardware faults that should be obvious. Any hardware faults could cause the disconnection. Check that the cable is fully inserted into the port without using excessive force.

Any excessive force could lead to the cable breaking, or damaging the port. You check that the controller is not broken by testing it out on a different device. If the controller does not work on another device, there is a good chance that your controller is faulty.

If, however, your controller seems to be working fine with other devices, there is the possibility of your controller simply not being compatible with the Pi. Try unplugging your controller and re-inserting it, restarting your Pi if needed, and running RetroPie again.

If this problem persists, contact the developer directly for assistance, or you may be able to get support through third party online communities like Reddit. There will always be other people who have experienced the same issue, and you are likely to find answers to your issues there.

Another option would be to try a different set of controllers; some models might not work at all or only partially. Again, try connecting several types of controllers to your Pi, including those made specifically for use with Raspberry Pi. Some popular controllers include:

  • SNES (Super Nintendo Entertainment System)
  • Pikmin 2 (Nintendo Gamecube)
  • XBox 360 Controller
  • Playstation Dualshock 4
  • PS4 Controllers

Delayed or Slow Controller

If the connection between your controller and program seems to be delayed, don’t worry. This is a pretty common issue for wireless controllers, but can also happen to wired ones, too. To isolate the concern, you should try using the controller on a different device.

Once you’ve confirmed that the controller works on another device, then you know the problem isn’t caused by the controller itself.

The last option is that the controller is incompatible with the operating system. In this case, you’ll want to contact the manufacturer of the controller for help. They may provide a driver for the controller in their software package.

How Do I Use A USB Keyboard With RetroPie?

There are many ways to connect a keyboard to your Raspberry Pi. One method is to use a USB hub. Another way is to use a USB extension cord.

The advantage of the latter is that you can move the keyboard around easily while still having full access to the ports on the back of the Pi.

A third option is to use an external keyboard. These keyboards usually plug directly into the USB port on the front of the Pi. However, they do require power from the Pi’s USB port as well as the keyboard’s own battery.

Depending on how much power you’re willing to give up, these options can be quite useful.

Final Thoughts

Controllers play an important part in playing games and immersing ourselves in different worlds. If you are having trouble configuring your controller in RetroPie, follow the steps mentioned above and hopefully your issue will be resolved.

Alternatively, if you are unable to solve the issue, seek help on places like Reddit where there are threads dedicated to resolving issues like this. Good luck!

]]>
How To Power Raspberry Pi 4 https://raspians.com/how-to-power-raspberry-pi-4/ Tue, 15 Feb 2022 15:57:41 +0000 https://raspians.com/?p=425 Read More]]> To provide your Raspberry Pi 4 (or other computer) with juice, you’ll want a power supply that can deliver at least three amps and five volts over a USB Type C wire. A phone or laptop charger that can output at least three amps and 5 volts over USB Type C should do the job.

How To Power Raspberry Pi 4

You can also power your Pi 4 off of a power bank that you’d use to charge a phone or tablet. There are many options for powering your Raspberry Pi – and some are more appropriate than others, depending on your needs. With this guide, you’ll learn all about powering your Raspberry Pi 4!

What Kind Of Power Adapter Do I Need For Raspberry Pi?

A Raspberry Pi 4 does not have a power switch. To turn on a Raspberry Pi 4, you simply plug it into an outlet.
When you want to turn it off, shut down the operating system first, then unplug the power cord.

Power switches are available for Raspberry Pi 4s, but don’t forget that you need to shut down the operating system before turning off the power.

Raspberry Pi 4 uses an external power connector.

Which USB Type C Cables Work With Raspberry Pi?

Any USB Type-C to USB Type-C cable works fine with the Raspberry Pi 4. However, if you use an e-marked USB 3.0 or USB 3.1 cable, it won’t charge your Raspberry Pi 4 (see also ‘How To Safely Overclock Raspberry Pi 4‘). You’ll need to use a regular USB 2.0 cable instead.

A lot of people use USB-C cables for charging purposes. However, some of them do not work properly. You should avoid buying these types of cables if possible.

Ways To Power Your Raspberry Pi

A charging hub can be a useful and quick desktop power solution. It allows you to charge multiple devices simultaneously.

Solar energy is great for powering things. A solar panel charges batteries, and the batteries charge up a Raspberry Pi.

A solar-powered charger is a great tool to use when you’re out camping or hiking. You can charge your phone, tablet, or other devices using this type of setup. This product is very useful if you want to be self-sufficient while traveling.

A boost converter takes low voltage (2.4v) from rechargeable AA batteries and boosts it up to 5v. This allows you to run your RPi off of AA batteries without having to connect it to a wall outlet. However, this method requires more power than using a standard RPi power supply.

Boost converters are very easy to use. There are two wires in and two wires out. This means you can connect them to any device that needs 5 volts or more. These devices include most phones and tablets.

Most Raspberry Pi robots use a battery pack. This is because batteries are cheap and easy to get. However, if you want your robot to be really powerful, then you need to buy a bigger battery pack.

A PoE injector connects a Raspberry Pi to the Internet via a standard Ethernet cable. It also provides power to the Pi over the same cable.

A UPS is a battery backup system that provides an uninterruptible power supply to equipment connected to it. In this case, the UPS keeps the Raspberry Pi powered up even when there is no external power source available.

The recommended power supply requirements for the Raspberry Pi range between 700mA and 2.5A. This means that most people should be fine using a standard 5V micro USB cable.

However, if you’re running a lot of peripherals, such as a keyboard, mouse, or monitor, then you may need an additional power supply.

Power consumption varies greatly depending on what you’re doing. Video playback uses more power than idle or booting. Some devices draw more power than others, such as keyboards and mice.

Low Power Warning

The Raspberry Pi can run on a lower power supply, but it may be unable to perform some tasks. A yellow lightning bolt appears in your screen indicating an under-voltage alert.

A powered USB hub is recommended if you want to connect heavy peripherals to your Raspberry Pi.

GPIO Power

Raspberry Pi is powered by an external supply. To get stable power, you need to use an adapter or a cable. You can also power things attached to the Pi, using the GPIO pins – such as hats. This method is dangerous because if you short out the pins, you could damage the board.

A hat is a piece of hardware that sits over the GPIO pins. It provides additional safety features such as power filtering and ESD protection.

The Raspberry Pi 4 has a total of 40 GPIO pins. The pin count remains the same as previous versions, but there are some improvements to the layout. There are now four additional I2C/SPI/UART connectors available. This means that you can connect up to eight devices to each port.

The GPIO 5V pins are typically powered by the 5V rail. You can connect them to a 5V source to supply additional power to things connected to the pins – but you can’t power the Pi itself like this.

Why Won’t The Pi Power Up?

The Raspberry Pi 4 is non-standard and won’t work with some USB-c cables. This might be the cause.
A compliant charger is a better option. Non-compliant chargers may damage your device if you use them.

A full-featured USB-C cable uses an e-marker to identify itself as such. Shorting the two CC lines prevents the cable from detecting the Raspberry Pi and powering it.

Need A Fan? Power And Heat On Raspberry Pi

The new Raspberry Pi 4 draws more power than previous models. At idle, it consumes about 17% more power than the 3B+ model. At full throttle, the 4 consumes about 19% more power than the older model.
You should use a fan or heat sink to avoid overheating (see also ‘Does Raspberry Pi 4 Need A Fan?‘).

Conclusion

Getting the right power supply for your needs is essential. Hopefully, this guide has helped you out!

]]>
How to Turn on the Raspberry Pi 3 After Shut Down https://raspians.com/how-to-turn-on-the-raspberry-pi-3-after-shut-down/ Tue, 15 Feb 2022 15:12:14 +0000 https://raspians.com/?p=409 Read More]]> The Raspberry Pi 3 is a handheld, pocket sized electronic device. It can code, it can game, it can make videos. 

Regardless of what it can do, it comes without a traditional power button. 

With that in mind, you may be wondering how to turn it on after the power has been turned off.  This guide will explain the various methods that you can turn your Pi 3 on after it has been turned off. 

How to Turn on the Raspberry Pi 3 After Shut Down

Raspberry Pi 3 Overview

Raspberry Pi 3 is a 2016 and onwards rendition of the original 2012 Raspberry Pi. 

It is newer, faster and has improved features. 

The main features are as follows.

  • 4 USB Ports
  • Bluetooth and WiFi
  • 40 Pin GPIO
  • 10/100 LAN Port
  • HDMI Port
  • Camera Port
  • Video/Audio Jack
  • SD Card Slot
  • Quad Core 1.4 GHz

How to Turn on Your Raspberry Pi 3

Raspberry Pis go against standard device conventions that you might have grown accustomed to. They do not have a power button. That means, they have no magic switch to turn them on. This may feel counterintuitive, but stick with it. 

In place of a traditional power on button command, Raspberry Pis have a different system. 

You have to plug in a cable in order to get power to the Pi 3 device. This power cable is inserted into the micro USB port. And, it is the answer to all your questions. 

If this is the first time powering up, and subsequent times thereafter, you have to tick a few boxes in order to ensure you don’t break your device before you get your feet on the ground. 

1. The Micro SD card. It’s important. This needs to be inserted in the Pi 3 device. Before it is inserted, the Micro S card needs to have the most update Raspbian operating system downloaded and ready to go. 

2. The HDMI cable needs to be connected to your chosen monitor or screen. Your Keyboard and Mouse also need to be plugged in and ready to go. If you are using an Ethernet cable, you got it, plug it in. 

3. When, and only when, all of the above boxes have been ticked and thoroughly checked, can you plug in the micro USB power cable. 

Now, your Raspberry Pi 3 will be fully awake and aware. You can tell that everything is working as it should be, because the device actually gives you the green light, meaning go, or good. However you wish to interpret it, green light is a good sign. 

How Do You Shut Down the Raspberry Pi 3?

You have a few different options when it comes to the shut down of your Raspberry Pi 3. 

Okay, firstly and most importantly, here is what absolutely not to do. 

Don’t just unplug the micro USB power cord. It’s so tempting, we know. But, please don’t do it. You can break your Pi 3 so easily by doing this.

Yes, it is a quick and easy way to shut the whole thing down, but it can also corrupt your files, your data, and even the inner workings of the Raspbian operating system. You don’t want that to happen. 

So, now we have covered what not to do, let’s move on to what is safe to do. 

1. Type the shutdown command. This can be ‘sudo shutdown -h now or sudo poweroff. 

This is the official shut down device command, and can be typed from your USB keyboard. 

2. Use the Menu Options. This is a useful knowledge nugget for whenever you may be using your Raspberry Pi 3 without a keyboard device. 

First, press start to bring up the menu bar. 

On the menu bar, there is an option that says ‘shutdown’. 

This is the one you want. Press it. 

This is another safe way to turn off your Pi 3 without faults and repercussions. 

3. SSH. SSH, or secure shell, is a way to remotely access your device from another device controlled by you. 

If you set your Pi 3 up on the SSH, you can control it from afar. So, logic then follows that, while connected to the network via the SSH connection, you can shut the Pi 3 down with a remote command. You can use the same shutdown command as we saw above, 

How To Turn on Raspberry Pi 3 After Shutdown

There are no complicated methods here.

If you have shut down your Pi 3 correctly and safely, then you have an easy task ahead of you. Sit back and relax. 

All that you have to do is plug back in the power cable. This is of course assuming that everything we previously talked about is still in place. This includes the HDMI cable, the keyboard, mouse, and the Micro SD card. 

Making Your Own Power On/Power Off Button

There is another option. It is possible, with the later models, to create your own power button for the Pi. 

You will need a power button and a python code. All of which you can find on the Raspberry Pi instructional website link below. 

Link

When you have successfully installed your power button, you can switch off your Raspberry Pi 3 safely, just like all of your other electronic devices. 

This may seem like the easier option overall. However, it does take a precise coding knowledge and a certain confidence. You can learn all of these skills, of course. 

Final Thoughts

 And this concludes our guide for how to turn on your Raspberry Pi 3 after shutdown action has been completed. 

If you’re feeling particularly adventurous and tech savvy, you can make your very own power button for your Pi 3. This might save you a lot of time and hassle and give you a snappy, easy, extremely convenient way to turn your device off and on again safely.

You won’t lose any data, you won’t corrupt any files, and you certainly will not damage the Raspbian operating system. 

If not, then no worries. There are options for you too. You can access your Pi 3 remotely via SSH, and enforce the shutdown command from an external device. 

If you don’t have access via SSH, you can simply type the command into your keyboard that is connected to your Raspberry Pi 3 device. 

]]>
How To Reboot Raspberry Pi https://raspians.com/how-to-reboot-raspberry-pi/ Tue, 15 Feb 2022 14:19:58 +0000 https://raspians.com/?p=376 Read More]]> One of the first things everyone should learn how to do on their Raspberry Pi is how to turn it on and off again. 

If you don’t know how to, then don’t worry – we’ll show you how with this handy guide!

Command Line

If you prefer to use terminal commands, there are several options to do so. 

In fact, for many Linux users, terminal commands are the preferred way to do many things. They’re often the most convenient way too, as Linux GUI tools are rarely as good as those on other operating systems.

Rebooting the Raspberry Pi through the command line is exceptionally easy! All you’ll need is access to a terminal window. You can do this directly on the machine itself, or remotely through SSH.

To reboot your Raspberry Pi, type the following:

sudo reboot now

This will instantly reboot your Raspberry Pi.

To shut down your Raspberry Pi instead, use this command:

sudo shutdown now

As you may have guessed, this tells the Raspberry Pi to shut down immediately.

How To Reboot Raspberry Pi

Pull the Plug

Disconnecting the power cable will turn off the Raspberry Pi instantly. You should always shut down your Raspberry Pi safely. 

Pulling the power cord out of your computer could corrupt your SD card or damage your hard disk drive. If you need to power the Raspberry Pi off by pulling the cord, be aware that it could result in data loss and corruption of your OS.

You likely won’t;t have to worry about any physical damage to the Raspberry Pi itself, but it’s always something to think about. 

Therefore, you shouldn’t really ever pull the power cord from the device without making sure that you’ve shut the system down properly beforehand.Desktop GUI

You can easily reboot your Raspberry Pi by using the desktop guide too. Simply use the mouse to click on the Raspberry Pi logo in the bottom left of the screen. It’ll be where the Windows/Start menu is on Windows.

Click this, then click “Shutdown”. A menu with three options will appear: Shutdown, Reboot, and Logout. To reboot the Raspberry Pi, simply select the reboot option!

For many people, using the GUI might well be the easiest way to reboot their Raspberry Pi. If you use the GUI, you’ll need to have physical access to the Raspberry Pi, so that you can use a keyboard and mouse. Of course, this is also possible to do remotely over VNC!

How To Turn Raspberry Pi On

A Raspberry Pi can be turned off by unplugging it from the power supply. Plugging it back in when you are ready to turn it on will put it back online.

What Is A Raspberry Pi?

Raspberry Pi is a credit card sized computer that plugs into your TV or monitor via HDMI cable. 

It has a single USB port and a micro SD slot. The board comes preloaded with the Linux operating system. It is very cheap (about $35) and ideal for beginners who want to get started with programming.

How Do I Install Raspbian On My Raspberry Pi?

You will need to have an account at raspberrypi.org, but it’s free. 

When you first boot up the device, there are some setup steps where you choose language etc., then you come to a menu where you select “Start Raspbian”. 

This starts downloading the OS image onto the microSD card. Once this finishes, you’ll be able to log in to the desktop by entering username “pi” and password “raspberry”.

How Do I Update Raspbian?

To update Raspbian, simply open a terminal window and type:

sudo apt-get update && sudo apt-get upgrade -y.

How Do I Connect My Raspberry Pi To The Internet?

There are many ways to connect your Raspberry Pi to the Internet. 

The easiest way is to plug it directly into your router using its Ethernet port. If you don’t have access to your router’s settings, you may need to download a network configuration utility such as NetworkManager.

How Do I Configure My Raspberry Pi?

The default username and password for logging into the Raspbian desktop is ‘pi’ and ‘raspberry’. You can change these if you wish.

How Do I Use My Raspberry Pi As A Server?

If you’re looking to set up a web server, you could try Apache HTTPd. Type:

sudo apt-get install apache2.

Then edit /etc/apache2/sites-available/default and add a line like:

ServerName www.example.com.

Save the file, and restart the service by typing

sudo service apache2 start.

Now visit www.example.com in your browser.

How Do I Control My Raspberry Pi Remotely?

Remotely controlling your Raspberry Pi from another computer requires two things: SSH and VNC. 

To enable SSH type sudo raspi-config. Select Interfacing Options and check Enable SSH. Next, go back to the main menu and select Reboot. After rebooting, you should see a login prompt when you power on your Raspberry Pi.

VNC is a remote desktop protocol used to view the graphical interface of your Raspberry Pi over the network. To install VNC type sudo apt-get install tightvncserver. Run vncviewer from a Windows machine to connect to your Raspberry Pi.

Frequently Asked Questions

What Other Commands Can Turn Off The Raspberry Pi?

Use any of the above commands to turn off the RPi correctly: $ sudo halt $ sudo poweroff $ sudo shutdown -h now $ sudo shutdown -h 10 # after 10 minutes $ sudo init 0 Once the shutdown process is complete, the green LED on the Raspberry Pi board will blink a few times. It is then safe to disconnect the power cable.

What Is SIGTERM?

When RPi (or any other UNIX-like system) shuts down or reboots correctly, using commands from the terminal or their GUI equivalents, it first tries to shut down all gracefully processes by sending them a SIGTERM signal, which notifies them to save data and shut down.

What Is Command Line Interface?

A command line interface allows you to type in commands, which are then executed by the OS. 

This can be useful if you need to perform repetitive tasks on multiple files at once. 

For example, you could use it to change all the file extensions from.mp3 to.ogg. You would simply enter one command to do this, followed by another command to verify that everything worked as expected.

Conclusion

 Hopefully this article has helped you to learn how to shut down your Raspberry Pi correctly!

]]>
How To Format A Raspberry Pi SD Card https://raspians.com/how-to-format-a-raspberry-pi-sd-card/ Tue, 15 Feb 2022 13:52:07 +0000 https://raspians.com/?p=353 Read More]]> How do you format an SD card so that you can use it on the Raspberry Pi? Well, wonder no more, as this simple guide will tell you exactly how to do it!

How To Format A Raspberry Pi SD Card

SD Card Format

SD cards are used today for many purposes. There are three main types of SD card formats: FAT16, FAT32 and exFAT. The first two are standard SD cards, while exFAT is an extended SD card format. Standard SD cards are smaller than exFAT cards but larger than FAT16 or FAT32.

You need to format an SD card with FAT32 before installing Raspbian on the Raspberry Pi. The Raspberry Pi needs a minimum of 4 GB of space.

What’s A File System?

File systems organize files by storing them in different areas of a disk or other storage media. Files are divided into folders which are organized into subfolders. Each folder contains sub-subfolders.

There are many types of file systems used by computers. FAT32 is the most popular type of file system for portable storage devices such as USB drives.

NTFS is the default file system for Windows operating systems.

ExFAT is an open standard file system that supports large volumes of data while maintaining compatibility with existing applications.

Fat32 is an older filesystem but still widely used today. It supports files up to 4 GB and drives up to 32 GB. It’s also easy to use. However, it doesn’t support very large files or drives. You should use FAT32 because it’s compatible with the Raspberry Pi.

SD Card Size

SD cards have evolved from time as we have come of age. We have seen a lot of increases in sizes and capacities of the cards. Currently, we still have SD cards of 128 Mb, 256 Mb, 512 Mb, 1 GB, 2 GB, 4 GB, 8 GB, 16 GB, 32 GB, 64 GB, 128 GB, 256 GB, 512 GB, 1 Tb and most recently 2 Tb.

The earlier sizes of 2 GB and below have lost relevance as people’s requirements have greatly increased over time. However, the 2 Tb SD card is still rare and thus, very expensive.

You need to format your SD Card before installing the operating system. Don’t forget to back up your data before formatting.

For Windows, formatting an SD card is very easy. You can use either the Windows Explorer method or the Disk Management method to do this. There are other ways to format SD cards, but these two methods are the easiest ones.

What Hardware Do I Need?

Formatting an SD card is easy. All you need is an SD card reader (or adapter) that supports SDHC/microSDXC. This will allow you to read the SD card.

Format SD Card In Windows

Windows Explorer

  1. Formatting an SD card takes several minutes. You must be careful when formatting the SD card because any mistake could damage your data.
  2. After formatting, you should back up your important files before proceeding. You should always back up your files before formatting a drive. Formatting a drive will delete everything on it. If you don’t do this, then you will lose all your data when you install the operating system.
  3. In the list of disk drives, right-click on the drive that has the SD card inserted into it and select Properties. Click on the tab labeled “Format”. Select FAT32 from the dropdown menu.
  4. Choose a name for the card. Leave the other properties to their defaults. Press start, and the formatting process will begin. All data will be wiped.
  5. This could take quite a while – the bigger the card, the longer it will take. For example, an 8 GB SD card will finish formatting a lot quicker than a 512 GB SD card.

Use Command Prompt

  1. To format Raspberry Pi SD card, we should use the following commands:
  2. Insert the SD card into the computer. Open the command prompt window by pressing the Windows key on your keyboard, typing “cmd” (without the quotation marks), and pressing the enter key on your keyboard.
  3. Once the command prompt window has appeared, type the following command: diskpart. This will open the l. A new command prompt window will appear – this is the tool.
  4. In the Windows Disk Management tool, type the following command: list disk. This will show all the disks attached to this computer.
  5. Then, in the Windows Disk Management tool, type the following command to select the SD card: select disk n. Replace n with the number of the SD card. For example, if the SD card is sdb then replace n with sdb.
  6. In Windows Disk Management tool, type the following command again: list par. This will display all the partitions on the selected SD card.
  7. In the command prompt screen, type the following command once more: select par n. Replace n with a number representing the partition you want to work with. For example, if you want to work with the first partition, then replace n with 1.
  8. Type: format fs=fat32 quick. This will format the SD card using the FAT32 file system.

Rufus

  1. You can use Rufus to format an SD card. Clicking the “Boot selection” menu item allows you to choose whether you want to boot from the USB drive.
  2. Selecting “Non-bootable” formats the SD card without letting a computer boot from it. If you want to use your SD card to run your Raspberry Pi OS, then you don’t want this option.
  3. Your SD card should now be formatted as FAT32! You may want to rename your drive to something more meaningful.

Format SD Card In Linux

Gparted

  1. You can really easily format your SD Card for Raspberry Pi using GParted.
  2. Open Gparted, and select your SD Card from the drop-down menu given in the right-hand corner. If you have multiple partitions, delete them and create a new one.
  3. Select FAT32 as your file System and click on add. Confirm the changes after pressing apply. The SD is now formatted as Fat32 and is ready to be used for Raspberry Pi.

Conclusion

Hopefully this guide has helped you to learn how to format your SD card for use on your Raspberry Pi!

]]>