to mess up, to slip up
Desculpe amigão... eu dei mancada interpretando mal a situação.
Sorry man... I messed up by misreading the situation.
The expression dar mancada comes from mancar, "to limp", which traces back to Latin mancare, from mancus ("maimed, lame"). A mancada is literally a misstep, and many languages tie a stumble of the feet to the idea of erring or failing.
Source: Diário de um Linguista.
Falando's Idiom Trainer teaches you to recognize idiom meanings and create sentences using them, so you can speak like a Brazilian.