Does MK26F support USB Host/device?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Does MK26F support USB Host/device?

829 Views
neilhancock
Contributor IV

I'm using the MK26F on a custom board. MK26F is supported by KSDK1.3.

However MK26F seems to be missing from the KSDK1.3 directory tree.

Is it OK to substitute the K65F18 instead?

Are there any examples of using the K26F Uart Host CDC_Serial?

thanks

87393_87393.pngpastedImage_0.png

87394_87394.pngpastedImage_1.png

Labels (1)
Tags (3)
4 Replies

448 Views
DavidS
NXP Employee
NXP Employee

Hi Neil,

You can use the TWR-K65 example code for K26.  K26 is subset of K65.

Then you can use the following example:

C:\Freescale\KSDK_1.3.0\examples\twrk65f180m\demo_apps\usb\host\cdc\cdc_serial

Regards,

David

448 Views
neilhancock
Contributor IV

Hey thanks for the quick answer.

So following the recommendation

- from a new project - import the project KSDK_1.3.0 USB Host at

KSDK_1.3.0\examples\twrk65f180m\demo_apps\usb\host\cdc\cdc_serial

which creates a virtual project - host_cdc_serial_freertos_twrk65f180m mapped to

C:\Freescale\KSDK_1.3.0\examples\twrk65f180m\demo_apps\usb\host\cdc\cdc_serial\freertos\kds

then update the board files - board.c/.h files to reflect my custom board based on the K26

which are in a virtual folder  /host_cdc_serial_freertos_twrk65f180m/board

and I think maps to the physical tree/files

C:\Freescale\KSDK_1.3.0\examples\twrk65f180m

I'm wondering it seems like the the USB adapter sources have a different OS Abstraction that the rest of the KSDK_1.3

cdc_serial.c uses

OS_Task_create(Task_Start, NULL, 4L, 3000L, "task_start", NULL);

which comes from

C:\Freescale\KSDK_1.3.0\usb\adapter\sources\sdk\adapter_sdk.h

were as say the "Low power manager RTOS demo" task is different

OSA_TaskCreate(task_lpm,     (uint8_t *)"lpm", TASK_LPM_STACK_SIZE, task_lpm_stack, TASK_LPM_PRIO, (task_param_t)0, false, &task_lpm_task_handler);

Which is the latest leading edge? Is it OSA_TaskCreate()  and do you know of any issues if the the USB OS_Task_create() is replaced/merged in with other nonUSB KSDK_1.3.0 OSA abstraction examples like the "power_manager_rtos_demo"?

many thanks

0 Kudos

448 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Neil,

I'd highly recommend that you can find some useful documents about KSDK USB stack which reside in ~\Freescale\KSDK_1.3.0\doc\usb, such as reference manual and porting new platform user's guide.

And I think these documents will do a great favor for you.
Have a great day,
Ping

2015-10-29_11-04-18.jpg

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

448 Views
neilhancock
Contributor IV

Thanks for the references. Yes I had found them and very much appreciate some of the explanation in them.

I have appreciated some of the working examples of USB Host MSC to SD card on the FRDM-K64

However working from the basic KSDK/usb, this integration hasn't worked for me, and it seems as I identified above it is not on the same technical page as other parts of the KSDK with undefined integration risks for the future.

Also its not in the KSDKxx\middleware directories but in its own directory. I assumed this was part of marketing as technically USB is an enabler for IoT.

I moved onto another aspect of the project as there wasn't a response to the licensing questions I posed here

KSDK1.2 License question ?

So I suspended the integration effort  in favor of looking at other extensible options.

One option is that mbed has a basic USB framework that has been contributed by a thirdparty, initially designed for an NXP processor but it did work for me in one limited test with a KL25Z. The implementation as USB host is limited and not event driven, but was a working starting point and does seem like it might be a more stable way ahead.

Another option is that the supplied USB stack with a BSD licenses is available on other processors, just maybe I have to put the effort in to learn about those processors. I like the K26, but my evaluation is that the software hurdle is too large to make it work for the product I'm targeting.

0 Kudos