Basic frequency example.
As further exercise, made the call check whether the frequency service is available. If not, there is now a cleaner error message.