diff options
author | Uros Majstorovic <majstor@majstor.org> | 2018-03-16 16:49:37 +0100 |
---|---|---|
committer | Uros Majstorovic <majstor@majstor.org> | 2018-03-16 16:49:37 +0100 |
commit | b623f680f6a7aa53de6a1d949d857b37f391c80d (patch) | |
tree | 16f5bd03a46c748dcf5baedc3f3c88ca508860a8 /code/fe310/eos/i2s.c | |
parent | b1c3ee27894d33d9fcfca4ea4d0ccfb6d4cfc83e (diff) |
fixed irq handlers for ci/sd
Diffstat (limited to 'code/fe310/eos/i2s.c')
-rw-r--r-- | code/fe310/eos/i2s.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/code/fe310/eos/i2s.c b/code/fe310/eos/i2s.c index 64152dd..3b1772c 100644 --- a/code/fe310/eos/i2s.c +++ b/code/fe310/eos/i2s.c @@ -112,13 +112,13 @@ void eos_i2s_init(void) { I2S_PWM_REG_CK(PWM_COUNT) = 0; I2S_PWM_REG_CK(PWM_CMP0) = _eos_i2s_ck_period - 1; I2S_PWM_REG_CK(PWM_CMP1) = I2S_PWM_REG_CK(PWM_CMP0) / 2; - I2S_PWM_REG_CK(PWM_CMP2) = I2S_PWM_REG_CK(PWM_CMP0) / 2; + I2S_PWM_REG_CK(PWM_CMP2) = I2S_PWM_REG_CK(PWM_CMP0) / 8; I2S_PWM_REG_WS(PWM_CFG) = 0; I2S_PWM_REG_WS(PWM_COUNT) = 0; I2S_PWM_REG_WS(PWM_CMP0) = _eos_i2s_ck_period * 64 - 1; I2S_PWM_REG_WS(PWM_CMP1) = I2S_PWM_REG_WS(PWM_CMP0) / 2; - I2S_PWM_REG_WS(PWM_CMP2) = I2S_PWM_REG_WS(PWM_CMP0) - 1024; + I2S_PWM_REG_WS(PWM_CMP2) = I2S_PWM_REG_WS(PWM_CMP0) - _eos_i2s_ck_period; eos_intr_set(I2S_IRQ_SD_ID, I2S_IRQ_SD_PRIORITY, NULL); eos_intr_set(I2S_IRQ_CK_ID, I2S_IRQ_CK_PRIORITY, NULL); |