Raspberry Pi

130

Solutions

231

Contributors

The Raspberry Pi Foundation works to put the power of digital making into the hands of people all over the world, so they are capable of understanding and shaping our increasingly digital world, able to solve the problems that matter to them, and equipped for the jobs of the future.

We provide low-cost, high-performance computers that people use to learn, solve problems and have fun. We provide outreach and education to help more people access computing and digital making. We develop free resources to help people learn about computing and how to make things with computers, and train educators who can guide other people to learn.

Share tech news, updates, or what's on your mind.

Sign up to Post

Hi everyone,

So I've spent the past week reading and trying to understand the python language and more importantly the CherryPy web framework.
To be honest Im getting no-where quickly...

What I'm trying to do is simply build a frontend to a Raspberry Pi project I've been developing.
The CherryPy web framework seems perfect for this as it is small and contains its own web server that would suite my needs perfectly.

An admin user attaches to the Raspberry PI AP and is immediately directed to a webpage (This I have solved quite easily).
The webpage is presented by the CherryPy web server.

I have an index.html which it returned from my CherryPy script.

import os, os.path, sys
import cherrypy

# Configuration file to access server over network and define ports
cherrypy.config.update("server.conf")

class menu(object):
    @cherrypy.expose
    def index(self):
        return open('index.html')

(Fairly simply until now I know)

What I would like to do is have buttons on my index.html that can be pressed and return os.system('mkdir boom')  (obviously my system commands will be a little more than this.. They will start and stop services.

The buttons will eventually be toggle switches, so going to the page will need to return the current status of the running process. Red if the process is not running and Green if it is running. I think I need to be interacting with jquery on my index.html page to achieve this...

This whole area is new to me and …
0
Is it possible to program the Raspberry PI camera to do OCR?
Need it to recognize a list of characters and when seen, write the info to a file.  
Need the following info with each entry;
Captured data
Date and time (down to the second)
Location (can be GPS or user entry)

And once a day (or at user request) upload data to a online database.
0
I need a code in Embedded C for making call andi sending SMS by using Raspberry pi 3 and GSM SIM 900. Please help me. I am new to Raspberry pi
0
I have FreeRadius installed on a Raspberry Pi and would like to know how to enable Accounting.

Thanks
0
I have FreeRadius installed on a Raspberry Pi and everything seems to be working fine.

I would like to implement a limit on the number of logins per identity and was hoping someone could share with me how to achieve this.

My only goal is to provide some control of people sharing access credentials among those that shouldn't have them.

Thanks.
0
hi everyone,
i'm trying to start a project for a box storage facility, i know thing allready have been done but i would like to do mine :)

the code is not the problem but the electronics yes. The problem is not U = Ri :) but how can i mux the doors sensors ? If some one open the door very fast and then close what would happen ... is important not to miss the change of state ...

So any idea is really welcome

Thanks very much
0
Hi experts.

