Hello there, I am using the USB8452 to do a SPI communication to a display device through the USB845x C API. The device requires 10 bits data for 1 pixel frame. I am trying to write [0x0A] to the pixel at 10 bits per sample but this warning pops up after I set this ni845xSpiStreamConfigurationSetNumSamples to 10 bits per sample. It says that warning 301701 NI-845x: The passed in array of data bytes is not an exact multiple of the sample size. The remaining bytes beyond that last complete sample have been discarded.
Do correct me if I'm wrong, the expected transmission should be 0b0000 0010 10 as 0x0A supposedly become 10 bits, but the output that is been observed through oscilloscope is 0b1000 00 1010. The output will be different. I am not sure but there is like an offset happening because when I tried sending [0x0A, 0x0A] it now does not become [0b1000 0010 10, 0b1000 0010 10] as the first byte is being send like that. So, I conclude that the offset is random.
I did try with [0b0000 0010 10] a 10-bit data input, but it still does not give the correct output observed in the oscilloscope. As I said before, the output should be 0b0000 0010 10 when we see it in the oscilloscope. My question is how does the function ni845xSpiStreamConfigurationSetNumSamples works? if I set it to 8 bits it works just fine as I expected it would.
Thank you.