Jump to content
OMRON Forums

meindert.norg

Members
  • Posts

    39
  • Joined

  • Last visited

meindert.norg's Achievements

Contributor

Contributor (5/14)

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

Recent Badges

0

Reputation

  1. LS, Summary: Observation: Motor runs fast in opposite direction after hitting Positive end-switch. Cause: Configuration of "Overtravel Limit Use Bit" for motor #2 servo, which was used in series with #1 servo. Solution: Ignore Overtravel Limit switches for #2. Technical nitty gritty: When a motor hits an EndSwitch, moves in that direction are forbidden. When using 2 filters in series (#1 and #2), the #2 filter receives the #1FilterOutput through the #2MasterPosition input into its #2FollowingError. Positive changes to the #1FilterOutput are forbidden and ignored... ... but Negative changes to the #1FilterOutput are forwarded to the #2 Filter. In the presence of noise in #1FilterOutput, the result is a (fast) changing input in the negative direction for the #2 Filter... ...resulting in a large negative force on the motor... ... resulting in the motor moving away from the EndSwitch in an unexpected fast manner. Details: While testing Limit Switches (MLIM and PLIM) I noticed that everything worked according to expectation when using only one PID filter, but when using a second filter in series with the first filter, the motor would 'shoot back when hitting a Limit-Switch'. It is noteworthy to mention that I used manual switches for this test. The consequence is that if the motor moves away from the switch (as explained), the switch is not released as it would be if the switch was actually operated by the motor. In that case, the problem stated below is still true, but 'solves itself' automatically after the motor moves away from the switch. Still, the motor would experience an undesired jump in the opposite direction after hitting an End-Switch. I placed the filter from a #2 (unused motor) filter in series with the filter from my #1 motor, using the procedure from page 168 in the Turbo PMAC User Manual. This gave me to option to use both a low pass filter and a notch filter for my servo. In step 5 the procedure tell you to copy the Motor xx Flag Mode Control settings from the original motor (in my case #1) to the servo that is to be placed in series with the first motor (in my case #2). I used I124 = $800001: $1 = PMAC2 style. $80000 = Fault bit polarity This setting responds to EndSwitches by: Stopping the motor Ignoring any further positive commands, untill switch is released. When jogging in positive direction, and hitting the Positive Endswitch, the motor would immediate start running very fast in the opposite direction, as indicated in the measurement below. When zooming in to the event of hitting the EndSwitch, we observe that only negative (allowed) changes in the #1FilterOutput are forwarded to the #2FollowingError. This causes the #2filter to output an increasingly large negative value, making the motor accelerate in the negative direction. This problems is solved by ignoring the Endswitch flags for the second motor: #224 = $820001. regards, Meindert
  2. Hi Charles, During our phone conversation you mentioned that what really happens when the Master Position is used to calculate the Following Error FE is that per servo sample, each Master Position CHANGE is used to calculate FE. What does not happen is that (as the schematics above might make one believe) the Master Position (scaled with I107) is added to the FE. The fact that only changes propagate now gives a perfect explanation for my problem: When I106 (Master Position Enable) is switched on... ...the initial Master Position value (from my ECT) is ignored... ... and only consecutive changes to the Master Position propagate to the Following Error. That is exactly what I measured and showed in the plot above. I found an implementation that gives me the result I was looking for: I'm making sure the ECT contents that is linked to the Master Position is zero when I switch Master Position following on (I106=1). Then, I link the analog input to the Exponential Filter that feeds into the Master Position, and make sure the max rate of change is low enough: Disable I106 = 0 Point first element of ECT entry 3 (which is an Exponential-Filter) to ‘0’ (e.g. I8003 = $D035C0). Make sure to use $D in order not to change the "method". Then slow down max . rate of change for exp. filter (I8004) from $91 (=145) to $1: I8004 = $1 Then enable I106 = 1 Then point ECT entry 3 (I8003) to ECT result of entry 2 ($D03503): I8003 = $D03503, which was the original address. After delay reset max rate of change: I8004 = $91 Voila! Please let me know if my understanding of how Master Position is used is incorrect or if you find an easier way to do this. regards, Meindert
  3. Hi Charles, To respond to a few of your questions: I don't think it is a resolution issue, because my motor follows the analog input properly, IF I106 is set to 1. It does not follow if I106 is set to 0, as expected. I have the same behavior. After I106 is set to 1, the motor properly follows the analog input, it just does not take the initial ADC value into account AT THE MOMENT I106 is switched to 1.... I'm using entry 2 to copy the ADC result (which resides in Y-memory) into the table, because the exp.-filter (entry3) can not access Y-memory. It can only access X-memory, or earlier ECT results. Please correct me here if I'm making things more complex than they should. To be continued next week. regards, Meindert
  4. I103=$3501;Motor 1 Position Address I104=$3501;Motor 1 'Velocity' Address I105=$3506;Motor 1 Master Position Address I106=0;Motor 1 Master Follow Enable I107=3072;Motor 1 Master Scale Factor I108=96;Motor 1 Position Scale Factor I109=96;Motor 1 Velocity Scale Factor I8000=$78000;ECT Entry 0 I8001=$278005;ECT Entry 1 I8002=$C00C;ECT Entry 2 I8003=$D03503;ECT Entry 3 I8004=$91;ECT Entry 4 I8005=$200000;ECT Entry 5 I8006=$78018;ECT Entry 6 Or with more info: Encoder Table Definitions. Executed - Fri Mar 18 16:05:58 2011 Entry Address Y-Word Conversion Method ---------------------------------------------------- 1 Y:$ 3501 $078000 1/T extension of location $78000 2 Y:$ 3502 $278005 Unfiltered parallel pos of location Y:$78005 Y:$ 3503 $00C00C Width and Offset 3 Y:$ 3504 $D03503 Exponential filter from conv. encoder 4 ($C00C) Y:$ 3505 $000091 Maximum change in cts/cycle Y:$ 3506 $200000 Filter gain 4 Y:$ 3507 $078018 1/T extension of location $78018 5 Y:$ 3508 $078100 1/T extension of location $78100 6 Y:$ 3509 $078108 1/T extension of location $78108 7 Y:$ 350A $078110 1/T extension of location $78110 8 Y:$ 350B $078118 1/T extension of location $78118 FYI: I have motor 2 filter in series with motor 1 filter.
  5. Charles, Yes, tried that too, but did not get the effect I wanted. During out phone-call you mentioned that I should actually get the desired effect when doing what I'm doing, and that I actually should get a position jump when enabling I106 to 1 with I107 set to 1000 (actually, now we're getting more into details, I must be more correct and say that I107 = 3072). Well, I attached a measurement showing that I do not. This measurement shows what I'm doing: These are the steps I performed: t=0 sec: I106 = 0, analog input voltage (Vin) = 0 V t=3 sec: I106 = 1 t=5-7 sec: change Vin from 0 -> 6 and back to 0 V again. Notice the position (b) change from 0 -> 1.4e8 -> 0. This is approx +100 degrees. t=8 sec: I106 = 0 t=12 - 14 sec: I change Vin from 0 -> 3 V. t=17 sec: I106 = 1. Notice how the actual position does NOT change! t=18-24 sec: change Vin from 3 -> 6 -> 0 and back to 3 V again. Notice how the position now changes through the same 110 degrees, but shifted down. Does this explain what I'm observing? Is that according to your expectations? regards, Meindert
  6. Charles, Thanks for your answer. I'm afraid I did not explain clearly enough what my issue is. i don't think the %0 -> %100 command will work, because my motor is not moving at a specific speed, but is mostly moving around 0 following the value as indicated by the Master Position. Hence I don't think the FeedRate override will help here, but correct me if I'm wrong. First of all, I have no coordinate system defined, because I don't think my application asks for that. I'm running one motor, and the majority of the time all that motor is doing is stand still, while continually 'listening' to the Master Position setpoint. If that value changes (representing a desired change in motor position), the motor needs to follow that setpoint. So, the Master Position is not a velocity, it is a position. The problem arises when switching on Ix06, or changing Ix06 (thanks for the block diagram). Lets assume the situation where: the trajectory command = 0 the actual load position = 0 Ix06 = 0 Ix07 = 1000 the FE is zero and the ECT contents pointed to by Ix05 is 5. This 5 would be the same as 5 * (Ix07 = 1000) = 5000 cts. This 5000 cts is my desired position, as indicated by the earlier mentioned Analog Input signal. Problem: when I set Ix06 = 1, the motor does not move instantly. This is probably because the 5000 cts is compensated for somewhere else, with the result that FE does not change (and hence does not result in a motor move). The note: "Can be changed on the fly" indicates this. Question: how do I enable the Master Position feature so that the motor will end up at the location indicated by the analog input (at HW)? thanks, Meindert
  7. LS, The Clipper manual suggests: for the DAC (=PWM) Outputs Power Supply. My question: Are these +/-12 or +/-15 V used directly for the PWM H-bridge (and thus determine the maximal and minimal output voltage, and ultimately the servo-loop-gain) or does the Clipper have a 10 V regulator on board that limits the actual PWM output voltage to +/- 10 V? Thank you, Regards, Meindert
  8. LS, I have a question about what happens to a motor's setpoint when the master position is engaged (e.g. I106 is changed from 0 to 1). This is my configuration: 1 motor (#1) with encoder feedback ADC input connected to #1 master-position Master Pos Following off (I106=0) During startup, one of the first things that happens is motor-homing. During this phase, the ADC value for the master-position can be changing, but is ignored. After homing is complete, and the motor is moved to zero, the motor must start following the 'master position'. The ADC voltage represents the absolute motor-position, lets say 1V = 1 degree (with e.g. "Master Scale Factor" I107 = 1000), so with an ADC range of +- 10 V I have a range of +- 10 degrees. Numbers are just an example. My plan was to: Set "Master Scale Factor" (I107) to 0 Enable "Position Following Enable" (I106 = 1) Slowly increase "Master Scale Factor" (I107) from 0 to 1000 over e.g. 1 second. This way I could slowly 'pull' the motor towards the position as indicated with by the ADC voltage, and the ADC voltage would be allowed to change while doing this. However, when changing the "Master Scale Factor" (I107) or "Position Following Enable" (I106) the actual motor setpoint does not change (which in general is nice, because otherwise that would generate an step in setpoint, which is normally undesired), but is somehow offset with the master position value. My questions: What exactly is done with setpoints / master position values / offsets when I set I106 to 1 after I set I107 to 1000? In other words, where is the change in "Master Position"-value compensated for? And most importantly: what can I do to implement the desired behavior? Regards, Meindert Norg
  9. John, Thanks for your answer. I will definitely give this a try. Good luck with your telescopes. regards, Meindert
  10. LS, I was able to read Gathered data into Matlab using the ActiveX COM interface (supplied through the "Pcomm Server Pro 2 Library", as suggested by Charles in http://forums.deltatau.com/showthread.php?tid=354). The simplest code showing how to get data into Matlab is: hPcommServer = actxserver('PcommServer.PMacDevice'); hPmacDevice = hPcommServer.invoke('IPmacDevice'); results1 = hPmacDevice.Open(0); DataString = hPmacDevice.GetResponseEx(0,'list gather',1); The attached Matlab code includes error checking and data conversion that is required to generate the original values. regards, Meindert Norg DT_GatherData_v2_1.zip
  11. Sina, Thanks. Actually, I found that both the Master Position and the Commanded Position will 'go through' the [i]PID Velocity Feedforward Gain[/i] (Ixx32). Setting this parameter to match the [i]PID Derivative Gain[/i] (Ixx31) should result in a measurement as if one was measuring a PID controller that has the servo-error as input. I have not tried this yet though, because for now, Charles' suggestion to inject signals into the SinOutputDACBias works fine for me. Thanks, Meindert Norg
  12. Dear Serkan, Thanks for your suggestion. I implemented the random noise generator described on http://en.wikipedia.org/wiki/Linear_congruential_generator as: P907_Random_Value = ((P905_Random_Multiplier*P907_Random_Value) + P906_Random_Increment) % P908_Random_Modulus As mentioned on the Wiki, the generator-outcome strongly depends on the values of Modulus, Multiplier and Increment. For example with Modulus = 2^32, I only found combinations for the other parameters that would make the generator repeat itself every 256 samples or faster. The "Apple CarbonLib" settings do not show any repetition within 30.000 samples (that's how much memory I had left for gathering). P908_Random_Modulus = 2^(32)-1 P905_Random_Multiplier = 16807 P906_Random_Increment = 0 On my system, the cost of this code is approx. 21 usec (system: 80 MHz UMAC, at 6 kHz Servo interrupt, PLC0 with random generator running every servo-interrupt (I8 = 0). Taking out P906_Random_Increment from the equation reduces this by 6 usec. regards, Meindert Norg
  13. LS, Threat http://forums.deltatau.com/showthread.php?tid=407&pid=1457 speaks of injecting a sine-signals for identification purposes. In that threat, a PLC0 is used to calculate this sine signal on the fly. Does anyone have a method to calculate and inject a random signal (noise) instead of a sine-signal? Thanks. Meindert
  14. Sina / Charles, Thanks for your examples. They gave me a good head-start to get going with my Swept-Sine analysis. For the method of injecting a position signal into the servo-loop I ran into a limitation: by using the master position as injection point, the injected signal does not 'go through' the differentiator. The result is that the Kd (I131) can not be measured/estimated. Do you have a similar suggestion to inject a position signal that will go through the differentiator? Preferably a method that does not force me to 'open and close' the servo loop (like reconfiguring the ECT). I'd like to make this method an 'add-on' to an already existing and running servo-loop. Thank you.
  15. Hi, I also found a way to connect to the ActiveX COM-interface from Matlab. This is a short Matlab-code example to request the value of I130 from the controller: [code] % First connect to the Delta Tau COM server, which is implemented in % C:\WINDOWS\system32\PcommServer.exe. On my system, this executable is % started automatically when I call actxserver: hPcommServer = actxserver('PcommServer.PMacDevice'); % Create a handle to the custom interface: % This handle "hPmacDevice" will be the actual interfaces that is used to % make calls to the Delta Tau controller. hPmacDevice = hPcommServer.invoke('IPmacDevice'); % Open the interface to device 0. % From "PEWIN32PRO2", menu -> Terminal -> Select PMAC % opens a window with PMAC Devices. My UMAC is listed as number 00. results1 = hPmacDevice.Open(0); % Send a string and display its response, using GetResponseEx method: GetResponseExString = hPmacDevice.GetResponseEx(0,'I130',1) % Clean up: hPmacDevice.Close(0) hPmacDevice.delete clear hPcommServer; [/code] I attached the 'published' result of Matlab code with more explanation. I've not been able to successfully use gather related methods. I might be making the wrong calls (the PcommServer.pdf manual is somewhat unclear on what means what, and the examples don't get me any further either), or Matlab just does not like the Delta Tau COM implementation for those specific methods. I will update this post if I find out more. regards, Meindert
×
×
  • Create New...