Sliding Block Puzzle Solver

Left = Start | Middle = Solution | Right = Goal (white is any non-empty block)

Black = empty board space · Silver = outside the board · One connected piece per color.
One move may turn corners and continues until another piece moves.