On 18/03/2015 18:28, Doug Basberg wrote:
I do real-time controls programming and I control a relay in a python program that must be turned off before the program ends. First, the program should never exit unless I do it explicitly. Is there a 'hook' to process before any exit (even if not expected). I must turn off that relay or harm may occur. Thanks, Doug
https://docs.python.org/3/library/atexit.html -- My fellow Pythonistas, ask not what our language can do for you, ask what you can do for our language. Mark Lawrence _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor