i2c control specification for vocalfusion
Posted: Fri Nov 16, 2018 12:18 pm
Hi,
We've built a board based on the mono AEC vocalfusion reference design and want to control parameters like AEC on/off and tuning using i2c from another device in our hardware stack.
I am looking for a specification of the i2c commands that I can use to do this.
I have already seen that there are example host programs that can be run on the Raspberry Pi, and I realise it should be possible to reproduce this on our own hardware but it's difficult to decipher from the source exactly what is included in the payload and in what order.
I have also checked the documentation in lib_device_control, but the very general specification there doesn't seem to match the specific checks that I can see in e.g. the vf_control.xc file in module_vocalfusion. For example the vocalfusion code checks for the 'type' of the payload data, which is written in the payload, and also grabs the actual parameter value from from the payload at an offset position:
memcpy(¶m_type, &(payload[8]), sizeof(unsigned));
memcpy(&temp_param_f, &(payload[4]), sizeof(unsigned));
Is there any resource that states in a clear way exactly how an i2c command should be structured? Am I missing something? (I have checked the forums and the docs as best as possible, sorry!).
We've built a board based on the mono AEC vocalfusion reference design and want to control parameters like AEC on/off and tuning using i2c from another device in our hardware stack.
I am looking for a specification of the i2c commands that I can use to do this.
I have already seen that there are example host programs that can be run on the Raspberry Pi, and I realise it should be possible to reproduce this on our own hardware but it's difficult to decipher from the source exactly what is included in the payload and in what order.
I have also checked the documentation in lib_device_control, but the very general specification there doesn't seem to match the specific checks that I can see in e.g. the vf_control.xc file in module_vocalfusion. For example the vocalfusion code checks for the 'type' of the payload data, which is written in the payload, and also grabs the actual parameter value from from the payload at an offset position:
memcpy(¶m_type, &(payload[8]), sizeof(unsigned));
memcpy(&temp_param_f, &(payload[4]), sizeof(unsigned));
Is there any resource that states in a clear way exactly how an i2c command should be structured? Am I missing something? (I have checked the forums and the docs as best as possible, sorry!).