Init_I2S bug with WDFL?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Init_I2S bug with WDFL?

Jump to solution
616 Views
bowerymarc
Contributor V

In the Init_I2S PE module:

If you set transmit configuration->word flag configuration to 1, this is the comment and code generated (I2S1.c):

  /* I2S0_RCR3: RCE=0,WDFL=0 */

  I2S0_RCR3 &= (uint32_t)~(uint32_t)((I2S_RCR3_RCE(0x03) | I2S_RCR3_WDFL(0x1F)));                                  

seems the comment is correct, code not so much?

(K20F120M project)

Labels (1)
Tags (2)
0 Kudos
Reply
1 Solution
454 Views
Petr_H
NXP Employee
NXP Employee

Hi,

Please note that RCR register is for receiver, not transmitter. I don't see any issues in the code, it's just maybe little bit difficult to read (uses 1 masks and then inverts them using ~ operator...)

Best regards

Petr Hradsky

Processor Expert Support Team

View solution in original post

0 Kudos
Reply
1 Reply
455 Views
Petr_H
NXP Employee
NXP Employee

Hi,

Please note that RCR register is for receiver, not transmitter. I don't see any issues in the code, it's just maybe little bit difficult to read (uses 1 masks and then inverts them using ~ operator...)

Best regards

Petr Hradsky

Processor Expert Support Team

0 Kudos
Reply