  Let A be an abelian category of finite type and homological dimension 1. Then
by results of Green R(A), the extended Hall-Ringel algebra of A, has a natural
Hopf algebra structure. We consider its Heisenberg double Heis(A) and study its
relation with D(A), the derived category of A. We show that Heis(A) can be
viewed as a "Hall algebra" of D^{0,1}(A), the subcategory of complexes situated
in degrees 0 and 1, in the following sense: if B is the heart of a t-structure
on D(A) lying in D^{0,1}(A), then R(B) is naturally a subalgebra in Heis(A).
Further, we define a new algebra L(A) called the lattice algebra of A, obtained
by taking infinitely many copies of R(A), one for each site of an infinite
1-dimensional lattice and imposing Heisenberg double-type relations between
copies at adjacent sites and oscillator-type relations between copies at
non-adjacent sites. This algebra serves as the "Hall algebra" of the full
derived category D(A) in the following sense: any derived equivalence
D(A)-->D(B) induces an isomorphism of lattice algebras L(A)-->L(B).
