Here is the code, Printf active, UART commented out (I found the UART code on the internet):
//PIC 12F675
#include <htc.h>
#include <stdio.h>
//#include "sw_uart.h"
/*getcUART
getsUART
OpenUART
putcUART
putsUART
ReadUART
WriteUART
*/
unsigned char A=1;
void main(void){
//unsigned char input;
//OpenUART();
//INTCON=0; // disabling interrupts.
//init_comms(); // set up the USART - settings defined in usart.h
// Output a message to prompt the user for a keypress
//printf("\rPress a key and I will echo it back:\n");
//while(1){
//input = getch(); // read a response from the user
//printf("\rI detected [%c]",input); // echo it back
//}
printf ("A= %c",A); //%hd?, %ld?
}
// :: error: can't open input file "c:\...\C-Compiler\HI-TechC\lib\doprnt.c": No such file or directory
I'm using Hi-Tech v9.82.