Hot answers tagged

105 votes
Accepted

Which model Raspberry Pi I am running?

cat /proc/device-tree/model returns something like Raspberry Pi 3 Model B Rev 1.2
SBF's user avatar
  • 1,174
47 votes

Open chromium full screen on start up

Edit this file sudo nano /etc/xdg/lxsession/LXDE-pi/autostart And add this: @xset s off @xset -dpms @xset s noblank @chromium-browser --kiosk http://google.com/ # load chromium after boot and open ...
SK73106's user avatar
  • 611
32 votes
Accepted

Navigating through USB drive with "cd /myOtherFolder" causes "no such directory" error

You put a leading / to your path names! That's the root directory, meaning what you write next is an absolute path. Your /myFolder/myOtherFolder is not on your USB if it's mounted inside /media/pi/...
Nyos's user avatar
  • 721
24 votes

Which model Raspberry Pi I am running?

By CPU Type You could check the RPi version with the command, uname. The different RPi versions have different CPU architectures. The RPi 2 has an arm7, whereas the 3 has an arm8. uname -m By ...
Jacobm001's user avatar
  • 11.9k
13 votes

Where can I share my cool scripts?

Github.com gitlab.org bitbucket.org anywhere code related really
patrick's user avatar
  • 311
11 votes

Which model Raspberry Pi I am running?

There are many methods (of varying reliability) to determine this. One of the most complete and reliable is gpio -v which produces the following output. gpio version: 2.44 Copyright (c) 2012-2017 ...
Milliways's user avatar
  • 58.6k
10 votes

Open chromium full screen on start up

on chromium you can use --start-fullscreen (like F11)
Quadrifoglio Verde's user avatar
10 votes

Navigating through USB drive with "cd /myOtherFolder" causes "no such directory" error

To go into a bit more detail — Whether you come from a Windows or Mac OS X background, you will be used to external drives being independent places from your hard disk (more or less). Part of Unix ...
Artelius's user avatar
  • 201
9 votes
Accepted

Log output of background or boot script

First, if the script is run by a system daemon and that daemon is running with root privileges, you do not need to use sudo. This includes init (and systemd), which includes rc.local. If that daemon ...
goldilocks's user avatar
  • 58.5k
9 votes

Where can I share my cool scripts?

To have a jsfiddle-like shareable link for your scripts, create a Github account, and save your scripts as GISTs: https://gist.github.com/ You will be able to update them in the future if you need. ...
Paulo Amaral's user avatar
8 votes
Accepted

Launch GUI to view current directory from command line?

This is not really RasPi specific and just depends on your OS / it's installed file manager. For Raspbian, that should be pcmanfm So pcmanfm .
mystery's user avatar
  • 518
8 votes
Accepted

bash: npm: command not found

Don't install Node.js directly from apt—it's hideously out of date, and most of the features you're expecting to have won't work. The version in the repositories at the minute is v0.10.29, while the ...
Aurora0001's user avatar
  • 6,278
7 votes
Accepted

Setting system-wide path not working in /etc/environment

Can someone enlighten me of why the /etc/environment is ignored on Raspbian? It isn't. Add this to /etc/environment: FOO=bar Login, and echo $FOO. It's there. /etc/environment isn't actually ...
goldilocks's user avatar
  • 58.5k
7 votes
Accepted

Colored console over serial connection?

The default bash prompt is set in a system wide file; for a complete explanation of how bash sources its configuration see INVOCATION near the top of man bash. In short, that system wide file is ...
goldilocks's user avatar
  • 58.5k
7 votes

Adding 'at' command to Raspbian

It shouldn't be much more than: sudo apt-get install at
Ghanima's user avatar
  • 15.8k
7 votes
Accepted

How do I make sudo!! add a space after sudo?

You need to use sudo !! instead of sudo!!. This is intended behaviour. The !! history expansion, as stated in the documentation: designates the preceding command. When you type this, the ...
Aurora0001's user avatar
  • 6,278
