Script to Perform Action

I need script to perform action after getting Value.

Example.

If received-bit-per-second=1.0Mbps of ether1, Than It will send message using GSM Modem/ Email to perticular email address.

I mean if value match the action/ command execute.