| ??? 10/18/05 23:23 Read: times |
#102594 - Int 0 |
i've been using the int0 for adding a value to a var, i'm using a switch for call the int0.
if i've press the switch seems like the interrupt is executing too many times. i have this code:
unsigned char creditos_por_pulsos[]={1, 2, 5, 10, 20, 25, 50, 100};
void capturar_entradas() interrupt 0{
unsigned char vartmp;
while(IT0==1);
EA=0;
vartmp=P3>>5;
valor_credito=creditos_por_pulsos[vartmp];
creditos=creditos+valor_credito;
total_entradas=total_entradas+valor_credito;
EA=1;
}
thanks, Ruben Porras |
| Topic | Author | Date |
| Int 0 | 01/01/70 00:00 | |
| int 0 | 01/01/70 00:00 | |
| thanks | 01/01/70 00:00 | |
| points | 01/01/70 00:00 | |
| Hope this would help u......... | 01/01/70 00:00 | |
| Key debounce | 01/01/70 00:00 | |
| I do not see "micro" asking for help, yo | 01/01/70 00:00 | |
| .u didnt...U have...If ur...suits | 01/01/70 00:00 | |
sorry for the inconvenience caused by me | 01/01/70 00:00 | |
| the mistake is using int 0 | 01/01/70 00:00 |



