Jump to content
OMRON Forums

How do I access encoder compare and EQU registers on ACC24E2


bradp
 Share

Recommended Posts

In Turbo PMAC we used the suggested M-variables M108->Y:$078207,0,24,S ; ENC1 compare A position M109->X:$078207,0,24,S ; ENC1 compare B position M110->X:$078206,0,24,S ; ENC1 compare autoincrement value M111->X:$078205,11 ; ENC1 compare initial state write enable M112->X:$078205,12 ; ENC1 compare initial state M114->X:$078205,14 ; AENA1 output status M115->X:$078200,19 ; USER1 flag input status M116->X:$078200,9 ; ENC1 compare output value To use the gatearray compare end EQU feature. I do not see PowerPMAC structures for all of these variables so what is now the procedure?[hr] M108 is Gate1[4].Chan[0].CompA ; ENC1 compare A position M109 is Gate1[4].Chan[0].CompB ; ENC1 compare B position M110 is Gate1[4].Chan[0].CompAdd ; ENC1 compare autoincrement value M111 is Gate1[4].Chan[0].Ctrl.19.1 ; ENC1 compare initial state write enable M112 is Gate1[4].Chan[0].Ctrl.20.1 ; ENC1 compare initial state M116 is Gate1[4].Chan[0].Status.17.1 ; ENC1 compare output value Now for m111, m112, m116 you can not make a bitwise definition. So you must either use bit masking on the structure name or make m-variable definitions. 1.) The formula for translating a UMAC M-Variable address for Power PMAC when (UMAC_Address – UMAC_Base) < 8 is as follows: If a X Memory location 32 + (UMAC_Address – UMAC_Base)*4 + PPMAC Base If a Y Memory location (UMAC_Address – UMAC_Base)*4 + PPMAC Base UMAC_Base for CS2 $78200 PPMAC_Base for CS2 $600000 In addition when translating bits you must add 8 to the bit value. The reason is bits 23 - 0 of the PMAC are always mapped as bits 31 - 8 on the Power PMAC. Bits 7 - 0 are meaningless So the address M114->X:$78205,14 becomes M114->u.io.$600034.22 on the Power PMAC. So the address M111->X:$078205,11 becomes M111->u.io.$600034.19 on the Power PMAC. So the address M112->X:$078205,12 becomes M112->u.io.$600034.20 on the Power PMAC. So the address M116->X:$078200,9 becomes M116->u.io.$600020.17 on the Power PMAC.
Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Popular Days

Guest
This topic is now closed to further replies.
 Share


×
×
  • Create New...