You can find some examples of using ADC bean in help of ADC bean in bean´s pop-up menu on page "Typical usage". More detailed information about bean´s setting, methods and events are available in hints and the help on pages
properties, methods and events. To toggle with a logic value of a pin you can for example use "NegVal" method from BitIO bean.
Example:
AD1_GetValue(&Value);
if (Value > 0x00ef){
Bit1_NegVal();
}
Best Regards,
Vojtech Filip
Processor Expert Team