Background: Despite the progress of cardiac arrhythmia research and the advance of the pacemaker technology, much remains unknown about how the external pacing interacts with the heart's intrinsic activity. Methods: We present an open source computer model that is capable to simulate intrinsic heart rhythm under both normal and pathological conditions, and its interactions with extrinsic dual-chamber cardiac pacing. Detailed model structure and the software implementation are described. Results: We demonstrate the usage of the computer model for generating realistic cardiac activation sequences under different rhythm conditions. Representative examples are also provided to illustrate the application of the model to evaluate the performance of pacing algorithms. Conclusions: The present computer model provides a unified platform wherein it is possible to bench test advanced pacemaker algorithms in the presence of different heart rhythms. The availability of this open source model promises to support and stimulate future research in cardiac electrophysiology and development in pacemaker technology.