LM311 Current Sensing Switch
You need two op-amps.  One to give you the difference between the two volatges, and one to compare that voltage difference to a reference voltage.

Either that or read the voltage difference op-amp output with an ADC input on the microcontroller.

Also, you should investigate "High Side Current Sense Amplifiers" - they are chips specially designed for this purpose. They both calculate the voltage difference between two points and amplify it, and most often run off a lower voltage (3.3V or 5V) than the voltage level they are sensing at (say up to 60V).  I have used the AD8215 before now.