Compact capacitive sensors for machine automation