I sucessfully download the Custom_HID demo code on STM32L152-EVAL. It works. However, after I disconnect the USB cable from CN1, I use IAR and ST-link to program again, the error "Fatal error: Failed to read CPUID for Cortex device Session aborted! " occurs. I reconnect the USB cable and re-program, it works again. Strange.