; Prog 2 ; Ticker synchrone ; Org &8000 limit &80ff Nolist ld hl,bloc+6 ; attention !!! ld b,%00001001 ld c,0 ld de,routine call &bcef ; KL INIT EVENT ld hl,bloc ld de,1 ld bc,4 call &bce9 ; KL ADD TICKER ld b,0 Boucle push bc halt ; Faites ici ce que halt ; vous voulez... call &bcfb ; KL Next Synchronous jr nc,pasevent ld bc,&7f00 out (c),c ld c,64+18 out (c),c ld b,32 djnz $ ld bc,&7f44 out (c),c push hl ; sauve l'adresse du bloc d'{v{nement ; de l'{v{nement @ traiter call &bcfe ; KL DO Synchronous pop hl xor a call &bd01 ; KL Done Synchronous PasEvent pop bc djnz boucle halt ld hl,bloc call &bcec ; KL DEL TICKER ret ; Routine push af push hl push bc ld bc,&7f10 out (c),c ld c,64+11 out (c),c ld h,&c0 ld a,(bloc+8) ; prend la valeur du compteur 8 bits ld l,a ld a,r ld (hl),a ld b,20 Bouc ds 60 djnz bouc ld bc,&7f44 out (c),c pop bc pop hl pop af ret ; Bloc de controle suivi du bloc d'{v{nement Bloc ds 6+7