Python is a programming language that lets you work more quickly and integrate your systems more effectively. You can learn to use Python and see almost immediate gains in productivity and lower maintenance costs.

learn more… | top users | synonyms

1
vote
1answer
28 views

Extracted SMS body and passing it in a condition (Python)

This is my class for checking unread messages def CheckUnreadMsgs(ser) print "Check for new messages...\n" ser.write("AT\r") time.sleep(3) line = ser.read(size = 64) print line ...
0
votes
1answer
27 views

Python in the latest Raspbian Wheezy

What version of Python does the last Raspbian Wheezy comes with? In LXTerminal I ask for version 3 (python3) and says it is already installed, but when I check (python) it says that the latest is ...
0
votes
0answers
18 views

Data Transfer b/w Ubutu & RaspberryPi through Python [on hold]

I am working on Ubuntu PC and want to make a Python program to get a file (video.h264) from RaspberryPi. Both machines are connected together by CAT5 cable directly, without any Switch or Hub b/w ...
0
votes
0answers
16 views

Use webrtc without a browser or some alternative method

Right now I am using this project here. It is a python script that runs a server using webrtc to send the clients/browsers webcam to the server and perform face recognition. What I want to do is do ...
1
vote
4answers
359 views

Root access , nightmare when TRYING to learn the basics

Why have a product an software that's so tricky to grasp when it's meant to be educational. I'm trying to experiment with the gertboard an simply run Python 2.7 ( I'm using 2.7 because any other ...
4
votes
0answers
47 views

Resolution properties for python's OpenCV and uv4l camera driver

I've followed this tutorial to install OpenCV 2.3.1 in raspberry and it has worked fine. I've also installed from here the uv4l raspicam driver. But now I need to modify some capture properties as the ...
0
votes
0answers
54 views

Network access without port forwarding [on hold]

I have a pi connected to a servo motor. The motor is controlled by a python script, which also checks a dedicated gmail account for new mail every minute. If there is new mail the servo does it job, ...
2
votes
2answers
60 views

Proper hardware debouncing my interrupt driven digital electrical meter input?

This is a child of my first problem, I am getting ghosting/bouncing on my digital input, but this question is more hardware related and specific to my problem. I have a RasPi model B. I have read ...
2
votes
2answers
95 views

I am getting ghosting/bouncing on my digital input

