USB Audio 2.0 with DFU disabled error

Sub forums for various specialist XMOS applications. e.g. USB audio, motor control and robotics.
Post Reply
User avatar
bowerymarc
Active Member
Posts: 40
Joined: Mon Dec 30, 2013 7:29 am
Contact:

USB Audio 2.0 with DFU disabled error

Post by bowerymarc »

usb audio 6.15.2rc1 - disable DFU, compiles. But gets this runtime error:

Code: Select all

tile[0] core[5]  (Suspended: Signal 'ET_ECALL' received. Description: [i]<path to>[/i]/sw_usb_audio-[sw]_6.15.2rc1/sc_usb_audio/module_usb_audio/main.xc:395:110: error: passing null argument to a non-null parameter.)	
	2 _Susb_audio_core_0.task.Endpoint0.2() main.xc:395 0x000130e0	
	1 __start_core()  0x0001647e	
and the line in question:

Code: Select all

           Endpoint0( c_xud_out[0], c_xud_in[0], c_aud_ctl, c_mix_ctl, c_clk_ctl, c_EANativeTransport_ctrl, dfuInterface);
(where main calls Endpoint0).

Now, endpoint0 is 'C' code, not 'XC' so the param dfuInterface is declared as 'unsigned', and it's being passed 'null'. I'm not sure exactly how to fix that properly.... via a cast or...?


User avatar
bowerymarc
Active Member
Posts: 40
Joined: Mon Dec 30, 2013 7:29 am
Contact:

Post by bowerymarc »

I *think* this is fixed by changing the declaration in endpoint0.h to match that in endpoint0.c:

Code: Select all

extern "C" {
void Endpoint0(chanend c_ep0_out, chanend c_ep0_in, chanend c_audioCtrl,
        chanend ?c_mix_ctl,chanend ?c_clk_ctl, chanend ?c_EANativeTransport_ctr, CLIENT_INTERFACE(i_dfu, dfuInterface));
}
Post Reply