BASIC4MCU | 질문게시판 | codevision atmega128 undefined 오류
페이지 정보
작성자 안탕준 작성일2022-12-01 15:59 조회515회 댓글1건본문
#include<mega128.h>
#include<delay.h>
#include <alcd.h>
#asm
.equ __lcd_port=0x1B ;포트A
#endasm
#include <lcd.h>
#define SET() #asm("sei")
#define CLI() #asm("cli")
void LCD_Decimal(short Data)
{
unsigned char Decimal[3];
Decimal[2]='0'+Data /100;
Data = Data%100;
Decimal[1] = '0'+Data / 10;
Data = Data%10;
Decimal[0] ='0'+Data/1;
LCD_pos(10,1);
LCD_data(Decimal[2]);
LCD_pos(11,1);
LCD_data(Decimal[1]);
LCD_pos(12,1);
LCD_data(Decimal[0]);
}
void port_init(void)
{
DDRD = 0x07;
DDRG = 0x10;
}
void timer0_init(void){
TCCR0 = 0x06;
TCNT0 = 0x80;
TIMSK = 0x01;
ASSR = 0x08;
}
interrupt [TIM0_OVF] void timer0_ovf_isr(void){
int count;
count ++;
TCNT0 = 0x80;
}
다음 과 같은 코드이며 Error: C:\Users\electronic\Desktop\까마귀\sengju.c(24): undefined symbol 'LCD_pos' 다음 과 같은 오류가 계속 뜨는데 해결을 못하겠습니다 ..
댓글 1
조회수 515master님의 댓글
master 작성일
#include "lcd.h"
헤더파일과 LCD .c 파일 첨부하셔야 합니다.