Re: [问题] 8051的问题

楼主: IhateOGC (我讨厌)   2014-07-22 21:10:53
※ 引述《gauss5566 (下面给妳吃)》之铭言:
: unsigned char code tab1[360]={
: 128, 131, 134, 137, 140, 143, 146, 149, 152, 156,
: 159, 162, 165, 168, 171, 174, 176, 179, 182, 185,
: 188, 191, 193, 196, 199, 201, 204, 206, 209, 211,
: 213, 216, 218, 220, 222, 224, 226, 228, 230, 232,};
#typedef unsigned char UINT8
#include <stdio.h> /* printf */
#include <sys/io.h> /* outb_p */
int main(int argc , char* argv[]){
UINT8 temp;
int i;
iopl(3);
for(i = 0 ;i< (sizeof(code_table)/sizeof(unsigned char));i++)
{
temp = outb_p(code_table[i]);
printf("code_table[%d] = 0x%X\n",itemp);
}
iopl(0);
printf("IhateOGC\n");
return 0;
}
: 这是一个SIN波的AD资料
: 我要利用中断去取那个时间上的那点的"值"
: /*

Links booklink

Contact Us: admin [ a t ] ucptt.com