New answers tagged

0

There's a neat little library here that helps to provide this functionality.


0

As Joan said on Raspberry Pi Forums: mmap expects you to be using the /dev/mem device where offsets mean something. The /dev/gpiomem device (as written) ignores any offset and always grants access to the GPIO register area I would to read this mmap exceptional behaviour directly on its man pages :/


0

You can use python and Tkinter module: import tkinter as tk import os, subprocess def btn_click(): # ASYNCH os.system("bash /home/pi/shell_script.sh") # SYNCH p = subprocess.Popen(["bash", "/home/pi/shell_script.sh"], stdout=subprocess.PIPE, stderr=subprocess.PIPE) out, err = p.communicate() print(out, err) root = tk.Tk() frame ...


0

Forget NOOBS use PINN this has a much wider choice of OS - you can install any of the 3 versions of Raspbian. Each OS has to be downloaded from the web, so PINN doesn't waste the 1.3GB that NOOBS does.


0

As a matter of fact hdmi_safe=1 implies ALL of these: hdmi_force_hotplug=1 hdmi_ignore_edid=0xa5000080 config_hdmi_boost=4 hdmi_group=2 hdmi_mode=4 disable_overscan=0 overscan_left=24 overscan_right=24 overscan_top=24 overscan_bottom=24 hdmi_safe=1 worked for me but the 3 metioned by @goldilocks did not. You can try ...


0

I ran into the same issue today after upgrading to Raspbian buster. I was able to get the system booting again after purging version 0.11 of raspi-copies-and-fills from recovery mode as per @emmanuel-thomé 's answer. Given @vhdirk's answer (that a rebuild from arm-mem source works), here's how I rebuilt a new raspi-copies-and-fills package... I pulled the ...


1

I hosted my personal blog in a Raspberry Pi. you can see the stats of this litte computer in this page https://www.flopy.es/monitor/status.html In the same raspberry I have my blog, my webpage (more serious), a mail server and a personal cloud made with Nextcloud.


0

As you will have to act on the GPIO I recommand you go with wiring pi. If you are coming from the Arduino world you will recognise commands. Wiring Pi, is a Wiring library, like on Arduino with DigitalWrite() but for Raspberry. Of course if you don't know how works a shift register maybe you should take a look at the datasheet of something like the ...


1

You try to upgrade from Raspbian Wheezy to Raspbian Jessie. Wheezy is deprecated since years and isn't supported anymore. Jessie is old-stable since about two years and will also deprecated next. Current stable version is Raspbian Stretch. Debian/Raspbian is able to upgrade to a complete new version but it isn't an easy task. There are some assumptions made ...


1

/dev/gpiomem only gives access to the GPIO register addresses. To gain access to the PWM registers you need to use /dev/mem which requires root access. If you try to access hardware PWM with wiringPi you need to be running as root. If you run the program without being root it will crash. Have a look at Minimal GPIO Access for an example of accessing the ...


0

Using PXE means net booting, that is, the RasPi is loading the kernel and operating system from a master server on the network, but not from the SD Card. Because PXE is only working on wired ethernet connections I assume your RasPis are all connected with an ethernet cable. For this scenario I have made a configuration for Raspberry Pi. How to do it you can ...


-2

Unless you provide a safe limitation (ie: "Only files in /mnt/volatile"), it's not a good idea to completely automate the removal of files. You can look into tmpwatch/tmpreaper on how Linux and different distributions create temporary files and directories, to hook into, or take advantage of the existing setup. For example, if you can put unimportant files ...


2

I don't know what version of the Pi you use, but from version 3 onward it may be possible to boot from network: https://www.raspberrypi.org/documentation/hardware/raspberrypi/bootmodes/net_tutorial.md How to PXE Boot a Pi 3? But it seems like it requires a bit of preparation and configuration. At work, we just configured one PI that fits our needs (base ...


1

Assuming you have not done anything with the Raspian card yet you could follow the instructions on building a new card it may be the fastest method. Make sure that as someone new to PI that you go ahead and use the version with desktop. Install guide and download is available here: https://www.raspberrypi.org/downloads/raspbian/ I am making a quick ...


-2

Question How to enable AD9833? How to clock it? Answer Two good references are: The AN1070 app notes, where there is an example of frequency calculations. You also need to study very carefully the functions of the pins Master Clock, Frame Sync (See Appendix A below) Arduino forums. The Arduino guys have more experience on this chip, ...


1

