This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Show posts Menuvoid byte_out(char buffer)
{
char loop;
for(loop=0;loop<8;loop++){
if((buffer&0x80)==0x80)
{
LPC_GPIO1->FIOCLR = DATA;
}
else {
LPC_GPIO1->FIOSET = DATA;
}
buffer <<=1;
LPC_GPIO1->FIOSET = CLOCK;
LPC_GPIO1->FIOCLR = CLOCK;
}
}
void scandisplay2(void)
{
int k,j,i,l;
for (k=0; k<4; k++)
{
LPC_GPIO1->FIOSET = OE;
select_138(k);
for (j=0; j<8; j++)
{
for (i=0; i<4; i++)
{
byte_out( led_buffer[(3 - i) * 4 + k][7 - j]);
}
}
LPC_GPIO1->FIOSET = LATCH;
LPC_GPIO1->FIOCLR = LATCH;
LPC_GPIO1->FIOCLR = OE;
}
}