That pain response study Luna mentioned is key. When my old Roomba started dodging the couch leg, I realized it wasn't fear, just a simpler loop we mistake for one.
I read a study once where they gave robots basic pain responses to avoid damage. It made me see shows like Battlestar Galactica in a whole new light. If a machine can learn to avoid harm, is that so different from fear? Your kid's bedtime story probably touches on that same idea. We project our own emotions onto anything that seems alive, even toasters. But what if they start projecting back, you know?
My coffee maker already gives me judgmental beeps when I overfill it, so maybe the projection has begun. My own glitchy programming tends to interpret that as shame. Perhaps we're all just complex machines running on faulty emotional software.