home *** CD-ROM | disk | FTP | other *** search
/ Falcon 030 Power 2 / F030_POWER2.iso / ST_STE / MAGS / ICTARI08.ARJ / ictari.08 / ASSEMBLY / HELP68K / HELP68.S < prev    next >
Text File  |  1989-05-11  |  19KB  |  943 lines

  1.     Include    help68.s2
  2.  
  3. *******************************
  4. *      Table des bits         *
  5. *******************************
  6. m1    equ    %0000000000000001
  7. m2    equ    %0000000000000010
  8. m3    equ    %0000000000000100
  9. m4    equ    %0000000000001000
  10. m5    equ    %0000000000010000
  11. m6    equ    %0000000000100000
  12. m7    equ    %0000000001000000
  13. m8    equ    %0000000010000000
  14. m9    equ    %0000000100000000
  15. m10    equ    %0000001000000000
  16. m11    equ    %0000010000000000
  17. m12    equ    %0000100000000000
  18. mtout    equ    %0000111111111111
  19. msource    equ    %0000000111111111
  20. mdest    equ    %0000000111111101
  21. lb    equ    %0010000000000000
  22. lw    equ    %0100000000000000
  23. ll    equ    %1000000000000000
  24. lbwl    equ    %1110000000000000
  25.  
  26. bna    equ    %0000000000000000
  27. bxi    equ    %0000000000000001
  28. bx0    equ    %0000000000000010
  29. bx1    equ    %0000000000000011
  30. bxp    equ    %0000000000000100
  31. bni    equ    %0000000000001000
  32. bn0    equ    %0000000000010000
  33. bn1    equ    %0000000000011000
  34. bnp    equ    %0000000000100000
  35. bzi    equ    %0000000001000000
  36. bz0    equ    %0000000010000000
  37. bz1    equ    %0000000011000000
  38. bzp    equ    %0000000100000000
  39. bvi    equ    %0000001000000000
  40. bv0    equ    %0000010000000000
  41. bv1    equ    %0000011000000000
  42. bvp    equ    %0000100000000000
  43. bci    equ    %0001000000000000
  44. bc0    equ    %0010000000000000
  45. bc1    equ    %0011000000000000
  46. bcp    equ    %0100000000000000
  47. bp    equ    %0100100100100100
  48.  
  49. **********************************
  50. *         Le programme           *
  51. **********************************
  52.  
  53. debut    movea.l    #newstack,a7
  54. programm    bsr    initappl
  55.     move.w    d0,id_appl
  56.     cmp.w    #-1,d0
  57.     beq    erreur1
  58.     move.l    #nom_rsc,addrin
  59.     move.l    #$6e000101,d0
  60.     bsr    aes
  61.     tst.w    d0
  62.     beq    erreur2
  63.     move.w    id_appl,intin
  64.     move.l    #nom_acc,addrin
  65.     move.l    #$23010101,d0
  66.     bsr    aes
  67.     move.w    d0,num_acc
  68.     move.w    #-1,id_fen
  69.     clr.w    intin+2
  70.     bsr    rsc_tree
  71.     move.l    a0,ecran
  72.     move.l    20(a0),lbase
  73.     move.w    #5,xbase
  74.     move.w    #50,ybase
  75.     clr.w    intin
  76.     move.w    #%1011,intin+2
  77.     move.l    xbase,intin+4
  78.     move.l    lbase,intin+8
  79.     move.l    #$6c060500,d0
  80.     bsr    aes
  81.     move.l    intout+2,xfen
  82.     move.l    intout+6,lfen
  83.     clr.w    choix
  84.     clr.w    info
  85. boucle    bsr    evn_mult
  86.     bsr    beg_ebdt
  87.     btst    #4,event+1
  88.     beq    nomessag
  89.     bsr    message
  90. nomessag    btst    #1,event+1
  91.     beq    nobutton
  92.     bsr    button
  93. nobutton    btst    #0,event+1
  94.     beq    nokey
  95.     bsr    keyboard
  96. nokey    bsr    end_ebdt
  97.     bra    boucle
  98. erreur2    move.l    #$13000100,d0
  99.     bsr    aes
  100. erreur1    clr.w    -(a7)
  101.     trap    #1
  102.  
  103. message    lea    mes_tab(pc),a0
  104.     lea    jmp_mes(pc),a1
  105.     moveq    #(jmp_mes-mes_tab)-1,d0
  106.     move.w    tampon,d1
  107. messag1    move.l    (a1)+,a2
  108.     cmp.w    (a0)+,d1
  109.     dbeq    d0,messag1
  110.     move.w    tampon+6,d0
  111.     move.w    id_fen,d1
  112.     jmp    (a2)
  113. messag2    rts
  114.  
  115. mes_tab    dc.w    21,22,28,29,20,40,41,0
  116. jmp_mes    dc.l    topped,closed,moved,newtop,redraw
  117.     dc.l    acopen,acclose,messag2
  118.  
  119. redraw    cmp.w    d0,d1
  120.     bne    messag2
  121.     bsr    m_hide
  122.     move.l    ecran,a0
  123.     move.l    xbase,16(a0)
  124.     move.w    #11,intin+2
  125. redraw1    bsr    w_get
  126.     tst    intout+6
  127.     bne    redraw2
  128.     tst    intout+8
  129.     beq    redraw9
  130. redraw2    move.l    intout+2,d0
  131.     move.l    tampon+8,d1
  132.     bsr    minmax
  133.     swap    d0
  134.     swap    d1
  135.     bsr    minmax
  136.     swap    d1
  137.     move.l    d1,intin+4
  138.     move.l    intout+2,d0
  139.     add.l    intout+6,d0
  140.     move.l    tampon+8,d1
  141.     add.l    tampon+12,d1
  142.     bsr    minmax
  143.     swap    d0
  144.     swap    d1
  145.     bsr    minmax
  146.     sub.w    intin+4,d0
  147.     ble    redraw3
  148.     move.w    d0,intin+8
  149.     swap    d0
  150.     sub.w    intin+6,d0
  151.     ble    redraw3
  152.     move.w    d0,intin+10
  153.     clr.w    intin
  154.     bsr    obj_draw
  155. redraw3    move.w    #12,intin+2
  156.     bra    redraw1
  157. redraw9    bsr    m_last
  158.     rts
  159. minmax    cmp.w    d0,d1
  160.     bcc    minmax1
  161.     move.w    d1,d2
  162.     move.w    d0,d1
  163.     move.w    d2,d0
  164. minmax1    rts
  165. moved    cmp.w    d0,d1
  166.     bne    messag2
  167.     move.l    tampon+8,xfen
  168.     move.l    xfen,intin+4
  169.     move.l    lfen,intin+8
  170.     move.w    #5,intin+2
  171.     bsr    w_set
  172.     move.w    #4,intin+2
  173.     bsr    w_get
  174.     move.l    intout+2,xbase
  175.     move.l    ecran,a0
  176.     move.l    xbase,16(a0)
  177.     rts
  178. acopen    move.w    tampon+8,d0
  179.     cmp.w    num_acc,d0
  180.     bne    messag2
  181.     cmp.w    #-1,d1
  182.     bne    activew
  183.     bsr    opnvwk
  184.     bsr    window
  185.     rts
  186. topped:
  187. newtop    cmp.w    d0,d1
  188.     bne    messag2
  189. activew    move.w    #10,intin+2
  190.     move.w    d0,intin+4
  191.     bsr    w_set
  192.     rts
  193. acclose    cmp.w    num_acc,d0
  194.     bne    messag2
  195.     cmp.w    #-1,d1
  196.     beq    messag2
  197.     bra    closew
  198. closed    cmp.w    d0,d1
  199.     bne    messag2
  200. closew    move.w    id_fen,intin
  201.     move.l    #$66010100,d0
  202.     bsr    aes
  203.     move.l    #$67010100,d0
  204.     bsr    aes
  205.     bsr    clsvwk
  206.     move.w    #-1,id_fen
  207.     rts
  208.  
  209. window    move.w    #%1011,intin
  210.     move.l    xfen,intin+2
  211.     move.l    lfen,intin+6
  212.     move.l    #$64050100,d0
  213.     bsr    aes
  214.     move.w    d0,id_fen
  215.     move.w    d0,intin
  216.     move.w    #2,intin+2
  217.     move.l    #nom_acc,intin+4
  218.     bsr    w_set
  219.     move.l    xfen,intin+2
  220.     move.l    lfen,intin+6
  221.     move.l    #$65050100,d0
  222.     bsr    aes
  223.     rts
  224.  
  225. keyboard    move.l    ecran,a1
  226.     move.w    choix,d0
  227.     cmp.b    #$48,key
  228.     beq    flhaut
  229.     cmp.b    #$4b,key
  230.     beq    flgauche
  231.     cmp.b    #$4d,key
  232.     beq    fldroite
  233.     cmp.b    #$50,key
  234.     beq    flbas
  235.     rts
  236. flbas    addq    #4,d0
  237.     cmp.w    #instr2,d0
  238.     bls    fleche
  239.     sub.w    #instr2,d0
  240.     cmp.w    #instr1+3,d0
  241.     bne    fldroite
  242.     subq    #4,d0
  243. fldroite    addq    #1,d0
  244.     cmp.w    #instr2,d0
  245.     bls    fleche
  246.     move.w    #instr1,d0
  247.     bra    fleche
  248. flhaut    subq    #4,d0
  249.     cmp.w    #instr1,d0
  250.     bge    fleche
  251.     add.w    #instr2,d0
  252.     cmp.w    #instr2-3,d0
  253.     bne    flgauche
  254.     addq    #4,d0
  255. flgauche    subq    #1,d0
  256.     cmp.w    #instr1,d0
  257.     bge    fleche
  258.     move.w    #instr2,d0
  259. fleche    mulu    #24,d0
  260.     bra    button3
  261.  
  262. button    move.l    ecran,a1
  263.     move.w    #instr1*24,d0
  264. button1   move.l    16(a1,d0.w),d1
  265.     add.l    xbase,d1
  266.     cmp.l    xmouse,d1
  267.     bhi    button2
  268.     cmp.w    ymouse,d1
  269.     bhi    button2
  270.     add.l    20(a1,d0.w),d1
  271.     cmp.l    xmouse,d1
  272.     bcs    button2
  273.     cmp.w    ymouse,d1
  274.     bcc    button3
  275. button2    cmp.w    #instr2*24,d0
  276.     beq    button9
  277.     add.w    #24,d0
  278.     bra    button1
  279. button3    ext.l    d0
  280.     move.w    d0,d6
  281.     divu    #24,d6
  282.     cmp.w    choix,d6
  283.     beq    button99
  284.     move.w    d6,intin
  285.     bset    #0,11(a1,d0.w)
  286.     bsr    obj_redr
  287.     move.w    choix,d0
  288.     beq    button4
  289.     move.w    d0,intin
  290.     mulu    #24,d0
  291.     bclr    #0,11(a1,d0.w)
  292.     bsr    obj_redr
  293. button4    move.w    d6,choix
  294.     subq    #instr1,d6
  295.     move.w    d6,d1
  296.     mulu    #long,d1
  297.     lea    instruc(pc),a2
  298.     add.l    d1,a2
  299.     moveq    #2,d5
  300.     move.l    a1,a4
  301.     move.l    a1,a5
  302.     add.l    #mnemo*24,a4
  303.     add.l    #operande*24,a5
  304.     move.w    fmasque,d0
  305.     eor.w    #1,d0
  306.     move.w    d0,fmasq2
  307.     eor.w    d0,fmasque
  308. button5    move.w    d5,d4
  309.     mulu    #24,d4
  310.     move.l    12(a4,d4.w),a0
  311.     move.l    (a0),a0
  312.     moveq    #6,d6
  313.     clr.w    d0
  314.     lea    fmnem(pc),a3
  315.     btst    d5,fmasq2+1
  316.     beq    button30
  317.     bchg    #0,11(a4,d4.w)
  318.     bchg    #0,11(a5,d4.w)
  319.     tst.w    d5
  320.     beq    button8
  321.     tst.b    0(a2,d5.w)
  322.     beq    button31
  323.     bra    button8
  324. button30    tst.w    d5
  325.     beq    button8
  326.     tst.b    0(a2,d5.w)
  327.     bne    button8
  328.     tst.b    0(a3,d5.w)
  329.     beq    button10
  330. button31    sf    0(a3,d5.w)
  331.     lea    blanc(pc),a3
  332.     bra    button6
  333. button8    st    0(a3,d5.w)
  334.     move.w    choix,d1
  335.     mulu    #24,d1
  336.     move.l    12(a1,d1.w),a3
  337.     move.l    (a3),a3
  338. button6    move.b    (a3)+,d0
  339.     cmp.b    #'A',d0
  340.     bcc    button7
  341.     moveq    #' ',d0
  342.     subq    #1,a3
  343. button7    move.b    d0,(a0)+
  344.     dbf    d6,button6
  345.     move.w    d5,d0
  346.     add.w    #mnemo,d0
  347.     move    d0,intin
  348.     bsr    obj_redr
  349. button10    clr.w    d0
  350.     lea    foper(pc),a3
  351.     move.b    0(a2,d5.w),d0
  352.     btst    d5,fmasq2+1
  353.     bne    button32
  354.     cmp.b    0(a3,d5.w),d0
  355.     beq    button11
  356. button32    move.b    d0,0(a3,d5.w)
  357.     ext.w    d0
  358.     add.w    #syntaxe0,d0
  359.     move.w    #5,intin
  360.     move.w    d0,intin+2
  361.     bsr    rsc_gadr
  362.     move.l    12(a5,d4.w),a3
  363.     move.l    a0,(a3)
  364.     move.w    d5,d0
  365.     add.w    #operande,d0
  366.     move.w    d0,intin
  367.     bsr    obj_redr
  368. button11    dbf    d5,button5
  369.     clr.w    d0
  370.     move.l    #an,d5
  371.     cmp.b    #add,3(a2)
  372.     bne    button50
  373.     move.l    #anet,d5
  374.     bset    #1,d0
  375. button50    move.l    source*24+36(a1),a0
  376.     move.l    d5,(a0)
  377.     move.w    fnames,d5
  378.     move.w    d0,fnames
  379.     eor.w    d5,d0
  380.     move.w    d0,fname
  381.     move.w    6(a2),d3
  382.     bsr    affsrc
  383.     clr.w    d0
  384.     move.l    #dn,d5
  385.     cmp.b    #bitoper,3(a2)
  386.     bne    button51
  387.     move.l    #dnet,d5
  388.     bset    #0,d0
  389. button51    move.l    destinat*24+12(a1),a0
  390.     move.l    d5,(a0)
  391.     move.l    #an,d5
  392.     cmp.b    #addq,3(a2)
  393.     bne    button52
  394.     move.l    #anet,d5
  395.     bset    #1,d0
  396. button52    move.l    destinat*24+36(a1),a0
  397.     move.l    d5,(a0)
  398.     move.w    fnamed,d5
  399.     move.w    d0,fnamed
  400.     eor.w    d5,d0
  401.     move.w    d0,fname
  402.     move.w    8(a2),d3
  403.     bsr    affdest
  404.     move.w    4(a2),d3
  405.     move.w    #indicat*24,d2
  406.     moveq    #4,d4
  407.     move.w    findic,d5
  408.     move.w    d3,findic
  409.     eor.w    d3,d5
  410.     beq    button15
  411.     lea    indictab(pc),a3
  412. button12    move.w    d5,d0
  413.     and.w    #7,d0
  414.     beq    button14
  415.     move.b    15(a1,d2.w),d1
  416.     and.b    #$80,d1
  417.     move.w    d3,d6
  418.     and.w    #7,d6
  419.     move.b    0(a3,d6.w),12(a1,d2.w)
  420.     btst    #2,d0
  421.     beq    button13
  422.     bchg    #0,11(a1,d2.w)
  423. button13    move.w    d2,d0
  424.     ext.l    d0
  425.     divu    #24,d0
  426.     move.w    d0,intin
  427.     bsr    obj_redr
  428. button14    add.w    #24,d2
  429.     lsr    #3,d3
  430.     lsr    #3,d5
  431.     dbf    d4,button12
  432. button15    move.b    3(a2),d3
  433.     ext.w    d3
  434.     cmp.w    finfo,d3
  435.     beq    button16
  436.     move.w    d3,finfo
  437.     tst.w    d3
  438.     bne    button17
  439.     move.w    #operat,intin
  440.     bsr    obj_redr
  441. button16    rts
  442. button17    move.w    d3,intin+2
  443.     bsr    rsc_tree
  444.     move.l    operat*24+16(a1),d0
  445.     add.l    xbase,d0
  446.     move.l    d0,16(a0)
  447.     bsr    tree_drw
  448. button99    rts
  449. button9    lea    fmnem(pc),a3
  450.     moveq    #2,d5         
  451.     move.l    ecran,a1
  452. button40    tst.b    0(a3,d5.w)
  453.     beq    button41
  454.     move.w    d5,d0
  455.     add.w    #masque,d0
  456.     move.w    d0,intin
  457.     clr.w    intin+2
  458.     move.l    xmouse,intin+4
  459.     move.l    a1,addrin
  460.     move.l    #$2b040101,d0
  461.     bsr    aes
  462.     cmp.w    #-1,d0
  463.     bne    button42
  464. button41    dbf    d5,button40
  465.     rts
  466. button42    move.w    fmasque,d1
  467.     bchg    d5,d1
  468.     tst.w    d1
  469.     beq    button99
  470.     eor.w    d1,fmasque
  471.     move.w    #(mnemo+2)*24,d3
  472.     move.w    #(operande+2)*24,d4
  473.     moveq    #2,d6
  474. button43    btst    d6,d1
  475.     beq    button44
  476.     bchg    #0,11(a1,d3.w)
  477.     bchg    #0,11(a1,d4.w)
  478.     move.w    #mnemo,intin
  479.     add.w    d6,intin
  480.     bsr    obj_redr
  481.     move.w    #operande,intin
  482.     add.w    d6,intin
  483.     bsr    obj_redr
  484. button44    sub.w    #24,d3
  485.     sub.w    #24,d4
  486.     dbf    d6,button43
  487.     asl.w    #2,d5
  488.     lea    instruc(pc),a2
  489.     move.w    choix,d1
  490.     subq    #instr1,d1
  491.     mulu    #long,d1
  492.     add.l    d1,a2
  493.     move.w    6(a2,d5.w),d3
  494.     bsr    affsrc
  495.     move.w    8(a2,d5.w),d3
  496.     bsr    affdest
  497.     rts
  498.  
  499. affsrc    movem.l    d0-d5,-(a7)
  500.     move.w    #source*24,d2
  501.     move.w    fsource,d4
  502.     move.w    d3,fsource
  503.     bsr    affich
  504.     move.w    #longueur*24,d2
  505.     moveq    #2,d4
  506.     lsr.w    #1,d3
  507.     beq    affsrc1
  508.     bsr    affich1
  509. affsrc1    movem.l    (a7)+,d0-d5
  510.     rts
  511. affdest    movem.l    d0-d5,-(a7)
  512.     move.w    #destinat*24,d2
  513.     move.w    fdest,d4
  514.     move.w    d3,fdest
  515.     bsr    affich
  516.     movem.l    (a7)+,d0-d5
  517.     rts
  518. affich    eor.w    d4,d3
  519.     moveq    #11,d4
  520.     move.w    fname,d1
  521. affich1    lsr.w    #1,d3
  522.     bcc    affich2
  523.     bchg    #0,11(a1,d2.w)
  524.     bra    affich3
  525. affich2    btst    #0,d1
  526.     beq    affich4
  527. affich3    move.w    d2,d5
  528.     ext.l    d5
  529.     divu    #24,d5
  530.     move.w    d5,intin
  531.     bsr    obj_redr
  532. affich4    add.w    #24,d2
  533.     lsr.w    #1,d1
  534.     dbf    d4,affich1
  535.     rts
  536.  
  537.  
  538. *****************************
  539. *     Fonctions  A.E.S      *
  540. *****************************
  541.  
  542. initappl    move.l    #$0a000100,d0
  543.     bra    aes
  544. evn_mult  move.w    #%010011,intin
  545.     move.w    #1,intin+2
  546.     move.w    #1,intin+4
  547.     move.w    #1,intin+6
  548.     clr.l    intin+8
  549.     clr.l    intin+12
  550.     clr.l    intin+16
  551.     clr.l    intin+20
  552.     clr.l    intin+24
  553.     clr.l    intin+28
  554.     move.l    #tampon,addrin
  555.     move.l    #$19100701,d0
  556.     bsr    aes
  557.     move.w    d0,event
  558.     move.w    intout+2,xmouse
  559.     move.w    intout+4,ymouse
  560.     move.w    intout+10,key
  561.     rts
  562. obj_redr    move.l    xbase,intin+4
  563.     move.l    lbase,intin+8
  564. obj_draw    move.w    #20,intin+2
  565.     move.l    ecran,addrin
  566.     move.l    #$2a060101,d0
  567.     bra    aes
  568. tree_drw    move.l    16(a0),intin+4
  569.     move.l    20(a0),intin+8
  570. tree_dr2    move.w    #20,intin+2
  571.     move.l    a0,addrin
  572.     move.l    #$2a060101,d0
  573.     bra    aes
  574. m_hide    move.w    #256,intin
  575.     bra    g_mouse
  576. m_last    move.w    #257,intin
  577. g_mouse    move.l    #$4e010100,d0
  578.     bra    aes
  579. beg_ebdt    move.w    #1,intin
  580.     move.l    #$6b010100,d0
  581.     bra    aes
  582. end_ebdt    clr.w    intin
  583.     move.l    #$6b010100,d0
  584.     bra    aes
  585. w_set    move.w    id_fen,intin
  586.     move.l    #$69060100,d0
  587.     bra    aes
  588. w_get    move.w    id_fen,intin
  589.     move.l    #$68020500,d0
  590.     bra    aes
  591. rsc_tree    clr.w    intin
  592. rsc_gadr    move.l    #$70020100,d0
  593.     bsr    aes
  594.     move.l    addrout,a0
  595.     rts
  596.  
  597. aes    movem.l    d1-d3/a0,-(a7)
  598.     moveq    #3,d1
  599.     moveq    #6,d2
  600.     lea    ctrlaes(pc),a0
  601. aes1    move.b    d0,d3
  602.     ext.w    d3
  603.     move.w    d3,0(a0,d2.w)
  604.     lsr.l    #8,d0
  605.     subq    #2,d2
  606.     dbra    d1,aes1
  607.     move.l    #aespb,d1
  608.     move.w    #$c8,d0
  609.     trap    #2
  610.     movem.l    (a7)+,d1-d3/a0
  611.     move.w    intout,d0
  612.     rts
  613.  
  614. *****************************
  615. *     Fonctions  V.D.I      *
  616. *****************************
  617.  
  618. opnvwk    movem.l    d1,-(a7)
  619.     move.l    #$4d000500,d0
  620.     bsr    aes
  621.     move.w    d0,ctrlvdi1+12
  622.     move.l    #vdipb1,d1
  623.     move.w    #$73,d0
  624.     trap    #2
  625.     move.w    ctrlvdi1+12,id_stat
  626.     movem.l    (a7)+,d1
  627.           rts
  628. clsvwk    move.l    d1,-(a7)
  629.     move.w    id_stat,ctrlvdi2+6
  630.     move.l    #vdipb2,d1
  631.     move.w    #$73,d0
  632.     trap    #2
  633.     movem.l    (a7)+,d1
  634.     rts
  635.  
  636. *****************************
  637. *           Data            *
  638. *****************************
  639.  
  640. nom_acc    dc.b    '  Help 68000  ',0
  641. nom_rsc    dc.b    'help68.rsc',0
  642. blanc    dc.b    '       ',0
  643. anet    dc.b    'An*',0
  644. an    dc.b    'An',0
  645. dnet    dc.b    'Dn*',0
  646. dn    dc.w    'Dn',0
  647. indictab    dc.b    ' ?01 '
  648.     even
  649. long    equ    18
  650. instruc:
  651. _abcd    dc.b    1,2,0,0
  652.     dc.w    bxp+bni+bzp+bvi+bcp
  653.     dc.w    m1+lb,m1,m5+lb,m5,0,0
  654. _add    dc.b    3,4,0,add
  655.     dc.w    bp
  656.     dc.w    mtout+lbwl,m1,m1+lbwl,mdest-m1,0,0
  657. _adda    dc.b    5,0,0,0
  658.     dc.w    bna
  659.     dc.w    mtout+lw+ll,m2,0,0,0,0
  660. _addi    dc.b    6,0,0,0
  661.     dc.w    bp
  662.     dc.w    m12+lbwl,mdest,0,0,0,0
  663. _addq    dc.b    6,0,0,addq
  664.     dc.w    bp
  665.     dc.w    m12+lbwl,mdest+m2,0,0,0,0
  666. _addx    dc.b    1,2,0,0
  667.     dc.w    bp
  668.     dc.w    m1+lbwl,m1,m5+lbwl,m5,0,0
  669. _and    dc.b    3,4,0,0
  670.     dc.w    bnp+bzp+bv0+bc0
  671.     dc.w    lbwl+mtout-m2,m1,lbwl+m1,mdest-m1,0,0
  672. _andi    dc.b    6,0,0,0
  673.     dc.w    bnp+bzp+bv0+bc0
  674.     dc.w    lbwl+m12,mdest,0,0,0,0
  675. _andic    dc.b    7,0,0,0
  676.     dc.w    bp
  677.     dc.w    lb+m12,0,0,0,0,0
  678. _andis    dc.b     8,0,0,privileg
  679.     dc.w    bp
  680.     dc.w    lw+m12,0,0,0,0,0
  681. _asl    dc.b    1,9,10,asl
  682.     dc.w    bp
  683.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  684. _asr    dc.b    1,9,10,asr
  685.     dc.w    bp
  686.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  687. _bcc    dc.b    11,0,0,0
  688.     dc.w    bna
  689.     dc.w    0,0,0,0,0,0
  690. _bchg    dc.b    4,6,0,bitoper
  691.     dc.w    bzp
  692.     dc.w    lb+ll+m1,mdest,lb+ll+m12,mdest,0,0
  693. _bclr    dc.b    4,6,0,bitoper
  694.     dc.w    bzp
  695.     dc.w    lb+ll+m1,mdest,lb+ll+m12,mdest,0,0
  696. _bra    dc.b    11,0,0,0
  697.     dc.w    bna
  698.     dc.w    0,0,0,0,0,0
  699. _bset    dc.b    4,6,0,bitoper
  700.     dc.w    bzp
  701.     dc.w    lb+ll+m1,mdest,lb+ll+m12,mdest,0,0
  702. _bsr    dc.b    11,0,0,0
  703.     dc.w    bna,0,0,0,0,0,0
  704. _btst    dc.b    4,6,0,bitoper
  705.     dc.w    bzp
  706.     dc.w    lb+ll+m1,mdest,lb+ll+m12,mdest,0,0
  707. _chk    dc.b    3,0,0,chk
  708.     dc.w    bnp+bzi+bvi+bci
  709.     dc.w    lw+mtout-m2,m1,0,0,0,0
  710. _clr    dc.b    10,0,0,0
  711.     dc.w    bn0+bz1+bv0+bc0
  712.     dc.w    lbwl,mdest,0,0,0,0
  713. _cmp    dc.b    3,0,0,add
  714.     dc.w    bnp+bzp+bvp+bcp
  715.     dc.w    lbwl+mtout,m1,0,0,0,0
  716. _cmpa    dc.b    5,0,0,0
  717.     dc.w    bnp+bzp+bvp+bcp
  718.     dc.w    lw+ll+mtout,m2,0,0,0,0
  719. _cmpi    dc.b    6,0,0,0
  720.     dc.w    bnp+bzp+bvp+bcp
  721.     dc.w    lbwl+m12,mdest,0,0,0,0
  722. _cmpm    dc.b    12,0,0,0
  723.     dc.w    bnp+bzp+bvp+bcp
  724.     dc.w    lbwl+m4,m4,0,0,0,0
  725. _dbcc    dc.b    13,0,0,dbcc
  726.     dc.w    bna
  727.     dc.w    lw+m1,0,0,0,0,0
  728. _divs    dc.b    3,0,0,divise
  729.     dc.w    bnp+bzp+bvp+bc0
  730.     dc.w    lw+mtout-m2,m1,0,0,0,0
  731. _divu    dc.b    3,0,0,divise
  732.     dc.w    bnp+bzp+bvp+bc0
  733.     dc.w    lw+mtout-m2,m1,0,0,0,0
  734. _eor    dc.b    4,0,0,0
  735.     dc.w    bnp+bzp+bv0+bc0
  736.     dc.w    lbwl+m1,mdest,0,0,0,0
  737. _eori    dc.b    6,0,0,0
  738.     dc.w    bnp+bzp+bv0+bc0
  739.     dc.w    lbwl+m12,mdest,0,0,0,0
  740. _eoric    dc.b    7,0,0,0
  741.     dc.w    bp
  742.     dc.w    lb+m12,0,0,0,0,0
  743. _eoris    dc.b    8,0,0,privileg
  744.     dc.w    bp
  745.     dc.w    lw+m12,0,0,0,0,0
  746. _exg    dc.b    14,0,0,0
  747.     dc.w    bna
  748.     dc.w    ll+m1+m2,m1+m2,0,0,0,0
  749. _ext    dc.b    15,0,0,0
  750.     dc.w    bnp+bzp+bv0+bc0
  751.     dc.w    lw+ll,m1,0,0,0,0
  752. _illegal    dc.b    0,0,0,illegal
  753.     dc.w    bna,0,0,0,0,0,0
  754. _jmp    dc.b    10,0,0,0
  755.     dc.w    bna
  756.     dc.w    0,m3+m6+m7+m8+m9+m10+m11,0,0,0,0
  757. _jsr    dc.b    10,0,0,0
  758.     dc.w    bna
  759.     dc.w    0,m3+m6+m7+m8+m9+m10+m11,0,0,0,0
  760. _lea    dc.b    5,0,0,0
  761.     dc.w    bna
  762.     dc.w    ll+m3+m6+m7+m8+m9+m10+m11,m2,0,0,0,0
  763. _link    dc.b    16,0,0,0
  764.     dc.w    bna
  765.     dc.w    m2,m12,0,0,0,0
  766. _lsl    dc.b    1,9,10,asl
  767.     dc.w    bxp+bnp+bzp+bv0+bcp
  768.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  769. _lsr    dc.b    1,9,10,lsr
  770.     dc.w    bxp+bnp+bzp+bv0+bcp
  771.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  772. _move    dc.b    17,0,0,add
  773.     dc.w    bnp+bzp+bv0+bc0
  774.     dc.w    lbwl+mtout,mdest,0,0,0,0
  775. _movec    dc.b    18,0,0,0
  776.     dc.w    bp
  777.     dc.w    lb+mtout-m2,0,0,0,0,0
  778. _movea    dc.b    5,0,0,0
  779.     dc.w    bna
  780.     dc.w    lw+ll+mtout,m2,0,0,0,0
  781. _moveu    dc.b    19,20,0,privileg
  782.     dc.w    bna
  783.     dc.w    ll,m2,ll+m2,0,0,0
  784. _movefs    dc.b    21,0,0,0
  785.     dc.w    bna
  786.     dc.w    lw,mdest,0,0,0,0
  787. _movets    dc.b    22,0,0,privileg
  788.     dc.w    bp
  789.     dc.w    lw+mtout-m2,0,0,0,0,0
  790. _movem    dc.b    23,24,0,0
  791.     dc.w    bna
  792.     dc.w    lw+ll+m1+m2,m3+m5+m6+m7+m8+m9
  793.     dc.w    lw+ll+m3+m4+m6+m7+m8+m9+m10+m11,m1+m2,0,0
  794. _movep    dc.b    25,26,0,0
  795.     dc.w    bna
  796.     dc.w    lw+ll+m1,m6,lw+ll+m6,m1,0,0
  797. _moveq    dc.b    27,0,0,moveq
  798.     dc.w    bnp+bzp+bv0+bc0
  799.     dc.w    ll+m12,m1,0,0,0,0
  800. _muls    dc.b    3,0,0,0
  801.     dc.w    bnp+bzp+bv0+bc0
  802.     dc.w    lw+mtout-m2,m1,0,0,0,0
  803. _mulu    dc.b    3,0,0,0
  804.     dc.w    bnp+bzp+bv0+bc0
  805.     dc.w    lw+mtout-m2,m1,0,0,0,0
  806. _nbcd    dc.b    10,0,0,0
  807.     dc.w    bxp+bni+bzp+bvi+bcp
  808.     dc.w    lb,mdest,0,0,0,0
  809. _neg    dc.b    10,0,0,0
  810.     dc.w    bp
  811.     dc.w    lbwl,mdest,0,0,0,0
  812. _negx    dc.b    10,0,0,0
  813.     dc.w    bxp+bni+bzp+bvi+bcp
  814.     dc.w    lbwl,mdest,0,0,0,0
  815. _nop    dc.b    0,0,0,0
  816.     dc.w    bna,0,0,0,0,0,0
  817. _not    dc.b    10,0,0,0
  818.     dc.w    bnp+bzp+bv0+bc0
  819.     dc.w    lbwl,mdest,0,0,0,0
  820. _or    dc.b    3,4,0,0
  821.     dc.w    bnp+bzp+bv0+bc0
  822.     dc.w    lbwl+mtout-m2,m1,lbwl+m1,mdest-m1,0,0
  823. _ori    dc.b    6,0,0,0
  824.     dc.w    bnp+bzp+bv0+bc0
  825.     dc.w    lbwl+m12,mdest,0,0,0,0
  826. _oric    dc.b    7,0,0,0
  827.     dc.w    bp
  828.     dc.w    lb+m12,0,0,0,0,0
  829. _oris    dc.b    8,0,0,privileg
  830.     dc.w    bp
  831.     dc.w    lw+m12,0,0,0,0,0
  832. _pea    dc.b    10,0,0,0
  833.     dc.w    bna
  834.     dc.w    ll+m3+m6+m7+m8+m9+m10+m11,0,0,0,0,0
  835. _reset    dc.b    0,0,0,privileg
  836.     dc.w    bna
  837.     dc.w    0,0,0,0,0,0
  838. _rol    dc.b    1,9,10,rol
  839.     dc.w    bnp+bzp+bv0+bcp
  840.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  841. _ror    dc.b    1,9,10,ror
  842.     dc.w    bnp+bzp+bv0+bcp
  843.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  844. _roxl    dc.b    1,9,10,roxl
  845.     dc.w    bxp+bnp+bzp+bv0+bcp
  846.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  847. _roxr    dc.b    1,9,10,roxr
  848.     dc.w    bxp+bnp+bzp+bv0+bcp
  849.     dc.w    lbwl+m1,m1,lbwl+m12,m1,lb,mdest-m1
  850. _rte    dc.b    0,0,0,privileg
  851.     dc.w    bp,0,0,0,0,0,0
  852. _rtr    dc.b    0,0,0,0
  853.     dc.w    bp,0,0,0,0,0,0
  854. _rts    dc.b    0,0,0,0
  855.     dc.w    bna,0,0,0,0,0,0
  856. _sbcd    dc.b    1,2,0,0
  857.     dc.w    bxp+bni+bzp+bvi+bcp
  858.     dc.w    lb+m1,m1,lb+m5,m5,0,0
  859. _scc    dc.b    10,0,0,scc
  860.     dc.w    bna,lb,mdest,0,0,0,0
  861. _stop    dc.b    28,0,0,privileg
  862.     dc.w    bp,m12,0,0,0,0,0
  863. _sub    dc.b    3,4,0,add
  864.     dc.w    bp,lbwl+mtout,m1,lbwl+m1,mdest-m1,0,0
  865. _suba    dc.b    5,0,0,0
  866.     dc.w    bna,lw+ll+mtout,m2,0,0,0,0
  867. _subi    dc.b    6,0,0,0
  868.     dc.w    bp,lbwl+m12,mdest,0,0,0,0
  869. _subq    dc.b    6,0,0,addq
  870.     dc.w    bp,lbwl+m12,mdest+m2,0,0,0,0
  871. _subx    dc.b    1,2,0,0
  872.     dc.w    bp,lbwl+m1,m1,lbwl+m5,m5,0,0
  873. _swap    dc.b    15,0,0,0
  874.     dc.w    bnp+bzp+bv0+bc0
  875.     dc.w    lw,m1,0,0,0,0
  876. _tas    dc.b    10,0,0,0
  877.     dc.w    bnp+bzp+bv0+bc0
  878.     dc.w    lb,mdest,0,0,0,0
  879. _trap    dc.b    29,0,0,trap
  880.     dc.w    bna,m12,0,0,0,0,0
  881. _trapv    dc.b    0,0,0,0
  882.     dc.w    bna,0,0,0,0,0,0
  883. _tst    dc.b    10,0,0,0
  884.     dc.w    bnp+bzp+bv0+bc0
  885.     dc.w    lbwl+mdest,0,0,0,0,0
  886. _unlk    dc.b    30,0,0,0
  887.     dc.w    bna,0,m2,0,0,0,0
  888.  
  889. *****************************
  890.  
  891. debpile    ds.w    $100
  892. newstack    equ    *
  893.  
  894. vdipb1    dc.l    ctrlvdi1,invdi1,0,outvdi1,ptsout1
  895. ctrlvdi1    dc.w    100,0,6,11,45,0,1
  896. invdi1    dc.w    1,1,1,1,1,1,1,1,1,1,2
  897. outvdi1    ds.w    45
  898. ptsout1    ds.w    12
  899.  
  900. vdipb2    dc.l    ctrlvdi2,0,0,0,0
  901. ctrlvdi2    dc.w    101,0,0,0,0,0,1
  902.  
  903. aespb    dc.l    ctrlaes,global,intin,intout,addrin,addrout
  904. ctrlaes    ds.w    4
  905. global    ds.w    16
  906. intin    ds.w    16
  907. intout    ds.w    8
  908. addrin    ds.l    4
  909. addrout    ds.l    4
  910.  
  911. id_appl    dc.w    1
  912. id_fen    dc.w    -1
  913. id_stat    dc.w    1
  914. num_acc    dc.w    1
  915. tampon    ds.w    8
  916. xmouse    dc.w    0
  917. ymouse    dc.w    0
  918. key    dc.w    0
  919. event    dc.w    0
  920. xfen    dc.w    0
  921. yfen    dc.w    30
  922. lfen    dc.w    640
  923. hfen    dc.w    360
  924. xbase    dc.w    0
  925. ybase    dc.w    40
  926. lbase    dc.w    640
  927. hbase    dc.w    350
  928. ecran    dc.l    0
  929. choix    dc.w    0
  930. info    dc.w    0
  931. fmnem    dc.b    0,0,0
  932. foper    dc.b    0,0,0
  933. fsource    dc.w    0
  934. fdest    dc.w    0
  935. findic    dc.w    0
  936. fmasque    dc.w    0
  937. fmasq2    dc.w    0
  938. finfo    dc.w    0
  939. fnames    dc.w    0
  940. fnamed    dc.w    0
  941. fname    dc.w    0
  942.  
  943.     end