AnsweredAssumed Answered

Trying to Run USB Audio Example Code On FRDM-KL25Z

Question asked by Mark Trainer on Aug 13, 2014
Latest reply on Aug 13, 2014 by Mark Trainer

Trying to run USB audio example code on the KL25Z freedom board, once I get a working project then it is easier to understand the mechanisms and customize it for my project's needs.

 

I am using CW10.6 and Freescale USB Stack v4.0.3. I can compile and download the USB_AUDIO_DEVICE_MKL25Z128_PEx demo; albeit a huge (and uncomfortable) list of warnings from pragma's and  unused variables. (see below) This is "out of the box" unhampered project.

 

But upon connecting to the PC, the PC does not recognize the USB peripheral. I receive "USB Device Not Recognized", if I open the device status pane it reads "Windows has stopped this device because it has reported problems. (Code 43)"

 

I have similar difficulties with all the USB demos for the KL25 and K20 board projects (USB audio and CDC). Is there something silly that I am doing on my end?

 

 

 

 

 

In file included from ../Sources/USB/app/audio_generator/audio_generator.c:23:0:

C:/Freescale/Freescale USB Stack v4.0.3/ProcessorExpert/Examples/Device/Audio/USB_AUDIO_DEVICE_MKL25Z128_PEx/Sources/USB/app/common/kinetis/hidef.h:20:0: warning: ignoring #pragma gcc_extensions on [-Wunknown-pragmas]
C:/Freescale/Freescale USB Stack v4.0.3/ProcessorExpert/Examples/Device/Audio/USB_AUDIO_DEVICE_MKL25Z128_PEx/Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Sources/USB/app/audio_generator/audio_generator.c: In function 'TestApp_Init':

../Sources/USB/app/audio_generator/audio_generator.c:120:14: warning: variable 'error' set but not used [-Wunused-but-set-variable]

../Sources/ProcessorExpert.c:38:6: warning: return type of 'main' is not 'int' [-Wmain]

../Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Generated_Code/usb_audio.c: In function 'USB_Service_Audio_Status_Interrupt':

../Generated_Code/usb_audio.c:93:12: warning: variable 'producer' set but not used [-Wunused-but-set-variable]

../Generated_Code/usb_audio.c: In function 'USB_Service_Audio_Isochronous_IN':

../Generated_Code/usb_audio.c:161:21: warning: variable 'iso_in_recv' set but not used [-Wunused-but-set-variable]

../Generated_Code/usb_audio.c:160:12: warning: variable 'producer' set but not used [-Wunused-but-set-variable]

../Generated_Code/usb_audio.c: In function 'USB_Audio_Get_Feature_Unit':

../Generated_Code/usb_audio.c:784:12: warning: variable 'status' set but not used [-Wunused-but-set-variable]

../Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Generated_Code/usb_class.c:31:13: warning: 'USB_Device_Init_Params' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:32:13: warning: 'USB_Control_Service' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:33:13: warning: 'USB_Control_Service_Handler' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:34:15: warning: 'USB_Strd_Req_Get_Status' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:35:15: warning: 'USB_Strd_Req_Feature' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:36:15: warning: 'USB_Strd_Req_Set_Address' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:37:15: warning: 'USB_Strd_Req_Get_Config' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:38:15: warning: 'USB_Strd_Req_Set_Config' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:39:15: warning: 'USB_Strd_Req_Get_Interface' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:40:15: warning: 'USB_Strd_Req_Set_Interface' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:41:15: warning: 'USB_Strd_Req_Sync_Frame' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:42:15: warning: 'USB_Strd_Req_Get_Descriptor' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:43:13: warning: 'USB_DCI_CallBack' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:44:13: warning: 'USB_DCI_SetAddressCallback' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:45:15: warning: 'USB_DCI_Get_BDT_Index' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_class.c:46:15: warning: 'USB_DCI_Validate_Param' declared 'static' but never defined [-Wunused-function]

../Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Generated_Code/usb_dci.c: In function 'USB_DCI_SetAddressCallback':

../Generated_Code/usb_dci.c:86:44: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]

../Generated_Code/usb_dci.c: In function 'USB_DCI_OnDeviceSetupPacket':

../Generated_Code/usb_dci.c:257:53: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]

../Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Generated_Code/usb_descriptor.c: In function 'USB_Desc_Set_Cur_Volume':

../Generated_Code/usb_descriptor.c:851:12: warning: variable 'volume' set but not used [-Wunused-but-set-variable]

../Generated_Code/usb_devapi.h:216:0: warning: ignoring #pragma options align [-Wunknown-pragmas]

../Generated_Code/usb_framework.c:42:3: warning: missing braces around initializer [-Wmissing-braces]

Outcomes