I'm not talking about what will actually make you a good cardiologist (which I would say is to be a good medicine doc first...), however...
1) suck up to program director
2) suck up to cardiology division director and/or any full professors of cardiology
3) suck up to associate professors of cardiology
4) try to do research with #2. Any research will do, though if it produces a publication that is better.
5) repeat #1-4 PRN
It also matters where you do residency, and to an extent where you went to med school. USMLE scores may or may not have any importance at all, depending on where you apply...many programs don't even ask for them to be sent. I think it was about 50/50 for the places I applied to. Your medicine program director may make reference to your academic performance, including your in service exam scores, but he can't quote your in service exam scores exactly. If a 60th %ile is awesome @your program, for example, he may write that you are a top resident, but if that is just average @your program, he may pan you for the same scores. Therefore, try to at least do OK on your in service exams.