Utility function to translate a Wi-Fi frequency to its corresponding channel.
frequency
the channel represented by the frequency or 0