<commit_before>#include "Hardware.h"
#include <stdbool.h>

static const IOPort* port;

void setup() {
	const OscillatorModule* osc = Hardware.OscillatorModule;
	osc->InternalOscillator->setFrequency(8000000);
	osc->PhaseLockedLoop->enablePLL();
	osc->selectSystemClockSource(
			OscillatorModule_ClockSource.INTERNAL);
	port = Hardware.PortA;
	port->setDigitalOutput(0b11111111);
}

void loop() {
	port->writeDigital(0xFF);
}
<commit_msg>add ADConverter module example and modify existing modules calling<commit_after>#include "Hardware.h"
#include <stdbool.h>

static const IOPort* port;
static const ADConverterModule* adc;

int adcResult;

static void onConverted() {
	adcResult = adc->getResult();
}

InterruptListener adcListener = {
	onConverted,
};

void setup() {
	const OscillatorModule* osc = Hardware.OscillatorModule;
	osc->InternalOscillator->selectFrequency(
			InternalOscillator_Frequency.HF_8MHz);
	osc->PhaseLockedLoop->enablePLL();
	osc->selectSystemClockSource(
			OscillatorModule_ClockSource.INTERNAL);
	port = Hardware.PortA;
	port->setPinModes(0b11111111, IOPort_PinMode.DIGITAL_OUTPUT);
	adc = Hardware.ADConverterModule;
	adc->enable();
	adc->selectInputChannel(ADConverterModule_InputChannel.AN0);
	const InterruptService* adcIntService = Hardware.ADConverterModuleInterruptService;
	adcIntService->registerListener(&adcListener, InterruptService_Priority.HIGH_PRIORITY);
	adcIntService->enableInterrupt();
}

void loop() {
	port->writeDigital(0xFF);
	adc->startConversion();
}

{'fraction_non_alphanumeric': 0.11495016611295682, 'fraction_numerical': 0.019269102990033222, 'mean_word_length': 7.274725274725275, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1421338', 'n_tokens_mistral': 546, 'n_tokens_neox': 499, 'n_words': 84}