Software control system. Which one is it?
This is still a PI controller. You've simply truncated the error signal to 1-bit of accuracy.

Here is the inner loop rearranged to make it obvious:

...
int error = (valuefrom_ADC &lt; 1234) ? 1 : -1;
dutycycle += error;
TIM1-&gt;CCR1 = dutycycle;
...


EDIT: I usually call these "Error Integrators" when they have no proportional term.