We present the mixed Galerkin discretization of distributed parameter port-Hamiltonian systems. On the prototypical example of hyperbolic systems of two conservation laws in arbitrary spatial dimension, we derive the main contributions: (i) A weak formulation of the underlying geometric (Stokes-Dirac) structure with a segmented boundary according to the causality of the boundary ports. (ii) The geometric approximation of the Stokes-Dirac structure by a finite-dimensional Dirac structure is realized using a mixed Galerkin approach and power-preserving linear maps, which define minimal discrete power variables. (iii) With a consistent approximation of the Hamiltonian, we obtain finite-dimensional port-Hamiltonian state space models. By the degrees of freedom in the powerpreserving maps, the resulting family of structure-preserving schemes allows for trade-offs between centered approximations and upwinding. We illustrate the method on the example of Whitney finite elements on a 2D simplicial triangulation and compare the eigenvalue approximation in 1D with a related approach.Keywords: Systems of conservation laws with boundary energy flows, port-Hamiltonian systems, mixed Galerkin methods, geometric spatial discretization, structure-preserving discretization. * Accepted version of P. Kotyczka et al., Weak form of Stokes-Dirac structures and geometric discretization of port-Hamiltonian systems, J. Comput. Phys. 361 (2018) 442-476, https://doi.• The power-preserving maps for the discrete power variables offer design degrees of freedom to parametrize the resulting finite-dimensional PH state space models. They can be used to realize upwinding.• Mapping the flow variables instead of the efforts avoids a structural artificial feedthrough, which is not desirable for the approximation of hyperbolic systems.We consider as the prototypical example of distributed parameter PH systems, an open system of two hyperbolic conservation laws in canonical form, as presented in [1]. We use the language of differential forms, see e. g. [23], which highlights the geometric nature of each variable and allows for a unifying representation independent from the dimension of the spatial domain.An important reason for expressing the spatial discretization of PH systems based on the weak form is to make the link with modern geometric discretization methods. Bossavit's work in computational electromagnetism [24], [25] and Tonti's cell method [26] keep track of the geometric nature of the system variables which allows for a direct interpretation of the discrete variables in terms of integral system quantities. This integral point of view is also adopted in discrete exterior calculus [11]. Finite element exterior calculus [27] gives a theoretical frame to describe functional spaces of differential forms and their compatible approximations, which includes the construction of higher order approximation bases that generalize the famous Whitney forms [28], see also [29]. We refer also to the recent article [30] which proposes conforming polynomial ap...