I have been trying to automate some infrared command through my Raspberry Pi, using the IRDroid-Rpi infrared transceiver (http://www.irdroid.com/2016/10/discover-how-to-turn-raspberry-pi-into-a-infrared-remote-control-using-the-irdroid-rpi/). These commands must be first learned from my Set Top Box infrared remote control using irrecord, but it is a commercial remote.

I have followed the documentation and finally got the IRDroid-Rpi to work. However, it will only work if I learn commands from commercial remote controls like a Samsung TV remote control. My STB remote control is non commercial, and I have not been able to make the IRDroid-Rpi learn and send the commands correctly. Here is my procedure and files:

pi@raspberrypi:~ $ sudo irrecord -f -d /dev/lirc0 lircdtp2.conf

Press RETURN now to start recording.
................................................................................
Found const length: 108301
Please keep on pressing buttons like described above.
Creating config file in raw mode.
Now enter the names for the buttons.

Please enter the name for the next button (press <ENTER> to finish recording)
KEY_CHANNELUP

Now hold down button "KEY_CHANNELUP".
Sorry, something went wrong.
Try again.
Got it.
Signal length is 3


# Please make this file available to others
# by sending it to <lirc@bartelmus.de>
#
# this config file was automatically generated
# using lirc-0.9.0-pre1(default) on Tue Apr 25 23:40:23 2017
#
# contributed by 
#
# 

Open in new window

0
I am designing my first Raspberry Pi app .... It tracks a volley ball game ... I have found a lot of motion tracking ... I need a tutorial teaches me how to map the court ... the court has white lines ... when the ball goes beyond the white line an LED will light up ... how can I get raspberry to map the court ?
0
Exception thrown: 'Microsoft.Azure.Devices.Client.Exceptions.IotHubCommunicationException' in mscorlib.ni.dll
Exception when sending message:An error occurred while sending the request.

Getting an exception error while sending telemetry data to azure iot hub using Dht11 sensor with raspberry pi 3 and windows 10 iot core.
0
Hello Everyone,

I am working to set up a raspberry pi as a vpn through my pfsense router. I have the pi configured and I am now having issues getting it to pass through the firewall to a public ip. If that won't work I'm looking for a username/password based vpn akin to pptp to add simplicity for my users (they don't want to use another client like open vpn) I'm fairly new to configuring vpns and I'm looking for a little guidance.
0
Hi,
this is the second time I receive this type of requirement but it is the first time I think I will try to achieve.
Once, a client asked me to make a system that allow to track their truck fleet. Now, for an Airsoft store, I have been requested to develop a software that allows to track team members with any electronic device.
In bothe cases a mandatory requirement was to display all devices at once, meaning in 1-screen multiple trucks or team members.
I think, one way, to achieve this is, probably, to provide 1 gps device connected to a raspberry (my favorite) or arduino board to every truck/team member and then display 'dots' per each one maybe using google maps but I have not found someway multiple locations can be displayd at once in google map.
So, I would like from you to tell me about any similar project you may remember, or suggestions so I use can start reading about it.
Thanks a lot.
Note: I have searched for existing devices but I have not found something that works for multiple 'dots', in 1 screen and close to realtime.
0
HI,
Have a couple of Raspberry Pi 3'3, using them for some Bluetooth things..

The below python script will make the pi crash intermittently. (maybe after about 15 - 60 mins of operation, no real pattern..

The script is launched remotely via another controlling python script via a subprocess call, like this....

.....blah..
cmd = "ssh pi@192.168.30.30 /home/pi/scripts/bluez/whos_in_slave.py"
p = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
    for line in p.stdout:
        pi_names += line

Open in new window


There doesn't seem to be any resource issues (CPU or Mem)

Not sure how to debug this one..

Any ideas experts??

The called script on the remote Pi (that intermittently crashes..) looks like the following..

#!/usr/bin/python
#makes list of users that can be seen at the moment..
import bluetooth
import os
import subprocess
import time

if __name__ == '__main__':

    #Text file containing candidates
    candidates_file = "/" + os.path.join('home', 'pi', 'scripts', 'bluez', 'devices.lst')


    #Read text file into dictionary so we can search and sort easily..
    candidate_dic = {}

    with open(candidates_file, 'r') as candidates:
        for line in candidates:
            (key, val) = line.rstrip("\n").split('||')
            candidate_dic[key] = val

    #lets now find out who we can see....

    in_list = ""

# 
    for key, val in candidate_dic.iteritems():
        result = bluetooth.lookup_name(key, timeout=5)
        if (result != None):
		if (result !=""):
            		in_list += val + "\n"

    #Now print out the result..
     print(in_list)

Open in new window

0
I am using chromium to autostart a webpage into a kiosk.  but my webpage needs a username and password, I have the username and password stored but is there away that when page loads select enter? To continue past the login screen.
0
Good day experts...

I have successfully installed the ptpd package on a Raspberry Pi (v2)...long story of why, but need to try and make it work.  My Grandmaster clock is located at x.x.x.28 and is providing PTP (and NTP) to a number of other devices, so I believe it is setup correctly.  I start ptpd from the command line as root (see command below), but the output shows it never anything other then "lstn_init" state.

Using tcpdump, I don't see any related traffic going out of the interface.  If I run ptpd in "hybrid" mode I do see some multicast traffic outbound, but our GrandMaster is set to use unicast only.

Anyone with thoughts or suggestions?  Thanks!

****** Command ******
ptpd --statistics-file I /var/log/ptpd.stats --interface eth0 --ptpengine:ip_mode=unicast --ptpengine:log_delayreq_interval=0 --ptpengine:unicast_address=x.x.x.28 --ptpengine:delay_mechanism=E2E --foreground --verbose -D -f /var/log/ptpd.logd
****** /Command ******

****** Output ******
Runtime debug not enabled. Please compile with RUNTIME_DEBUG
2016-03-22 13:21:41.078628 ptpd2[2828].startup (info)      (___) Configuration OK
2016-03-22 13:21:41.079464 ptpd2[2828].startup (info)      (___) Successfully acquired lock on /var/run/ptpd2.lock
2016-03-22 13:21:41.080276 ptpd2[2828].startup (info)      (___) Successfully bound ptpd2 to CPU core 0
2016-03-22 13:21:41.082341 ptpd2[2828].startup (notice)    (___) PTPDv2 started successfully on eth0 using "slaveonly" preset (PID 2828)
# …
0
Hey Guys -

I used to have an extensive media collection for which I've spent a ton of time and resources ripping from physical to digital media.  Currently, I have 20+tb which is mostly comprised of my ripped Blu-Ray movies.  All media is stored on my home "server" on a single 26tb+ partition which is made up of x10 physical drives (x9 SATA & x1 SSD) binded together using StableBit DrivePool (works great :)).  Unfortunately, I still have more to go and each time I must add storage, it's costing more.   For the last upgrade, I not only purchased another 4tb drive, but also a SATA card plus upgraded my power supply from a 650W to 1000W.  Besides the cost, nothing I have is backed up!  At the end of this post is my current setup.

I play all of my media using a few methods.  Most local playing on TV is via a different dedicated computer running Kodi (XBMC).  The second most used playback is Plex which sends the media out in many ways.

My Question
When thinking about the above situation recently, I thought it may be a good solution to purchase cloud-based storage and start moving media there.  I'd need at least a few TBs to start, but would also need for the service to offer certain features to make it compatible with my setup.  The need for local sync also wouldn't be required or used.  Below is the feature list I'd need:

Required Features for Cloud Storage to Work
Ability to have multiple TBs of space to purchase
Preferably multiple
0

Raspberry Pi

130

Solutions

231

Contributors

The Raspberry Pi Foundation works to put the power of digital making into the hands of people all over the world, so they are capable of understanding and shaping our increasingly digital world, able to solve the problems that matter to them, and equipped for the jobs of the future.

We provide low-cost, high-performance computers that people use to learn, solve problems and have fun. We provide outreach and education to help more people access computing and digital making. We develop free resources to help people learn about computing and how to make things with computers, and train educators who can guide other people to learn.