As somebody who has broken ribs too often to think about, can I recommend very very shallow breathing, using your diaphragm if possible (so the opposite of yoga breathing). You want to imagine you are breathing from your tummy, so that your tummy pushes in and out, and confine the air there, and critically do not let air up into the ribcage- ribcage needs to stay static and not expand. If you can do this, it will heal quicker and better than anything else possibly can do to help. This unfortunately means no exercise/ getting out of breath for a few days too.