-
Notifications
You must be signed in to change notification settings - Fork 7.6k
tests: drivers: i2s: Add i2s_additional tests #90732
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tests: drivers: i2s: Add i2s_additional tests #90732
Conversation
068a111
to
32a154c
Compare
32a154c
to
7b2b8dc
Compare
{ | ||
struct i2s_config i2s_cfg = default_i2s_cfg; | ||
|
||
i2s_cfg.block_size = 6; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is block size 6 so special that it needs to be tested?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
block_size of 6 bytes is not supported by Nordic's drivers.
https://github.com/zephyrproject-rtos/zephyr/blob/main/drivers/i2s/i2s_nrf_tdm.c#L466C29-L466C45
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, they only support sizes that are multiples of 32-bit words. But I don't think there's actually a need to check this. This test case looks quite weird.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It tests API - i2s_configure() shall return -EINVAL when invalid argument was passed.
https://docs.zephyrproject.org/apidoc/latest/group__i2s__interface.html#ga299003d72146c127f88d7c12c08889cc
Extend I2S testing with additional test cases that verify I2S/TDM driver operation at various configurations. Check: - word sizes of 8, 16, 24, 32 and 48 bits; - one, two, four and eight audio channels configuration; - data format I2S, Left Justified, Right Justified, PCM Long, PCM Short; - data order MSB and LSB first; - bit clock and frame clock inversion; - block size of 6 bytes; - bit clock continuous and gated; - internal loopback; - pingpong option. Signed-off-by: Sebastian Głąb <[email protected]>
7b2b8dc
to
42b583f
Compare
|
Extend I2S testing with additional test cases that verify I2S/TDM driver operation at various configurations.
Check: