Added a flexible number of channels