/* Determins if the specified Generic Clock channel is enabled.  */
bool system_gclk_chan_is_enabled(const uint8_t channel)
/* Determins if the specified Generic Clock channel is enabled.  */
bool system_gclk_chan_is_enabled(const uint8_t channel)
{
	bool enabled;
	system_interrupt_enter_critical_section();
	*((uint8_t*)&GCLK->CLKCTRL.reg) = channel;
	enabled = GCLK->CLKCTRL.bit.CLKEN;
	system_interrupt_leave_critical_section();
	return enabled;
}