Pots to midi with hairless

My question is: which is this right MIDI code to control knobs and other software elements?

Have you done a Google search to find the format and content of MIDI messages ? There are thousands of sites with with the details. Searching for midi message format example returns 192,000 matches for example

How can I send this message as MIDI message to serial monitor?

Did you look at the link I posted in my previous reply ? The page has examples of how to do it.