Revision history [back]
My guess is when you're logged into the Raspberry Pi you are running the code with sudo and this is not being done by Wing's remote agent. Probably the solution is setting access permissions so the user can access it without sudo. The selected answer for http://stackoverflow.com/questions/34533913/python-rasberry-pi-piano-hat-permission-denied and the document it links to may be what you need.