An extraction unit (10) for extracting cartridges (1a; 1b) of two different heights (ha;hb) comprises a seat (11, 12, 13; 15) for receiving any of such cartridges (1a; 1b) for extraction thereof in the seat. The seat is delimited by a first part (11,12,13) and second part (15) that are relatively movable between a
cartridge extraction position and a
cartridge loading and / or ejection position. The first part (11,12,13) has a first portion (11,12) and a second portion (13) that are relatively movable to delimit a cavity (12′) having selectively: —a first depth (da) for receiving a
cartridge (1a) of the first height (ha); and—a second depth (db) for receiving a cartridge (1b) of the second height (hb), the first part (11,12,13) has a lock (112′, 132, 132′, 142′) for locking the first and second portions (11,12,13) when the delimited cavity (12′) has the first depth (da) or the second depth (db). Such extraction unit (10) further comprises a
mechanical sensor (14) that senses the height (ha;hb) of a cartridge (1a; 1b) and that controls the lock (112′, 132, 132′, 142′) to lock or unlock the first and second portions (11,12,13) when the sensor is actuated by a cartridge of first height (ha) or of second height (hb).