K20 Generator Control in FreeMaster (KM34Z50M_GEN on TWR-KM34Z50M)

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

K20 Generator Control in FreeMaster (KM34Z50M_GEN on TWR-KM34Z50M)

868 Views
mjbcswitzerland
Specialist V

Hi All

I am presently working with the TWR-KM34Z50M and need to do something similar to the K20 based Generator which can be controlled by FreeMaster via USB (see manual chapter 6.6) http://cache.freescale.com/files/32bit/doc/user_guide/TWRKM34Z50UM.pdf

Since there are some strange things going on with the version that is pre-installed on the board I took a closer look and found that the USB device (called KM34Z50M_GEN) may be doing something wrong whenever it sends what looks to be a badly formed SERIAL_STATE (?)

There are 10 bytes of data sent on the INTERRUPT pipe (endpoint 3) which change between

0x00 0x00 0x00 0x00 0x00 0x00 0x02 0x00 0x00 0x00

and

0x00 0x00 0x00 0x00 0x00 0x00 0x02 0x00 0x03 0x00

If this is a SERIAL_STATE notification the first byte should be 0xa1 (and not 0x00) and the second byte 0x20 (and not 0x00).

It could also be an incorrectly formed NETWORK_CONNECTION (which matches the second byte, bNotification) but then the rest makes even less sense.

I believe that this is a CDC class notification and has nothing to do with the FreeMaster protocol itself, and therefore is also not discussed in any FreeMaster documentation.

Is this a bug in the KM34Z50M_GEN and can it be a cause of difficulties?

Regards

Mark

P.S: On a side note - I didn't manage to find a driver for the USB device (TWR_KM34Z50M_K20_Gen.inf according to the TWR-KM34Z50M manual) so I modified an existing CDC driver .inf to match and that seemed to sort it out. Although I searched through various SW packages without success beforehand .. does it actually exist and has it therefore been used before?

0 Kudos
4 Replies

458 Views
mjbcswitzerland
Specialist V

Hi

You can take:

http://www.utasker.com/kinetis/FRDM-K64F/uTaskerFreescaleMultiVirtualCOM_64bit.inf

and modify the

USB\VID_15a2&PID_0044

value to match the VID and PID of the USB-CDC interface at the device.

Regards

Mark

0 Kudos

458 Views
mjbcswitzerland
Specialist V

Hi All

Update: Although I could manipulate an existing CDC .inf file on Windows 7 so that the KM34Z50M_GEN communicates the same trick won't work on Windows 8.1. It refuses to identify that the file matches, whereby I have heard that Windows 8.1 is stricter on what it accepts.

Therefore, does anyone know where the correct file is hiding??

Regards

Mark

0 Kudos

458 Views
mjbcswitzerland
Specialist V

Hi

Update: I managed to manipulate a CDC .inf for Windows 8.1 - I forgot I needed to use a 64 bit type, so the immediate problem has been solved.

However it may be an idea to have the .inf as described in the user's manual obtainable from somewhere.

Regards

Mark

0 Kudos

458 Views
martinzhang
Contributor III

Hi Mark,

I also cannot find the file TWR_KM34Z50M_K20_Gen.inf, could you tell me how to manipulate an existing CDC.inf for Win7, 64 bits OS.

Best Regards,

Martin

0 Kudos