mirror of
https://github.com/tillitis/tillitis-key1.git
synced 2024-12-18 12:24:31 -05:00
Update bit divisor calc in verilator's uart to our current 18 MHz
This commit is contained in:
parent
6f31bbe37a
commit
2bb62af183
@ -24,10 +24,9 @@
|
||||
#include "Vapplication_fpga.h"
|
||||
#include "verilated.h"
|
||||
|
||||
// Joachim says:
|
||||
// Clock: 12 MHz, 38400 bps
|
||||
// Divisor = 12*10E6 / 38400 = 312
|
||||
#define BIT_DIV 312
|
||||
// Clock: 18 MHz, 38400 bps
|
||||
// Divisor = 18*10E6 / 38400 = 468.75 ~ 469
|
||||
#define BIT_DIV 469
|
||||
|
||||
struct uart {
|
||||
int bit_div;
|
||||
|
Loading…
Reference in New Issue
Block a user