For anyone having the same issues: It turns out that the above code uses too little CPU load and therefore does not shoot up the frequency. When I checked, my CPU was constantly running at 700 Hz. To achieve the required FPS on the above resolution, I changed my cpufreq governor from ondemand to performance. This might not be the only or the best solution, ...


2

Very late response but I came across this while searching for an answer myself. I solved this problem by setting deluge to download to a local directory on the Pi first, then use the "move on completed" option in deluge to move the completed file to your mounted curlftpfs directory. It will successfully seed as well. Hope this helps someone who ends up here ...


2

this error usually happens when you access the RPI via SSH, you could run: export DISPLAY=0:0 or add it to your bashrc if you want it to be perminantly excuted on every therminal run and ssh connection. EDIT (a great suggestion by roger-jones): you can also set the variable by prefixing it to the command: DISPLAY=0:0 python gui.py. If you SSH with ...


3

As joan pointed out in the comments above, there were extra spaces after "Keycard"


1

PI3B AND PI3B+ are very picky about undervoltage. Voltages on the input must be over 5V otherwise it shows the undervoltage symbol. It still works fine but at almost half of the processing speed.


1

GLIBC_2.27 is not a library, it means that a symbol from libc with version 2.27 (or higher) is needed. You can try to install the glibc from the same repository where you got the libatlas-base-dev, they should have a compatible version. libm is part or glibc. Newer versions of glibc should be upward compatible with older versions.


1

One option would be to check the Ethernet MAC address, but this can be spoofed. An alternative would be to use the serial number in /proc/cpuinfo such as in this Xojo thread. Such efforts should prevent most of the casual copying. However, a determined programmer can defeat that as well. See Dimitry's answer on a different thread.


3

The solution was surprisingly simple: Install an older Numpy version - I went with: sudo python3.7 -m pip install 'numpy>1.0, <1.15' --force-reinstall The installation took looong, but I'm now able to import numpy in python3.7 Hope this helps someone..I spent way too much time figuring this out


1

I've seen this effect when you have a broken SD card. You update the file, the inode is updated in storage because it's cached and you can verify the update as long as you don't reboot your system. But when you shut down your system the updated inode cannot be written to the broken SD card. Next time you boot your system you get the old inode pointing to ...


0

Openbox right-click menu is normally configured in a file called menu.xml, which is located either in ~/.config/openbox/ or somewhere under /usr/share/ if you don't have the former file. Find out what the command syntax is for this "Open in Terminal" option on a system where you have it (I'd expect something like lxterminal --command=%1), and add this item ...


2

Another simple method timeout 120 chromium-browser https://raspberrypi.stackexchange.com


-1

Go to /etc/ppp/peers/provider and set the communication rate to 9600


2

The culprit turned out to be the mini OTG adapter: It is cute, but it doesn't work with the hard drive. Switching to a regular OTG cable made the drive appear. Following is a diff of the boot messages when using the mini OTG adapter and the OTG cable. The message timestamps have been removed to produce a clean diff. Someone more familiar with Pi hardware ...


1

It sounds like you have destroyed the Pi and will need to buy a new one. The most likely explanation is you connected 5V to the Pi's 3V3 pin through the NRF24L01.


0

Question MCP3424 ADC 0~10VDC, 0~30 VDC, 12/16 bit resolution Sensor Output Divider - 10V x 1k/(1k + 1k) = 5V, 30V x 5k/(5k + 10K) = 5V OK? Answer No problem at all. You can even do 18 bit resolution. Using resistive voltage divider might not be a good idea, especially if you want high resolution. Perhaps you should consider a high ...


0

The circuit you show appears to be using I²C. However this shows pullup to 5V! Connecting GPIO to 5V will destroy the Pi! You can drive I²C from the Pi; it includes on-board pullup, so NO EXTERNAL PULLUP are needed. If they are present they NEED to be removed. The resistors R1, R2 have NOTHING to do with a voltage divider. You will need to supply your own ...


0

NOOBS is not an OS The link you listed is for an obsolete OS, and has no relevance the current Raspbian GUI or to Linux systemd. You need to list your script to get a definitive answer, it depends on what it does. https://www.raspberrypi.org/documentation/linux/usage/systemd.md shows how to start a general (non GUI) script.


1

The right combination to exit nano is Ctrl+X. If you accidentally killed apt upgrade (or it crashed on its own), try re-starting it right away. Deal with any error messages before you reboot, otherwise you may end up in the same state again. If you lost USB, you still have an option to login using a USB-to-UART dongle connected to UART pins. You will need to ...


