Hi, thanks for writing to HCM.
Your description suggests that you could have sustained a soft tissue contusion
(propably intercostal myalgia) or a minor rib injury
which typically produces pain on movement of the rib cage.
* avoid lying on the injured side
* Use some analgesic
* Apply pain kiler gels locally
* Ice compressions
If it is not resolving over time, consult your physician.
Hope this helps