I've learned that, when debugging a code that utilizes USART, we can't do it over the ST-LINKV2 on the Disco board.
I found that to achieve this we have to use a usb-to-serial converter. I have the PL2303HXA and i'm using it on my disco with the STM32F407VGT6 MCU. I've tried something but i can't debug. I've also considered the cross connection: tx(converter) - rx(mcu), rx(converter) - tx(mcu), and connected the common grounds and tried both 5V and 3.3V VCC, but still no result.
These are the connections i made:
Note: Here i have the LED1 blinking red (toggling), and when i try to debug like this it says: No ST-LINK detected and this one:
The other thing i did is this:
Here i connected the Mini USB to another usb port on my pc, and the PL2303HXA in another as can be seen.
Here i only get the error: Error: Flash Download failed - "Cortex-M4"
Flashing and debugging works fine and i connect the TX and RX cables and GND and thereby connect my board with the usb-to-serial adapter but i don't see any text displayed in TeraTerm.
So the board is ok. But why you don't see output on the PC is difficult to comment. Possible reasons range from "your STM32 program does not output any data on the USART2" to " the wrong COM port is selected in Tera Term". So far, this is only something you can check yourself.