I have a motor with encoder. 3 of the 5 cable to receive our engine (blue-orange-yellow) of the DC motor encoder cable for the other two power inputs. 5 V encoder supply Orange, Blue graund, Yellow Encoder signal output. I do not know how to do this I want to read the speed of the motor. I found an example similar to this but this is the one for 2 channel. Absolute encoder on how to speed read? Thank you in advance for your help.

You will need to find the interface specification for your particular 'absolute encoder'. Do you have the manufacturer and model number of the motor or encoder? Do you have an oscilloscope you can use to look at the encoder signal? Without more data it's impossible to guess what might be coming out that wire.

The catalog says that the 'BE' means an optical rotation sensor. The catalog says that the optical sensor gives 24 pulses per revolution. It is not an absolute encoder. It is not even a quadrature encoder. It will tell you how fast the motor is turning but not which direction. To measure speed, look for the time between pulses or the pulses over a time interval.

Blue is GroundOrange is +5V PowerYellow is pulse output

Here's some example code that might help in calculating RPM from the pulses: