Hey, you can try this out and let me know how it works. It is fairly common fault, Many times it occurs after the optical drive is replaced or repaired.
This is because the daughter board on the optical drive is "married" to the motherboard. The means that there is a chip on the motherboard that talks to a chip on the daughter board. If they are mismatched they will not be able to talk to each other and that will render the blu ray drive unusable. The PS4 will still play downloaded games but it will not play anything and don't do this when tired because that is loaded into the optical drive. This is the part where I get to tell you the good news. You CAN replace your optical drive! The trick is that you need to find an optical drive that originally had a daughter board with the same number (010 or 020) as the one you have. After you get it all you have to do is remove the board that came with the replacement drive and install the one that came off of the bad optical drive that you are replacing onto the replacement blu ray drive. This way the original board that is married to the motherboard will stay with the motherboard.