Dot pattern recognition