Rozhraní mezi Pythonem a Gammu
Gammu také obsahyje rozhraní pro Python, které vám umožní použít (většinu) funkcí Gammu z programovacího jazyka Python.
Poslední novinky
python-gammu 3.3.0
python-gammu 3.3.0 has been just released. This release is available from GitHub.
Vydal Gammu release automation dne 28. července 2026
python-gammu 3.2.6
python-gammu 3.2.6 has been just released. This release is available from GitHub.
Vydal Gammu release automation dne 10. února 2026
Stáhnout
Python module is now standalone, so please
download it separately. If you want to use binary
package, the daemon might be included in separate binary package in your
distribution, try looking for something like python-gammu.
Nejjednodušší je instalovat pomocí pip:
pip install python-gammu
Příklad
Using python-gammu is quite simple, for example sending of the text message can be done by following snippet:
import gammu
sm = gammu.StateMachine()
sm.ReadConfig()
sm.Init()
message = {
'Text': 'python-gammu testing message',
'SMSC': {'Location': 1},
'Number': '+420800123465',
}
sm.SendSMS(message)
Dokumentace
API documentation is available, but you might also find useful libGammu documentation. Please check developer documentation page for more details.
Check also Frequently Asked Questions.
Zdrojový kód a sledování chyb
Zdrojový kód i sledování chyb naleznete na GitHubu: