Sure, you subscribe to mode change events like so:
subscribe(location, modeChangeHandler)
Then in your modeChangeHandler, you can check which mode is being switched to like so:
def modeChangeHandler(evt) {
if (evt.value == "Home")
{
// Do stuff you want when mode changes to "Home"
}
}