#include<iom128.h>
#include<ina90.h>
#include<ina90.h>
void m_delay(unsigned int m)
{
unsigned int i,j;
{
unsigned int i,j;
__disable_interrupt();
for(i=0; i<m; i++)
for(j=0; j<2650; j++);
for(j=0; j<2650; j++);
__enable_interrupt();
}
}
void main(void)
{
unsigned int h,j,m;
h=0xFE;
j=0x7F;
{
unsigned int h,j,m;
h=0xFE;
j=0x7F;
DDRB=0xFF;
PORTB=0xFF;
PORTB=0xFF;
do{
m=h & j;
PORTB=m;
m_delay(100);
if((h==0x7F || j==0xFE))
{
h=0xFE;
j=0x7F;
}
else
{
h=((h << 1) | 0x01);
j=((j >> 1) | 0x80);
}
}while(1);
}
m=h & j;
PORTB=m;
m_delay(100);
if((h==0x7F || j==0xFE))
{
h=0xFE;
j=0x7F;
}
else
{
h=((h << 1) | 0x01);
j=((j >> 1) | 0x80);
}
}while(1);
}