Improvements to the proxy functionality

This patch contains two improvements: It implements the PROXY function, and it also enabled the restart functionality for the DEVICE function. The latter is needed on OSX since you can get sporadic interruptions where you need to invoke the "continue" restart.