commands and events for digital pin