1
0
Fork 0

Enables HFXO to ensure UART clock stability

This commit is contained in:
Shawn Nock 2019-06-26 10:55:43 -04:00
parent 3ba65efbaa
commit cae7b49c35
1 changed files with 5 additions and 3 deletions

View File

@ -603,6 +603,9 @@ static int h5_open(struct device *unused)
uart_irq_rx_disable(hci_uart_dev);
uart_irq_tx_disable(hci_uart_dev);
/* Enable HFXO so that UART clock is stable for 115200 bitrate */
*(uint32_t *)0x40000000 = 0x1;
bt_uart_drain(hci_uart_dev);
uart_irq_callback_set(hci_uart_dev, bt_uart_isr);
@ -617,7 +620,8 @@ static int h5_open(struct device *unused)
#if defined(CONFIG_BT_CTLR_ASSERT_HANDLER)
void bt_ctlr_assert_handle(char *file, u32_t line)
{
printk("Assert %s:%u", file, line);
printk("BT_CTLR Assert %s:%u", file, line);
sys_reboot(SYS_REBOOT_COLD);
}
#endif /* CONFIG_BT_CTLR_ASSERT_HANDLER */
@ -756,5 +760,3 @@ next:
net_buf_unref(buf);
}
}