initilize a memory zone in python
Diez B. Roggisch
deets at nospam.web.de
Sun Aug 30 22:58:54 CEST 2009
> hello, i'm new in python, i used to program in C,
> i have a small problem, i tryed to do some serial port things
> with python.
> i have something like:
> import sys,termios
> fd = sys.stdin.fileno()
> now i want to modify the actuall values in term_conf zone to zero
> i don't see how to do it,
> in C we can do : bzero(&term_conf,sizeof(struct termios));
> i want to know if it exist a similar function in python, thanks
In python you don't modify memory like that.
For the above function, you pass a value as the one you got to
tcgetattr, with values modified as you desire them.
More information about the Python-list