Hello,
We recently moved from Coldfire to the Kinetis line and have been looking for usb printer sample. On the Coldfire series using USB stack 4.1.1 we can enumerate as a printer without issue.
A few questions that hopefully you can clear up for us:
Cory
I can't ofer you a printer class solution out of the box but you could look at the uTasker project which has USB device support. It is fully compatible with the K22F (and all other KL and K parts with USB) and has been operated in USB-MSD, HID-mouse, HID-keyboard, HID-Kboot, USB-CDC modes as well as composite mixtures of them (including multiple CDC instances mixed with other classes). See for example Re: Re: Kinetis bootloader v. 1.1
However the solution has a few advantages:
1. It has very clean construction consisting on a hardware driver (HAL to the USB generic layer), a generic USB layer (HW and class independent) and a class/application layer. This means that there are no porting difficulties - there is also a Coldfire HAL which means that the USB generic and class layers can be used on Kinetis (KL or K parts) or Coldfire parts with no changes required.
2. It allows USB operartion to be simulated to analyse cases or develop new applications/classes. If you have a USB recording of a printer class in operation the sequences can be played through the code for development/debugging without need for HW which feels a bit like cheating in some ways. It was possible to develop and debug (reverse engineer) something like the KBOOT HID protocol in about 3 hours which then worked on all KL and K parts with no futher effort. I don't know how complicated the printer class is but with a reference recording the details can usually be filled in without much effort.
3. The application/class interface can use different methods depending on each control/application data packet requirements (including peeking in the USB interrupt, handling completely in the interrupt and/or deferring the work to a task level). BULK data pipes can be handled as if they were a bidirectional UART interface which again makes the interface very easy to work with at the class/application layer.
3. The USB device stack has been used and proven in various industrial projects over a period of 5 years on Coldfire and about 2 on Kinetis parts (whereby the USB controller in the Kinetis is almost identical to the one in the Coldfire).
Regards
Mark
Mark,
Thank you very much for your helpful response. I'll take a look at the uTasker offerings and see what we can work with.
Best Regards,
Cory
Hi Cory Todd,
No printer class in the coming KSDK 1.1, and so far no plan to support it yet. Sorry for the inconvenience that has caused.
Have a great day,
Kan
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
NXP,
Has there been any update on the development on a printer class. I know the SDK is on 1.3.0. Just wondering if there is now any plan for doing a printer class?
Thanks,