Trivial: Use "with" for locks where applicable
Enhancement: Replaced "dNG.pas.pythonback" functions with
"dNG.pas.data.binary" methods