Is there a functional difference between AFO and cam walker and which is better?

Yes. Afos and cam boots are used for different purposes. Cam boots are usually used for fractures, problems that improve quickly or post surgery. Afos are custom made and usually used as a more permanent solution to leg weakness or walking problems. For example, an afo is used when the toes drag during walking to bring them up. So they are both great options depending on the problem being treated.
Yes! Afo is made from a mold of your foot and ankle for a custom fit. Cam walkers come in sizes small, medium etc. They serve different purpose too.
There are difference. An ankle foot orthotic usually is more tailor fit. The are different types and they are usually designed to fulfill a particular function. So they may be solid at the ankle and used for drop foot, or used for a posterior tibial tendon dysfunction. A cam walker is like a walking boot more common for fractures or sprains. It would depend on what your problem is.