Jump to content
OMRON Forums

Amir

Members
  • Posts

    15
  • Joined

  • Last visited

Amir's Achievements

Apprentice

Apprentice (3/14)

  • Conversation Starter
  • Week One Done
  • One Month Later
  • One Year In
  • First Post

Recent Badges

0

Reputation

  1. I have a CK3M and would like to know how I can write directly to the Phase B output. I would like to use this output as a general purpose analog output. On the 15 pin connector, it is labeled Analog Output B+.
  2. Sina, A solution that would not require USB memory stick or SD card would be preferred. Consider packaging a new release of HMI and Delta Tau code for an end user to download. After the end user installs the new release, the new Delta Tau code is on the hard drive. It would be great for the end user to push a button on the new HMI that would build and download the new Delta Tau code. This could be a command line option to the Power PMAC Suite, where the Power PMAC Suite loads the new solution, builds and downloads and exits. Or some Telnet command...etc. Thanks
  3. Is there a command line I can send to telnet to build and download a PPmac solution? I am trying to facilitate the installation of a new release to my customer. Thanks
  4. Just found out that the M1 assignment is an Integer and not a floating point. You may use EncTable[9].ScaleFactor = 1/1000 eg. to add 3 more decimal places.
  5. I have master / slave working with ACC-28E. The question I have is how to control the speed of reaction to a new master command position. Below I describe the setup and algorithm. Motor[2] is stopped in closed loop during following. This is working fine, but when a new M1 is calculated, the slave motor 2 seems to want to jump to the new commanded master position as opposed to travel there in a given speed. Is there a way to control the speed? //--------------- // Setup the analog following in pp_Startup.txt //--------------- //Enc Table 9 is used for Z axis following the probe EncTable[9].Type = 1 //Parallel 32 bit m1->s.user:$20.0.32 //to set the master position EncTable[9].pEnc = Sys.pushm + $20 //s.user:$20.0.32 EncTable[9].Index1 = 0 EncTable[9].Index2 = 0 EncTable[9].Index3 = 0 EncTable[9].Index4 = 0 //integrate off EncTable[9].ScaleFactor = 1; //Set the Motor2 to follow EncTable 9 M1 = 0 //to set the initial position following Motor[2].pMasterEnc = EncTable[9].a Motor[2].MasterPosSf = 1; Motor[2].MasterCtrl = 1; //enable master following //------------------------- // Following Algorithm in rticplc.c //------------------------- //read the analog input AD1 = (*(pACC28E + 0xa00000/4 + 0)) /65536; //Calculate the error and multiply by a gain (P100) FollowAmount = p100 * ((34000 - AD1) / 34000); //Set the master encoder for motor 2 SetPtrVar(M1, FollowAmount);
  6. After power up on the Power PMAC, sometimes I have to rephase the motor using $* before any motion can take place and sometimes phasing is performed correctly/automatically on power up. Would placing #1 $* in the Startup.txt file solve this issue? If not, what will?
  7. Amir

    Serial Number

    Is there a unique serial number on the power PMAC and if so, which command do you use to access it?
  8. Is there a way to do a J+ or J- in a CPlc? All I found was the JogPosition() function which is the equivalent of J=.
  9. Amir

    RtiCplc

    Sys.ServoCount is not counting. Is this because there are no axis cards in the rack? If this is the case, is there a way to trick the Power PMAC into doing a background servo update? [quote='bradp' pid='871' dateline='1291076975'] The code is OK and runs on my system. So how is Sys.ServoCount, is it counting? How is Sys.WDTFault, is it 0? Do you have anything in the watch window that is setting UserAlgo.RtiCplc=0 or sending disable rticplc? Any other code that is running that could be doing this, check the task manager for other running programs and stop them. If all that turns up nothing then open a new project, issue $$$*** to PPmac, past the code into the rticplc and build and download and see if it now runs. [/quote]
  10. Amir

    M Variable Access

    Okay, the part that was missing, and not so obvious is that in the PMAC script language portion in the file plc1.plc you will have the following statement: #define MyPtrVar1 M1; #define MyPtrVar2 M2; and after a build, the file pp_proj.h is automatically generated and will produce something like: #define MyPtrVar1 1 #define MyPtrVar2 2 and then you can use MyPtrVar1 or MyPtrVar2 as an argument in GetPtrVar function from a C program with the added requirement that you include pp_proj.h. The bad part is that the compiler does not issue a warning if you accidentally reuse a definition like this: #define MyPtrVar1 M1; #define MyPtrVar1 M2; [quote='KEJR' pid='866' dateline='1291054158'] See edlay's response in a previous thread: "In your "global definitions.pmh" you have your M-ptr definition ptr MyPtrVar1->*; " Of course to make it do anything of much use you would want to map the M variable to something useful. KEJR [/quote]
  11. Amir

    RtiCplc

    my routine realtimeinterrupt_plcc() only runs once when I set UserAlgo.Rticplc=1. Each time I set UserAlgo.Rticplc=1 it will run just once and stop. What do I need to do to have it run continually?
  12. Amir

    M Variable Access

    In my case, the IDE has not auto assigned anything in the pp_proj.h file. Can you please provide one example of how MyPtrVar1 would be defined. [quote='KEJR' pid='862' dateline='1291045941'] In my example the MyPtrVar1 is defined in the delta tau IDE under global definitions. (PMAC Script Language / Global Includes / global definitions.pmh) What happens is that the IDE auto assigns unallocated P var indexes to your text name. The cool thing is that it is useable in the script programs, terminal, and C programs. The way they get brought into your C program is with the following include: #include "../../Include/pp_proj.h" There are other posts on here regarding global variables I believe, and there are some example C app projects installed with the IDE I think. KEJR [/quote]
  13. Amir

    M Variable Access

    In the example below, how is MyPtrVar1 defined? [quote='KEJR' pid='835' dateline='1289596869'] The global vars are nice, you don't have to type in hard M or P vars. I just want to point out that you don't have to declare another double in your code. You can do this kind of thing: MyScaledResult = (200* GetPtrVar(MyPtrVar1)) / 3; it makes a difference if you are using alot of Ptr vars or global vars. I personally don't like the GetPMACVar() function because of its possibility of throwing a run time error if you misspell the string. It is considerably slower too. Something to note if you are doing alot of global var manipulation. KEJR [/quote]
  14. 1. I have written a Windows program to communicate with the Power PMAC via Telnet. I can connect and I get the response "OK" after connecting, but there is no prompt to enter username or password. Do I have to do any "do, don't, will, won't" telnet handshaking? Or am I missing something else? 2. I used to use the PMAC.DLL to access the PMACGetResponseA function for my HMI. What is the equivalent and in which DLL for PowerPMAC? 3. Where is the communication library I see reference to on the forum?
  15. How do you access an M variable from a C PLC (user_plcc())?
×
×
  • Create New...