7 votes
Accepted

Error in apt-get update

All the repository URL's are in the apt source files. The main source file is /etc/apt/sources.list. You can edit the file with e.g. nano to remove the offending 'etcher' line(s): sudo nano /etc/apt/...
Dirk's user avatar
  • 3,506
6 votes
Accepted

How does one clear the bash history?

That is the bash history not a cache. It is stored in the .bash_history file in your home directory. By default it is limited to a set number of lines (1000) and the size of the file (2000). So even ...
Steve Robillard's user avatar
6 votes
Accepted

Bash command to append to /boot/config.txt

The redirection takes place before sudo takes effect. Try something like sudo sh -c "echo 'dtoverlay=pi3-miniuart-bt' >> /boot/config.txt"
joan's user avatar
  • 70.5k
6 votes

Where can I share my cool scripts?

One place to go to - if you care about some explaining of those scripts too - would be our official+ blog Piversify: Piversify is a blog dedicated to the Raspberry Pi, written by members of the ...
Ghanima's user avatar
  • 15.8k
6 votes
Accepted

JAVA_HOME not working

Your JAVA_HOME points to a different directory than where your java executable is located. Per your question, the JAVA_HOME directory is: /usr/lib/jvm/jdk-8-oracle-arm-vfp-hflt whereas java is ...
Phil B.'s user avatar
  • 5,033
6 votes
Accepted

Accessing EXPORTED Environment Variables in Python

The problem is the use of sudo. sudo will clear environment variables by default. You can use sudo -E (or --preserve-env) to not clear the environment. This can also be set in your sudoers file.
Craig's user avatar
  • 3,014
6 votes
Accepted

Why am I getting bash: esptool.py: command not found on new Raspbian install after installing esptool.py

On your original working install you probably installed it with sudo. If you use sudo pip3 install esptool esptool.py works just calling it by name, but if you don't use sudo you have to specify ...
T. M.'s user avatar
  • 871
6 votes
Accepted

Find out whether SPI is enabled or not

You can use raspi-config non-interactively to get the SPI status: sudo raspi-config nonint get_spi Which returns 0 (enabled) or 1 (disabled) Similarly, enable with: sudo raspi-config nonint do_spi ...
ben_nuttall's user avatar
  • 2,441
5 votes
Accepted

Run a script on Raspbian startup but not on terminal open

You can use a cron job. Cron is used when you want to schedule jobs to run at specific times, e.g. every hour, every Sunday at 3 a.m. It stores the details in a table for each user called a crontab ...
joan's user avatar
  • 70.5k
5 votes

Colored console over serial connection?

I read Walter's answer here and researched more and found: https://kb.iu.edu/d/acpy which indicated: TERM=ansi; export TERM does the job, you can add it to your .bashrc However, I still have grey ...
Robert's user avatar
  • 51
5 votes

Access shell while music playing

You can use screen It allows you to run commands in virtual terminal and then deattach from it and use terminal normally. To install it use these commands: sudo apt-get update sudo apt-get install ...
rav_kr's user avatar
  • 446
5 votes
Accepted

How to wait for networking on login after reboot?

Assuming you are using Raspbian, you can use raspi-config to delay boot until the network is up. start raspi-config with the following: sudo raspi-config then select option 4 Wait for network at ...
Steve Robillard's user avatar
5 votes
Accepted

How do I make .sh run on boot to console?

Unfortunately the Q&A you are consulting is Mostly obsolete, since the accepted answer uses SysV init style methods instead of systemd ones. These are both init systems. The former is used on v....
goldilocks's user avatar
  • 58.5k
5 votes
Accepted

Remote full reset (re-install) of a Raspberry

Firstly: doing this by remote is inadvisable especially if, like me, you happen to be 70+ miles from your remote pi. It's a very long drive if you screw it up. When you do this fir the first time, ...
Philip Couling's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible