The threshold value could be simple use of A/D to measure a pot of some
kind, a simple knob based setting control.
Why edge connector, you have a lot of I/O pins in design ? What is the connector connecting ?
As far as processor choice, consider a ESP32, Like ESP32C3 Supermini board. Reason is...