I'm experiencing a problem with a TWR-KV58F220M board and Windows 10.
I have used the board with two different computers - one with Windows Vista and one with Windows 10 Pro. The board works as I expect when I connect the board to the Vista PC via USB. I have used "blinky_KV58" and "bubble_level_tfm" pre-compiled example binaries from the "TWR-KV58F220M Quick Start Package" to test the board.
When I connect the board to the Windows 10 PC via USB I see the following behaviour:
1. The program on the KV58F220M starts running (e.g. the blinky_KV58 program starts flashing the LEDs).
2. After less than 1 second, the program on the KV58F220M stops and the green LED on the board is flashing.
3. The board is enumerated and shows up in Windows as an "MBED microcontroller USB Device". The green LED is on.
4. After 30-40 seconds there is a quick flash of the green LED on the board and the device disappears in Windows.
5. The board is quickly enumerated again and shows up in Windows as an "MBED microcontroller USB Device". The green LED is on. Now, there is a new file on the device file system called "fail.txt" containing the text "TIMEOUT".
6. Steps 4 and 5 are repeated.
If I disconnect and reconnect the board I get:
1. The green LED is flashing.
2. The board is enumerated and shows up in Windows as an "MBED microcontroller USB Device". The green LED is on.
3. After 30-40 seconds there is a quick flash of the green LED on the board and the device disappears in Windows.
4. The board is enumerated again and shows up in Windows as an "MBED microcontroller USB Device". The green LED is on. Now, there is a new file on the board USB device file system called "fail.txt" containing the text "TIMEOUT".
5. Steps 3 and 4 are repeated.
That is, the original program on the KV58F220M never starts.
If I, after having used the board on the Windows 10 PC, connect the board to the Vista PC, then the original KV58F220M doesn't start. I can then program the KV58F220M and start the program by pushing the reset button on the board or by disconnecting and reconnecting the board to the PC.
I have repeated this Windows Vista - Windows 10 cycle multiple times with the result that the KV58F220M program stops working after being connected to the Windows 10 PC.
In order to test whether the problem was caused by the computer or Windows 10 I programmed the KV58F220M with "blinky_KV58" on the Vista PC, then I booted the "Windows 10 PC" with Linux and connected the board via USB. The "blinky_KV58" started running on the KV58F220M and kept on running. I could disconnect and reconnect the board and the "blinky_KV58" program would start running (as it should).
I have found this text - https://mcuoneclipse.com/2016/08/01/bricking_and_recovering_opensda_boards_in_windows_8_and_10/ - about an issue that I thought might be related. I followed the instructions to enable the "Do not allow locations on removable drives to be added to libraries" setting in Windows 10 but the problem remains.
My guess is that the USB enumeration process in Windows 10 causes the K20 OpenSDA application on the TWR-KV58F220M board to program the KV58F220M with junk.
I have a FRDM-K64F board which does not show this problem when connected to the Windows 10 PC.
I would appreciate some help answering the following questions:
- Is my problem caused by my specific configuration (my board + my PC), or is there a general problem with TWR-KV58F220M boards and Windows 10?
- Is there a solution or workaround for this problem?
From "mbed.htm" on the TWR-KV58F220M board file system:
Version: 0203 Build: Jul 30 2015 13:45:39 Git Commit SHA: c541bf8976c443d8d8b2fd1262f4f343672d14da Git local mods:Yes