0

Your relay module is advertised as 5V, so it won't directly work with RPi GPIO which are only 3.3V. They seem to have a picture of their modules connected to the RPi, which doesn't help. You can complain to Amazon about this, and return the module for a refund (but considering the price, I wouldn't bother). You can try providing 3.3V as VCC and 5V as RY-VCC ...


1

I think the circuit you've illustrated is more complex than what is needed for simply driving a 12/24V relay. The primary considerations in using GPIO to control external devices are: GPIO has low output voltage (3.3 volts), GPIO has low drive current GPIO is fragile in the sense that it will not tolerate over-voltage I feel the optimal device for ...


0

The circuit you included would, in principle, work with any relay, provided a suitable transistor is used. There are some issues; what is D14 supposed to do (apart from dropping voltage, making it harder to turn on the opto-isolator). The use of an opto-isolator adds no value (unless you need galvanic isolation), the limited current transfer ratio just ...


0

I don't know how many amps Raspberry Pis can output on their GPIO pins, but the Songle SRD-05VDC-SL-C (the cheap blue electromechanical relay everybody seems to use these days) has a coil that needs 70 mA to latch... That could be the source of your problem...


1

After much strife, my issue was solved by installing blueman and using its wizard to pair the remote.


0

There is no officially supported upgrade. Expert users can upgrade, provided they are prepared to handle the issues. If you did this when Stretch was introduced, it may have worked, but there have been significant changes since. Don't bother! Buster will be out in the next few months. Incidentally the link you posted contains some very bad advice to run ...


2

I had the same problem with Libreelec: only one OS available and NOOBS asked everytime which one to boot (with a list of 1 element of course). In my case I solved by going in the configuration by holding SHIFT during boot, then I unchecked and then re-checked Libreelec in the list and finally exit with ESC. The subsequent boots went to Libreelec without ...


1

Default config for a Pi is DHCP addressing. The router (or switch) assigning the IP to your Pi will assign one from a pool of addresses with an express lease time set for the IP address it assigned (mapped) to the mac address of your WLAN0 interface. Think of this IP as "loaned" to you: it's not yours in perpetuity and the address can be chucked back into ...


0

I had a similar issue after upgrading from Raspbian 8 to Raspbian 9. After udev package was upgrading to latest backport version, the raspberry was booting in emergency mode : Welcome to emergency mode! After logging in,type "journalctl -xb" to view system logs, "systemctl reboot" to reboot, "systemctl default" or ^D to try again to boot into default mode. ...


-1

After using Ctrl+Alt+F1, try using Ctrl+Alt+F7. this should return you back to your normal screen. If that doesn't work, return to first screen using Ctrl+Alt+F1, then type startx. Enter that and it should reboot normally


0

My guess is the init level may not be set high enough yet for an X session. You might add a sleep 120 to the cron and possibly a nohup: @reboot sleep 120;nohup /bin/sh /home/pi/bbt/launcher.sh >/home/pi/logs/cronlog 2>&1 (edit: I also fully qualified the /bin/sh but I doubt that's the issue)


1

You can't run something at startup that should open a window, because the X Server is not yet available. Additionally, cron jobs don't normally have access to the X Server. However, it is possible to connect to the X Server if you prepare the correct environment. Normally, what you need are the DISPLAY, XAUTHORITY and XAUTHLOCALHOSTNAME variables. To ...


0

You can put your commands in ~/.bashrc and they'll be executed when you open a terminal.


0

It is very likely that you already have got a gateway ip address (default route) from the DHCP server on the router. I have very often seen on this site that it confuses the kernel if you define a second gateway. So please edit /etc/dhcpcd.conf and delete the entry for gateway 10.0.0.1. If it doesn't help, then please edit your question and add the output ...


3

Probably a bit late, but i had the same issue and it was impossible to find information, maybe this i'll help someone. My Camera is almost exactly like the one in the photo, and it doesn't have a "sunny" connector. What fixed it for me was just unscrewing it completely, pressing lightly on the sides of the sensor module, and reattaching everything, except ...


3

chrome is designed for ×86 processors only the RPi is an ARM processor but you can give chromium a shot.


0

the solution is to use orange pi r1, only available on aliexpress (yes it is Chinese) it have 2 Ethernet sockets which you can bridge and put your code in between, now how to bridge this guy, sorry i am the wrong man. also note that this board is not heavily documented nor super user friendly (watch youtube reviews) so you might do a long journey, hope ...


Top 50 recent answers are included