“He’d say, ‘I have a Sharpton radio ad — I need 60 seconds of smooth jazz,’ ” Lin-Manuel Miranda recalled the other day.

For the elder Mr. Miranda, hiring his son provided a dual benefit: His son charged less than other composers, and needed work.

Luis Miranda said he had encouraged his son — fruitlessly — to go to law school, noting that the salsa singer Rubén Blades had a law degree. But when it became clear that the younger Mr. Miranda was determined to focus on “In the Heights,” his father wanted to be able to help him.

“The work with me allowed him to sort of dedicate his life to art,” Luis Miranda said.

The younger Mr. Miranda said he did not consider his political jingles his most inspired work. He agreed with his father that music played a more important role in Spanish-language political campaigns than in English ones. But he said the parameters of the job were fairly limited.

The music is “generally accompanied by footage of the candidates shaking hands, doing very task-oriented things, so it’s got to have a pulse, and it’s got to be generally hopeful,” Mr. Miranda said.