Reliable destruction
Pierre-Eric.Melchy at uni-konstanz.de
Pierre-Eric.Melchy at uni-konstanz.de
Fri Aug 5 04:09:10 EDT 2005
Hello,
your idea sounds good and handles the exception on teardown as well.
(I did not think about the if XXX!=None check in teardown())
I will now provide each of the instruments with an explicit shutdown()
method which frees the interface card as well.
These methods will be called in a finally clause after run.
I think this is much better than to wait for or rely on garbage
collection.
Of course there is a hardware protection of the setup as well.
I am amazed how well Python handles lab instrumentation, it is really
fun to develop with Py.
Many thanks for your help
More information about the Python-list
mailing list