Live picture from the ESP32S3-CAM with the same steps as closest_pillar_test: colors, blobs, the split of touching pillars and the closest-pillar decision. The page re-runs the Arduino algorithm on every picture and checks it gives the same answer as the camera.
Pillars are only searched in the band between the yellow line (ignore top) and the red NEAR line (counted in rows up from the bottom edge); drag either line on the picture. Side zone: a pillar whose centre is within ± this many pixels of the middle is CENTER. A red pillar is on the correct side once it is left of the zone, a green one once it is right of it: green halo = correct side, red halo = not yet.
—
160×120 RGB565 from the camera, read with readPixel() (mirror / flip applied).
Every pixel to HSV and classify(): red, green or nothing.
BFS joins touching pixels of one color. Under MIN_PIXELS is noise (grey dashes).
frontPillarOfBlob() keeps the front part, isCloser() picks the lowest bottom.
Every parameter of the Arduino code. They start with the robot's values; move them to try new values live (changed ones turn orange). The page remembers them in this browser. The robot keeps its own values until you press Copy as Arduino code and paste the lines into the sketch.