How can I implement incremental (find-as-you-type) search on command line?

I'd like to write small scripts which feature incremental search (find-as-you-type) on the command line. Use case: I have my mobile phone connected via USB, Using gammu --sendsms TEXT I can write...

Getting LONG_BIT error when installing gammu in Mac OS X using GCC 4

I'm trying to install Python-Gammu on a mac running Snow Leopard. I successfully configured gammu with cmake and GCC 4, but am getting this error on install. It seems to indicate an improperly...

Sony Ericsson registers two devices when connected to USB port

I am very curios that why does every Sony Ericsson phone (w200i,2660 etc) register two ttyACM devices when connected to PC via USB? This also introduces complications in interfacing with the...

why does setting stderr=subprocess.STDOUT fix a subprocess.check_output call?

I have a python script running on a small server that is called in three different ways - from within another python script, by cron, or by gammu-smsd (an SMS daemon with the wonderful mobile...

subprocess call failing with unicode data from web form input - works with same input from elsewhere

I have a library that contains a function that checks various input data against a number of regexps to ensure that the data is valid. The function is called both for input received by a CGI...

How to return Gammu Python SendSMS function Sent Status?

Hi and thanks for taking the time to help. I'm currently using the following code #!/usr/bin/env python # Sample script to show how to send SMS import gammu import sys sm =...

How to send and receive SMS from python using usb modem?

I'm a beginner in python and i'm looking for a library to send and receive SMS through a Huawei modem. I tried gammu, pysms and pygsm but failed to get them to work. Could you give me code...

Python error when tryint to access list by index - “List indices must be integers, not str”

I have this Python code: sm.GetSMSStatus() sm.GetSMSFolders() sms = sm.GetNextSMS(Start = True, Folder=0) sms = sm.GetNextSMS(Location = sms['Location'], Folder=0) sms = sm.GetSMS(Location =...

How to use setup.py in Python gammu

I download the gammu source files. My aim is to be able to use the gammu module in my python program. How do I run the setup.py install for python-gammu. Each time I try, I get running...

Gammu how to load balance between two modems

I have two GSM USB modems connected to my server, and we use gammu send SMS. We would like to load balance between both the modems, so that if 100 messages are send in day 50 goes from first and...

gammu.ERR_TIMEOUT - Raspberry pi

Good afternoon! I have a problem and do not know how I can solve it. I am using gammu and did my python code and I'm using the raspberry pi, so far so good! The problem is that after some time...

Error while executing a python script to send SMS from PHP

Edit Actually, the problem can be solved using the path of the configuration file as a parameter of the function sm.ReadConfig(Filename="/home/myuser/.gammurc") I'm using the Gammu library for...

gammu receive sms message python fails

I have found a script on this website http://wammu.eu/docs/manual/smsd/run.html #!/usr/bin/python import os import sys numparts = int(os.environ['DECODED_PARTS']) # Are there any decoded...

Python USB Serial ports connection

I'm running a python code which is plugged with two serial ports, a huawei dongle and a zigbee. I understand that In order to find out which port the dongle is using I must use gammu. And the...

Python serial ports

I need to run both zigbee and SMS dongle on a raspberry pi, that means having to run both ports in a python script. Since xbee is always on ttyUSB0, is there a way I could set the dongle on...

How to install python-gammu on Raspberry pi

I have a problem when installing the python module for gammu on a raspberry pi model b+. How can i solve this problem ? Thanks! [email protected] ~ $ sudo pip install...

import gammu class - getting error no module named

I just want to get status from gammu import gammu.smsd smsd = gammu.smsd.SMSD('/etc/gammu-smsdrc') print smsd.GetStatus() I saved code to /home/pi/mypython.py and ran it from terminal sudo...

Error( Failed to get SMSC number from phone) in python-gammu when sending sms

I got this error in sending sms: gammu.ERR_GETTING_SMSC: {'Text': u'Failed to get SMSC number from phone.', 'Code': 69, 'Where': 'SendSMS'} Here is the code I use import gammu sm =...

Gammu on my Raspberry Pi (2 and 3) works perfectly only for 30 minutes

I meanwhile installed gammu in two different raspberry pi (2 and 3), and it works fine - but only for rather exactly 30 minutes. The daemon (according to top) continues, but no sms is sent or...

send sms with variable in gammu [python]

Im trying to send a variable in an sms using gammu. Im using the gammu smsd runonreceive to run a python script when I send a message to my raspberry pi from my phone. This is what the script...

python-gammu not working with sudo

I'm trying to make run a SMS sending python script from PHP. SendSMS.py: #!/usr/bin/env python import gammu sm=gammu.StateMachine() sm.ReadConfig() sm.Init() message={ ...

Gammu on raspberry Zero

I am trying to setup a raspberry zero to collect the temperature from a DS18B20 probe connected to a -20°C fridge of my lab. If a temperature above a certain value is detected, the raspberry...

Failed to Sending SMS with gammu (Error 500)

Problem: [email protected]:~ $ echo "Test" | sudo gammu sendsms TEXT +937******** If you want break, press Ctrl+C... Sending SMS 1/1....waiting for network answer..error 500, message...

python subprocess.run() returns AttributeError: 'module' object has no attribute 'run'

I'm trying to execute a shell command from a python script. I'm using python 3.7.3, so the run() function should work properly, but it always throws the AttributeError: 'module' object has no...