Check the pcm format is cpu-endian
int snd_pcm_format_cpu_endian(snd_pcm_format_t format);
format
the format to check
1 if the given PCM format is CPU-endian, 0 if opposite, or a negative error code if endian not specified.