A barrier system for controlling the passage of vehicles, comprising at least one module, which in turn comprises: - at least one tubular body; - tubular ribs having a trapezoidal configuration with an upper side parallel to a lower side and two leg sides, wherein the lower side comprises grooves and the two leg sides comprise protrusions; wherein the tubular body is placed in the interior of the tubular ribs; - at least one longitudinal shaft, rotatable between a first stable initial position and a second stable final position, wherein the longitudinal shaft comprises spikes arranged along the longitudinal shaft; - a drive mechanism (9,11) of the rotation of the longitudinal shaft, to place the longitudinal shaft in a position selected between the first stable initial position and second stable final position, wherein in the first stable initial position of the longitudinal shaft, the spikes are concealed in the module and in the second stable final position, the spikes protrude out of the module; and, - a rotary actuator that drives the drive mechanism (9,11) of the rotation of the longitudinal shaft; wherein the barrier system further comprises: - hinges; - a plurality of independent modules attached at the ends thereof by means of the hinges for folding/unfolding the modules, which are configured so that, in the folded position, the modules form a vertical alignment, alternating a module in non-inverted horizontal position over a module in inverted horizontal position and so on; wherein the hinges are hingedly fixed to a support removably fixed at the ends of the modules; characterized in that the hinges comprise two parallel bodies, attached to each other in a sliding manner by means of two screws, housed in a slot, of each one of the bodies, through which the screws can run, allowing relative sliding between both bodies in both rotational and linear directions, wherein each one of the parallel bodies further has a rotation shaft, by means of which the parallel bodies are retained in the supports on which the parallel bodies are articulated, wherein the hinges allow relative sliding between adjacent modules in both the rotational direction, in both directions of torsion between modules, and in the linear direction. - at least one tubular body; - tubular ribs having a trapezoidal configuration with an upper side parallel to a lower side and two leg sides, wherein the lower side comprises grooves and the two leg sides comprise protrusions; wherein the tubular body is placed in the interior of the tubular ribs; - at least one longitudinal shaft, rotatable between a first stable initial position and a second stable final position, wherein the longitudinal shaft comprises spikes arranged along the longitudinal shaft; - a drive mechanism (9,11) of the rotation of the longitudinal shaft, to place the longitudinal shaft in a position selected between the first stable initial position and second stable final position, wherein in the first stable initial position of the longitudinal shaft, the spikes are concealed in the module and in the second stable final position, the spikes protrude out of the module; and, - a rotary actuator that drives the drive mechanism (9,11) of the rotation of the longitudinal shaft; - hinges; - a plurality of independent modules attached at the ends thereof by means of the hinges for folding/unfolding the modules, which are configured so that, in the folded position, the modules form a vertical alignment, alternating a module in non-inverted horizontal position over a module in inverted horizontal position and so on;