57c4630568e13f94249d0c4250cc383710f0ecd5
[uccvend-snackrom.git] / ROM2 / chime.c
1 #include "vend.h"
2 #include "chime.h"
3
4 u8 chime_count;
5
6 void chime() {
7         /* called from the RTI interrupt, sees if we need to turn the chime on or
8          * off (chime would be on for N RTI cycles
9          */
10         if (chime_count) {
11                 bset((void*)&_io_ports[M6811_PORTA], PORTA_CHIME);
12                 --chime_count;
13         } else
14                 bclr((void*)&_io_ports[M6811_PORTA], PORTA_CHIME);
15 }
16

UCC git Repository :: git.ucc.asn.au