raspberry-pi3

How to solve LIBUSB_ERROR_BUSY on Raspberry Pi (Debian) running Node.js

蓝咒 提交于 2019-12-06 07:31:17
I am running node.js on a raspberry pi 3 (debian). I have a little prototype project which gathers data from an ANT+ transmitter on my turbo trainer, which is being sent via a Suunto Movestick USB dongle. I am using the Ant-Plus node module to manage the ANT+ protocol and a script which outputs the data to the console and sends via REST API to cloud storage. Anyhow, cutting to the chase, it was all working fine, multiple process start and stops with no problems, until I inadvertently killed the process by hitting ctrl + z instead of ctrl + c Now I just get the following error, when trying to

How to boot Android Things 0.6.1 DevPreview in CM3L (Computer Module 3 Lite)

陌路散爱 提交于 2019-12-06 06:27:27
问题 Actually I can boot Android Things "0.6.1 Developer Preview" in Raspberry Pi 3 (RPI3), I'm develop a project with Computer Module 3 Lite (CM3L) this have the same processor of the Raspberry Pi 3 (RPI3) but I only see the rainbow screen, never continue, I suppose the problem is relatad with DTB (Device Tree). I try some options 1. Add DTB file for CM3 "bcm2710-rpi-cm3.dtb" on boot partition, when I do that the rainbow screen appear an the disappear but not do anything more 2. Replace the

How to pipe Picamera video to FFMPEG with subprocess (Python)

☆樱花仙子☆ 提交于 2019-12-06 05:54:35
I see a ton of info about piping a raspivid stream directly to FFMPEG for encoding, muxing, and restreaming but these use cases are mostly from bash; similar to: raspivid -n -w 480 -h 320 -b 300000 -fps 15 -t 0 -o - | ffmpeg -i - -f mpegts udp://192.168.1.2:8090ffmpeg I'm hoping to utilize the functionality of the Picamera library so I can do concurrent processing with OpenCV and similar while still streaming with FFMPEG. But I can't figure out how to properly open FFMPEG as subprocess and pipe video data to it. I have seen plenty of attempts, unanswered posts , and people claiming to have

Raspberry Pi RuntimeError: Conflicting edge detection already enabled for this GPIO channel

余生长醉 提交于 2019-12-06 05:26:42
I was following a tutorial found here: https://www.linkedin.com/pulse/prepare-your-raspberry-pi-work-aws-iot-kay-lerch I have not even begun the internet part of it as I was having issues with the circuit. I wired my circuit just like it is shown in this diagram below using my raspberry pi 3. I then wrote the following python script as shown in the tutorial. import RPi.GPIO as gpio gpio.setmode(gpio.BOARD) gpio.setup(7, gpio.IN, pull_up_down=gpio.PUD_DOWN) def on_pushdown(channel): print "Button Pushed." while(True): gpio.add_event_detect(7, gpio.RISING, callback=on_pushdown, bouncetime=200)

windows 10 iot raspberry pi 3 wifi hotspot

蓝咒 提交于 2019-12-06 04:48:14
I am trying to make my RPi 3 an AP using Windows 10 IoT core. RPi is connected with internet through Ethernet port and I want to make RPi 3 builtin WiFi to share internet with other devices. I have read documentation page but it is not working for me. I have tried with Windows IoT Onboarding and from PowerShell also. After selecting adapters from IoR Onboarding, clicked on start sharing service and a message appears which says "internet conncetion sharing has started" but I can't find network on other devices. After selecting adapters from IoR Onboarding, clicked on start sharing service and a

Configure MySQL for local and remote access

 ̄綄美尐妖づ 提交于 2019-12-06 02:56:47
I'm using MySQL server version: 10.1.23-MariaDB-9+deb9u1 Raspbian 9.0 on a Raspberry Pi. This is my /etc/mysql/my.cnf : # The MariaDB configuration file # # The MariaDB/MySQL tools read configuration files in the following order: # 1. "/etc/mysql/mariadb.cnf" (this file) to set global defaults, # 2. "/etc/mysql/conf.d/*.cnf" to set global options. # 3. "/etc/mysql/mariadb.conf.d/*.cnf" to set MariaDB-only options. # 4. "~/.my.cnf" to set user-specific options. # # If the same option is defined multiple times, the last one will apply. # # One can use all long options that the program supports.

Wifi direct connection disconnects automatically after a few seconds in Raspberry Pi

旧城冷巷雨未停 提交于 2019-12-05 12:24:16
I am using this configuration for wifi direct connection in Raspberry PI 2 B+ ctrl_interface=DIR=/var/run/wpa_supplicant driver_param=use_p2p_group_interface=1 update_config=1 device_name=Raspberry_pi device_type=1-0050F204-1 p2p_go_intent=1 p2p_go_ht40=1 country=IN and then started wpa supplicant using sudo wpa_supplicant -Dnl80211 -iwlan0 -c/etc/wpa_supplicant/p2p.conf -B and then add new group using sudo wpa_cli -iwlan0 p2p_group_add and then set an IP using ifconfig p2p-wlan0-0 192.168.1.20 and then set the pin using sudo wpa_cli -ip2p-wlan0-0 wps_pin any 0000 up to this, everything is

Cross compilation: special cross compiler or just gcc with option -march?

此生再无相见时 提交于 2019-12-05 12:06:24
I need to compile a program for Raspberry PI 3+ on Linux machine, and code must be compliant with c++17 standard. Official toolchain is outdated and lack c++17 compilation option. Two solutions that I can see right now are: 1) gcc has an option -march, which described here: https://gcc.gnu.org/onlinedocs/gcc/ARM-Options.html 2) Installing arm-linux-gbueabi-gcc package, as proposed here: Cross-compiling for Raspberry pi with modern gcc What is the difference between two options? Is there some other possibilities that will work? If you want full Cross Compiler c++17 standard for your Raspberry

Automation of video recording on booting of raspberry pi3

偶尔善良 提交于 2019-12-05 11:53:02
I have written a python code which contains some opencv code to play around with my webcam. I have attached it to raspi 3. I want that on startup(booting), it start recording video automatically.. I am using crontab for this. My Python code: import cv if __name__ == "__main__": # find the webcam capture = cv2.VideoCapture(0) capture1 = capture # video recorder fourcc = cv2.cv.CV_FOURCC(*'XVID') #cv2.VideoWriter_fourcc() does not exist videoOut = cv2.VideoWriter('out1.avi', fourcc, 10.0, (640, 480)) videoOut1 = cv2.VideoWriter('out2.avi', fourcc, 10.0, (640, 480)) # record video while (capture

Unable to autolaunch a dbus-daemon without a $DISPLAY for X11. NetBeans. Pi as remote host

≡放荡痞女 提交于 2019-12-04 18:03:16
I am trying to run the following example code using my NetBeans IDE: #include <stdio.h> #include <stdlib.h> #include <string.h> #include <dbus/dbus.h> int main() { DBusConnection *connection = NULL; DBusError error; char buffer[1024]; dbus_error_init(&error); connection = dbus_bus_get(DBUS_BUS_SESSION, &error); if (dbus_error_is_set(&error)) { fprintf(stderr, "%s", error.message); abort(); } puts("This is my unique name"); puts(dbus_bus_get_unique_name(connection)); fgets(buffer, sizeof(buffer), stdin); return 0; } From an excellent tutorial: DBUS TUTORIAL USING THE LOW-LEVEL API I have my