binzer
Member
MCC-18
First attempt. Just a simple setup the devices code.
I am getting a couple of errors when compiling.
The biggie is:
MPLINK 4.22, Linker
Copyright (c) 2008 Microchip Technology Inc.
Error - could not find file 'c018i.o'.
Errors : 1
I can find the file, I added it in the Project window dropdown, still no joy.
The other is the adc setup, probably just missed something (commented out), will go back and do some more reading.
First attempt. Just a simple setup the devices code.
I am getting a couple of errors when compiling.
The biggie is:
MPLINK 4.22, Linker
Copyright (c) 2008 Microchip Technology Inc.
Error - could not find file 'c018i.o'.
Errors : 1
I can find the file, I added it in the Project window dropdown, still no joy.
The other is the adc setup, probably just missed something (commented out), will go back and do some more reading.
Code:
#include "stdlib.h"
#include "p18f1320.h"
#include "usart.h"
#include "adc.h"
#include "portb.h"
unsigned char config;
unsigned int spbrg;
void main(void)
{
// setup usart
OpenUSART(USART_ASYNCH_MODE &
USART_TX_INT_OFF &
USART_RX_INT_OFF &
USART_EIGHT_BIT &
USART_CONT_RX &
USART_BRGH_HIGH,
25 );
// setup adc /
// OpenADC(ADC_FOSC_32 & ADC_RIGHT_JUST & ADC_4_TAD & ADC_VREFPLUS_VDD & ADC_VREFMINUS_VSS & ADC_CH0 & ADC_INT_OFF);
// setup port inputs /
OpenPORTB( PORTB_CHANGE_INT_OFF & PORTB_PULLUPS_ON);
}