I am meassuring data pulses from my electrical meter, giving me one pulse per Watt used. I have 4 electrical meters connected to my Raspberry Pi model B. I have connected them directly like this (no ...
1
vote
2answers
81 views

Executing bash script in python language

I tried to make a python script to make "sudo cp -avr /home/pi/progs/ /var/www/" but wasnt able cuz of errors. Now I want to simply make "ls /var/www/" but I got those errors: Traceback (most ...
2
votes
2answers
102 views

9 Data Bits on UART pins?

I am wondering if it is possible to send 9 data bits framed with a start/stop bit at 1.25MBaud. I am currently using PySerial to configure the UART pins on the pi. I've stumbled across a few ...
2
votes
2answers
43 views

Headless RaspberryPi Network Login [Proxy]

I am connecting my RaspberryPi to my school's WiFi network which is fine for local operations like SSH, but the school has a web login to associate the IP with a user account which grants internet ...
0
votes
1answer
28 views

Enable GPCLK line for 1MHz (or greater) clock

I'm trying to drive a TLC5940 with a brand new RPi Model A+ (V1). I plan to use the Pi's SPI bus to pipe data to the chip, which I've done successfully before using an AVR. The part I'm stuck with is ...
0
votes
0answers
10 views

wireless - unable to retrieve number of connected clients as iw throws errors

i've sucessfully set up my wifi AP on raspi, and i have problems with implemting python script to handle the adafruit's lcd shield. The problem is that iw dev wlan0 station dump says nl80211 not found ...
3
votes
4answers
216 views

Why is Python the preferred language for the pi

Why is python perceived as the preferred language to control and manipulate Raspberry Pi? Why is Python language chosen over other other programming languages like PERL, etc. (which are included ...
0
votes
1answer
42 views

Pins I2C cannot be used as input

When using pin 3 and 5 as inputs, I get only 3.3v and I'm not able to use them as inputs. I use the same code and circuit on all the GPIO pins the circuit worked on every single pin except on this 2 ...
0
votes
1answer
70 views

Weak performance during motion detection with picamera and python script

To dig into the picamera python api i just started a simple motion detection script. It runs in the videomode with 2 frames/second and a resolution of 320x240. Frames are captured with the ...
1
vote
0answers
26 views

Can i setting sampling rate 2k in MCP3008 or python [closed]

Can i setting sampling rate 2k in MCP3008 or python. I think to do this a long time but i don't have no idea. please help, thanks.
0
votes
0answers
31 views

PySerial not responding after 10 seconds of inactivity

I've got the JY-MCU Bluetooth module connected to the hardware serial port on my Raspberry Pi. It seems to be working except for one thing: when there is no communication for about 10 seconds or more, ...
0
votes
1answer
61 views

GPIO problems, when run infinitely goes to the right

I'm trying to get a controller to move right, preferably one space, using GPIO. I'm not quite sure what I'm doing wrong but whenever I run the script it moves to the right but it never stops. I don't ...
0
votes
1answer
59 views

How to measure DC current RPi?

I have recently bought a Raspberry Pi, and I would like to be able to measure the current flowing through the circuit in our Greenpower electric racing car. It would also be useful to record this for ...
0
votes
1answer
106 views

Run a python script from terminal

i'm new to raspi. I try to run a python script from terminal (with typing not autostart when boot) Firstly, i directed the directory to my desired folder with cd /desireddirectory Then i try to run my ...
0
votes
2answers
51 views

I2C receive handler, as seen on I2C for Arduino

When managing smbus/I2C devices using python with the RPi, is there a way to register a handler function so it is called when a byte is available for read, like in Arduino Wire.onReceive()? Otherwise, ...
0
votes
1answer
35 views

Check whether an I2C slave device is ready or not

I'm using an I2C device connected to an RPi. The device only handles receiving one byte (which is then transferred via radio to a similar device on the other end, that acknowledges the reception of ...
0
votes
1answer
57 views

Speech Recognition

I'm making a project that requires the user to control the computer through speech. I've seen a couple of libraries, for python, that can do this but most of the ones that I have seen are windows ...
0
votes
0answers
52 views

Lighttpd + Python FastCGI not cooperating

I have a Flask App on my Raspberry Pi, the structure is /home/pi/microblog/ app db_upgrade.py runp.py app.db flask runp-sqlite.fcgi babel.cfg killpython ...
1
vote
0answers
121 views

Send SMS using Pi

I have a project, and I would like to send SMS message from Pi to my number phone, when I run it the command says: cannot send message: Process exited with a non-zero status I used SMS gateways to ...
0
votes
1answer
30 views

Raspberry Pi and lirc communication

So I've been working with lirc and pylirc and am looking at trying to communicate between 2 PIs using this technology. My question is how fast can I expect communication being if sending a single ...
0
votes
1answer
38 views

pyramid framework on raspberry pi

Before I buy a raspberry pi ( being honest ), I'd like to know if it is possible to run a pyramid python framework from raspberry Pi. If so, then how ? I know LAMP runs on it but at present I am ...
1
vote
1answer
166 views

GUI for Pi - Python or Java

I would like to know whether a Java based (using Pi4j library and Swing) or Python based GUI (using Tkinter) is more suitable for Pi in terms of execution speed. Following things need to be ...
0
votes
1answer
53 views

Fail to print using python-cups: “client-error-document-access-error”

I am trying to Print to USB HP printer through python. I was successfull in printing a text file using Ctrl-P command through gui after setting up CUPS using the WEB method. Now I am trying to print ...
0
votes
1answer
32 views

'var gpio' INVALID SYNTAX in IDLE3, Raspberry Pi

I'm new to Python and Raspberry Pi. I'm trying to drive a stepper motor with the Rpi from this website: http://www.sundh.com/blog/2014/02/control-stepper-motors-with-raspberry-pi-and-node-js/ I find ...
0
votes
0answers
30 views

Get connected(paired) device on bluetooth

Is there anyway in command lines or even python to get the Paired device at the exact moment? I've googled some of them but got nothing... I know there are commands to list all active devices nearby, ...
2
votes
4answers
153 views

GPIO Pin 17 does not trigger RPi.GPIO callback

I'm trying to read from all my Raspberry Pi B+ GPIOs. Using the Python3 RPi.GPIO library, it is quite easy to do, but I've come across a problem that I can't seem to resolve : GPIO 17 does not ...
1
vote
0answers
49 views

Determining position with motion detection - Camera Module

I currently am working on an art project that requires to know the position of a person within 3 columns. I have figured that I can achieve this result by motion detection by comparing one frame ...
0
votes
0answers
37 views

Error while running a Python GUI application using tkinter from command line

While running an python code for GUI from command line (command : sudo python SampleGUI.py), I get this error Traceback (most recent calls last): from tkinter import * ImportError: No module name ...
0
votes
0answers
141 views

Using python with bluetooth to communicate

I'm trying to write a simple program to communicate between the RPi and a bluetooth cellphone. I went with this tutorial: Bluetooth Python tutorial for RPi and was able to connect to the phone and ...
1
vote
1answer
93 views

How to get RPi to generate a triangle wave, then outputting a PWM signal

I want my Raspberry Pi B+ Model to generate a triangle wave and output a PWM signal from one of the GPIO pins, but I'm not sure how to go about doing this. All I want it to do is add some small length ...
1
vote
1answer
27 views

pyspi and file descriptors

Has anyone else noticed that py-spidev seems to leave a file descriptor open? When I run lsof -p 5833 I see that my program has 5 file descriptors open, which seems fine. When I run sudo lsof -p 5833 ...
0
votes
2answers
62 views

sleep() affecting only one certain output

the topic name might seem a bit chaotic, but I'm struggling to describe in one line what I mean. I want to create a python script that plays different sounds when certain button is pressed. So far I ...
1
vote
0answers
38 views

How to display black screen on raspberry pi

I am currently displaying an image on boot and when I press a button I want to show a black screen. My idea is to just load up a second black image in the background with qiv and then switch to it. My ...
0
votes
2answers
122 views

Interfacing with a Winbond W25Q64BV flash chip via SPI

I'm trying to interface with a Winbond W25Q64BV flash chip via SPI. I started off by testing it on Arduino (target is a Raspberry) as I found a few implementations before I got started. Most notably ...
0
votes
0answers
93 views

Not all arguments converted during string formatting Jasper

When I'm starting Jasper, I have a problem: Error Occured! Traceback: File "/home/pi/jasper/jasper.py", line 145, in app = Jasper() File "/home/pi/jasper/jasper.py", line ...
0
votes
0answers
43 views

Piface input pins as output with pifacecommon

I know it is possible to use the input pins on the piface as output pins. (src: https://projects.drogon.net/piface-abuse-using-inputs-as-outputs/) But how is this achieved using the pifacecommon ...
0
votes
0answers
30 views

Difference pifacedigitalio and wiringpi2 piface ouput pins

I would like to use a stepper motor connected to the piface with the wiringpi2 python module. I found some code online for testing stepper motors. import pifacedigitalio as pfio pfio.init() def ...
0
votes
1answer
78 views

Sending i2c commands from arduino to pi

The RPi and arduino are connected by I2C and the arduino sends coordinates to the RPi through the wire library. However, the RPi only receives and prints out 0 when it should print out the coordinate. ...
0
votes
0answers
51 views

Audio playback with Python: xcb_connection_has_error()

I'm a newbie to RasPi and Python, so please forgive me for asking a dump question :) I want to playback a wav file with Python 2.7.3 on my RaspberryPi B+ (model name: ARMv6-compatible processor rev 7 ...
0
votes
1answer
31 views

Installing python packages in the correct version [closed]

I've built python 3.4 from source and installed it. I also installed pip. When I try to install packages with 'pip3 install', it installs to python 3.2. How can I make pip install packages for python ...
-1
votes
2answers
115 views

Good way to start python script at startup with automatic restart if it crashes? [duplicate]

I've edited my rc.local to start my python script when the Pi boots up (like here). How can it be done to restart the script automatically if it crashes? It would be best if a re-start would be ...
0
votes
1answer
60 views

sudo for part of a python script [closed]

I have a program that automatically calls the following script. The script works up to point x but needs root privileges to perform the code from this point on. Can I give the script sudo privileges ...