GRILLIX: A 3 D turbulence code for magnetic fusion devices based on a field line map. .. In this work the newly developed code GRILLIX is presented, which is aimed to set a first milestone in the development of a 3D turbulence code for the edge/SOL. GRILLIX uses a simplified physical model (Hasegawa-Wakatani), but is capable to treat the complex geometry across the separatrix. The usually employed field aligned coordinate systems are avoided by using a cylindrical grid (R;Z;’) which is Cartesian within poloidal planes. The discretisation of perpendicular (w.r.t. the magnetic eld) operators is straight forward and parallel operators are discretised with a field line map procedure, i.e. field line tracing from plane to plane and interpolation. Via a grid-sparsification in the toroidal direction the flute mode character of the solutions can be exploited computationally. Ultimately, tokamak geometries with an arbitrary poloidal cross section, including a separatrix, can be treated with GRILLIX. ..