The invention is related to an implantable leadless pacemaker (iLP) for a human or animal heart, wherein the iLP comprises a housing, at least two electrode poles for picking up electrical potentials and/or delivering electrical stimulation, a stimulation control unit in connection with the electrode poles, a sensing unit, wherein the sensing unit is in connection with at least one electrode pole a signal processing unit in connection with the sensing unit a signal evaluation unit in connection with the signal processing unit and/or the sensing unit an energy source, wherein the iLP is configured to be anchored within a first heart chamber, and the sensing unit is configured to sense electrical potentials via the at least two electrode poles, wherein the sensing unit is further configured to sense a first signal associated with an activity of the first heart chamber, and the stimulation control unit is configured to deliver electrical stimulation in the first heart chamber via the at least two electrode poles, wherein the sensing unit is configured to sense a second signal associated with an activity of a second heart chamber, wherein the second heart chamber is different from the first heart chamber.