Author Topic: USB - Printing data from a VNC2 platform  (Read 6034 times)

VinceLeslie

  • Member
  • ***
  • Posts: 2
USB - Printing data from a VNC2 platform
« on: May 27, 2014, 06:09:23 pm »
I have an issue where my VNC2 host application does not cause Bulk Out data to be printed out to a printer.
My slave printer device is HP LaserJet printer. I am using a Beagle USB 480 to analyze USB traffic. My host test platform is now simplified to using Vinculem's V2Eval board loaded with their own Host printer sample code. I have exhausted support from Vinculum and have no solution. 
I can printer to the printer from my PC so I have printed to a file and followed the resulting file. But even better yet I used the USB 480 to monitor traffic between PC and printer and compared that to V2Eval board to printer.
A couple interesting things from the PC to printer.
During setup I see a SETUP packet setting Interface to 0 and ALT. to 0.
My code is not doing this.
Q: Why is interface being set to zero, I thought Default pipe is 0 and only used for config.
After Interface is set to zero there is a lot of Data Packets. The following list is of first ones with PID and CRC removed.
SOF
383  Out0 0x00 0x00 0x00 0x08 0x01 0x00
SOF
389  Out1 0x00 0x20
394  In0   0x00 0x00 0x00 0x09 0x01 0x00
SOF
400  In1   0x80 0x00 0x20
SOF
406  Out0 0x00 0x00 0x00 0x08 0x01 0x00
411  Out1  0x0a 0x02
SOF
417  In0  0x00 0x00 0x00 0x0e 0x01 x00
422  Out0  0x00 0x00 0x00 0x0f 0x01 0x00
427  Out1 0x01 0x02 0x02 0x10 0x06 0x04 0x00 0xff 0xff
SOF
433  In1  0x8a 0x00 0x02 0x50 0x52 0x49 0x4e 0x54
442  In0 0x00 0x00 0x00 0x12 0x01 0x00
447  Out  0x00 0x00 0x00 0x0b 0x01 0x00
452  Out  0x03 0x02 0x02 0x00 0x20
SOF
Q: What is this data, it can't be PCL commands be cause there are no esc characters. It certainly is not my text data from my print. My V2Eval platform isn't doing this either.

Thanks,
Vince

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: USB - Printing data from a VNC2 platform
« Reply #1 on: May 27, 2014, 08:41:14 pm »
bInterfaceNumber = 0 and bAlternateSetting = 0 is typical. However, these are the defaults so no need for the host to set them. No harm in doing so either.

Is the data you show transferring on endpoint 0, bulk endpoints, or some of each? (I'm not sure what Out0, Out1, etc. refer to.)


VinceLeslie

  • Member
  • ***
  • Posts: 2
Re: USB - Printing data from a VNC2 platform
« Reply #2 on: May 27, 2014, 09:06:40 pm »
Thanks,
Out0 are Bulk Data0
Out1 are Bulk Data1

Jan Axelson

  • Administrator
  • Frequent Contributor
  • *****
  • Posts: 3033
    • Lakeview Research
Re: USB - Printing data from a VNC2 platform
« Reply #3 on: May 27, 2014, 10:16:10 pm »
Not much help, but printers also use PJL. However, those commands begin with @PJL, and I don't see that in your data.