Mbed OS on ST-Nucleo-L476RG, problem with serial port

can I use mbed classic serial attach fun in mbedos? like this