The machine is suitable for the packing of square or round tablets of medicine or candy. It can implement automatic packing of single or multiple tablets or candy in pillow-shaped packs. It features longitudinal intelligent positioning system for light marks on pre-printed packaging materials. It features automatic filling, sealing, cutting, and counting (optional preset number) of the packs