PIC P16F690;

# enable gpsim as a simulator
pragma simulator gpsim;

Main {
    digital_output RC0; # mark pin RC0 as output
    write RC0, 0x1; # write the value 1 to RC0
    sim_assert RC0 == 0x1, "Pin RC0 should be 1";
}

Simulator {
    attach_led RC0;
    stop_after 1s;
    logfile "helloworld.lxt";
    log RC0;
    scope RC0;
}