Onboard station

This pull request builds on pull request #1256 and fixes a bug that caused the time-based onboard depart feature to fail while the vehicle was inside a station.