Smart sensing target flow controller: realizing automated flow control