getModuleAt(6, $col)->isDark(); $expected = ($col % 2 === 0); // Even columns should be dark if ($isDark !== $expected) { echo "❌"; } else { echo ($isDark ? "█" : "·"); } } echo "\n\n"; echo "Vertical Timing Pattern (column 6, rows 8-12):\n"; echo "Expected: █·█·█ (alternating dark-light-dark-light-dark)\n"; echo "Actual: "; for ($row = 8; $row <= 12; $row++) { $isDark = $matrix->getModuleAt($row, 6)->isDark(); $expected = ($row % 2 === 0); // Even rows should be dark if ($isDark !== $expected) { echo "❌"; } else { echo ($isDark ? "█" : "·"); } } echo "\n\n"; // Full check $hErrors = 0; for ($col = 8; $col <= 12; $col++) { $isDark = $matrix->getModuleAt(6, $col)->isDark(); $expected = ($col % 2 === 0); if ($isDark !== $expected) $hErrors++; } $vErrors = 0; for ($row = 8; $row <= 12; $row++) { $isDark = $matrix->getModuleAt($row, 6)->isDark(); $expected = ($row % 2 === 0); if ($isDark !== $expected) $vErrors++; } if ($hErrors === 0 && $vErrors === 0) { echo "✅ TIMING PATTERNS ARE CORRECT!\n"; } else { echo "❌ TIMING PATTERNS HAVE ERRORS!\n"; echo " Horizontal errors: {$hErrors}\n"; echo " Vertical errors: {$vErrors}\n"; }