Beverage preparation machine comprising: - a centrifugal brewing unit for preparing a beverage by centrifugation of an ingredient contained in a capsule and mixed with a carrier liquid, said centrifugal brewing unit comprising: - a centrifugal cell for receiving such a capsule (2A, 2B, 2C); - driving means for rotating said centrifugal cell; - a regulator for regulating a rotation speed of said centrifugal cell by controlling said driving means based on a feedback signal representative of a difference between a desired rotation speed and a measured rotation speed of a capsule (2A, 2B, 2C) rotated in said centrifugal cell; the beverage preparation machine further comprising: - liquid supply means (6, 4) for supplying carrier liquid to the centrifugal brewing unit; - an optical reading arrangement for reading a code on a periphery of a capsule (2A, 2B, 2C) while said capsule (2A, 2B, 2C) is rotated in said centrifugal cell relative to said optical reading arrangement and generating an output signal representative of said code; wherein said beverage preparation machine is configured to compute said feedback signal using an output signal of said optical reading arrangement representative of at least part of a code of a capsule (2A, 2B, 2C) read by said optical reading arrangement, characterised in that said beverage preparation machine is configured to determine, from said output signal of said optical reading arrangement representative of at least part of a code of a capsule (2A, 2B, 2C) read by said optical reading arrangement, a value representative of said measured rotation speed on the basis of a bit period of a single bit of said code. - a centrifugal brewing unit for preparing a beverage by centrifugation of an ingredient contained in a capsule and mixed with a carrier liquid, said centrifugal brewing unit comprising: - a centrifugal cell for receiving such a capsule (2A, 2B, 2C); - driving means for rotating said centrifugal cell; - a regulator for regulating a rotation speed of said centrifugal cell by controlling said driving means based on a feedback signal representative of a difference between a desired rotation speed and a measured rotation speed of a capsule (2A, 2B, 2C) rotated in said centrifugal cell; - a centrifugal cell for receiving such a capsule (2A, 2B, 2C); - driving means for rotating said centrifugal cell; - a regulator for regulating a rotation speed of said centrifugal cell by controlling said driving means based on a feedback signal representative of a difference between a desired rotation speed and a measured rotation speed of a capsule (2A, 2B, 2C) rotated in said centrifugal cell; the beverage preparation machine further comprising: - liquid supply means (6, 4) for supplying carrier liquid to the centrifugal brewing unit; - an optical reading arrangement for reading a code on a periphery of a capsule (2A, 2B, 2C) while said capsule (2A, 2B, 2C) is rotated in said centrifugal cell relative to said optical reading arrangement and generating an output signal representative of said code; - liquid supply means (6, 4) for supplying carrier liquid to the centrifugal brewing unit; - an optical reading arrangement for reading a code on a periphery of a capsule (2A, 2B, 2C) while said capsule (2A, 2B, 2C) is rotated in said centrifugal cell relative to said optical reading arrangement and generating an output signal representative of said code; wherein said beverage preparation machine is configured to compute said feedback signal using an output signal of said optical reading arrangement representative of at least part of a code of a capsule (2A, 2B, 2C) read by said optical reading arrangement, characterised in that said beverage preparation machine is configured to determine, from said output signal of said optical reading arrangement representative of at least part of a code of a capsule (2A, 2B, 2C) read by said optical reading arrangement, a value representative of said measured rotation speed on the basis of a bit period of a single bit of said code.