We define, analyse, and relate in a uniform way four different algebraic structures on the set of bitstreams, motivating each of them in terms of the digital circuits they can describe. For one of these, the 2-adic numbers, we characterise a class of linear digital circuits in terms of rational streams