Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
POWERBRICK-LV as Macro-Auxiliary: Configuration problem.
On a PowerBrick-LV, (Firmware, IDE configured as Macro-auxliary,
we have declared a brushless motor as slave Node 0, drived in PWM over MACRO (by a rack Power-UMAC).
We activated the motor as Macro-slave by :
Motor[1].pMotorNode = PowerBrick[0].MacroInA[0][0].a
Motor[1].MotorNodeOffset = 64
Motor[1].MotorMode = 5 // PWM by MACRO

Problem on the PowerBrick:
The Motor phase measured current "Motor[1].IaMeas, .IbMeas" are not copied in PowerBrick[0].MacroOutA[0][1] and [2]
(instead, there is a bad value depending of the encoder position ??, same value is in .MacroOutA[0][1] and .MacroOutA[0][2], but shifted of 16bits left in .MacroOutA[0][1] !)
Ps: the values written in PowerBrick[0].MacroOutA[0][0] (encoder pos) and PowerBrick[0].MacroOutA[0][3] (Status & Flags) are full ok

Have we missing something ?,
or is there a real problem and what is the way to turn around it ?

PS: with Motor[1].MotorMode =0 (Local contol) the motor works ok.

Thanks for your Help,
What are the pointer settings in the coordinating PPmac. For example Motor[x].pAdc, Motor[x].PhaseCtrl, and the several other pointers starting on page 728 of the PPmac User's Manual of March 17th 2014?
Hello Brad,
Thank you,
Here-under my parameters and find attached the global pp_save.cfg.

Quote:// ++ Clocks ++
PowerBrick[0].PhaseServoDir = 0 //Master
PowerBrick[0].PhaseFreq = 32000 //Phase-Clock =32 KHz (=freq du Ring)
PowerBrick[0].PhaseClockDiv = 0
PowerBrick[0].ServoClockDiv = 3 //Servo-Clock = 8 KHz
PowerBrick[0].PhaseClockMult= 0;
PowerBrick[1].PhaseServoDir = 3 //pas Master
PowerBrick[1].PhaseFreq = 32000 //Phase-Clock =32 KHz (=freq du ring)
PowerBrick[1].PhaseClockDiv = 0
PowerBrick[1].ServoClockDiv = 3 //Servo-Clock = 8 KHz
PowerBrick[1].PhaseClockMult= 0;
Sys.PhaseCycleExt = 1 //(i7) <- division par 2 de la Freq-Phase car MACRO (=16K)
Sys.RtIntPeriod = 2 //(i8) Période du Rti
Sys.ServoPeriod = (PowerBrick[0].ServoClockDiv +1)/PowerBrick[0].PhaseFreq //(i10) (en msec)
Sys.PhaseOverServoPeriod =1/(PowerBrick[0].ServoClockDiv +1); //(utilisé uniquement si servo à la Phase-rate)
// Macro
PowerBrick[0].MacroModeA =$00408000; //->Ce Master est: Slave, synch par le Ring (= idem un Gate2 *256)
PowerBrick[0].MacroModeB =$0; //->Ce Master est: non actif
PowerBrick[0].MacroEnableA =$0F803F00; //Master-n°0: Nodes 0,1,2,3,4,5 validés (= idem un Gate2 *256)
PowerBrick[0].MacroEnableB =$0; //Master-n°1: -aucun node validés-
Macro.TestPeriod = 20; // macro ring cycles in test period (i80)
Macro.TestMaxErrors = 2; // max macro errors allowed in test period (i81)
Macro.TestReqdSynchs = 16; // min synch packets needed in test period (i82)
// Motors
Motor[1].pMotorNode = PowerBrick[0].MacroInA[0][0].a //Consignes sur: Gate3-0, ICMacro-A, Node-0
Motor[1].MotorNodeOffset = 64 //=64 si Gate3, =0 si Gate2)
Motor[1].MotorMode = 5 //=5 PWM par MACRO

Motor[1].ServoCtrl = 1 // L'axe doit etre actif sur le Slave
Motor[1].PhaseCtrl = 4 //(=1 Gate3 ou =4 Gate1 ou pas packed) même si commandé MACRO en PWM (.MotorMode= 5)
Motor[1].pEncCtrl = PowerBrick[0].Chan[0].OutCtrl.a //(Control Ampli)
Motor[1].pDac = PowerBrick[0].Chan[0].Pwm[0].a //(si .MotorMode= 5) Consignes lue sur MACRO
Motor[1].pEncStatus = PowerBrick[0].Chan[0].Status.a // (Status Ampli)
Motor[1].pAmpEnable = PowerBrick[0].Chan[0].OutCtrl.a //(Enable Ampli)
Motor[1].pAmpFault = PowerBrick[0].Chan[0].Status.a // (Fault Ampli)
Motor[1].pLimits = PowerBrick[0].Chan[0].Status.a // Limites
Motor[1].pAdc = PowerBrick[0].Chan[0].AdcAmp[0].a //(si .MotorMode= 5) Courants émis sur MACRO
Motor[1].pEnc = EncTable[1].a //(si .MotorMode= 5) Feedback émis sur MACRO
Motor[1].pEnc2 = EncTable[1].a // ici peu importe la .pEnc car aucun codeur connecté PowerBrick
Motor[1].AmpFaultLevel =1
Motor[1].EncType =5

Gate3[0].Chan[0].PackOutData = 0 //Pour PowerBrick-LV (1=defaut)
Gate3[0].Chan[0].PackInData = 0 //Pour PowerBrick-LV (2=defaut)

Attached Files
.txt   pp_save.cfg.txt (Size: 104.71 KB / Downloads: 2)
This looks like the data from the slave brick. I would like to see the data from the coordinating (master) brick. Or have I misunderstood?
Sorry Brad,
Here is attached the configuration of our coordinating PPmac (UMAC).
Motor 1 is configured as this :
- Encoder sinCos+hall on local Acc-24E3,
- Motor and limits, drived as Node-0 (of a PowrBrick) in PWM

Attached Files
.pmh   Umac_conf_macro&motor.pmh (Size: 10.3 KB / Downloads: 16)
I have only tested the Power Brick auxiliary feature in Torque mode. The majority of people use it this way. Any particular reason why you want to do PWM instead? There is no benefit in further loading the master, especially that the slave unit possesses a CPU which might as well be put to use (computational load sharing). So that eventually the commutation and current loop are performed locally at the slave side.

Nevertheless, the current feedback should come back properly... I can take a look at this when I get back into the office sometime next week.
I di not see anything you have missed. I do not have a system to test with so the best option seems to be to do as Richard suggests and unload the main CPU by letting the slave do some of this work. That will get you going and later Richard can see why your setup did not work.
Thank you Brad and Richard,
You're absolutely right, and the final projet will be composed with several PowerBrick with SinCos-ACI option drived in Torque mode.

For the moment, and quickly, we have to validate the process of the machine.
For that, we have to drive a linear motor with a sincos encoder and our PowerBrick has not the option Sincos installed. We have only a Power-UMAC with Macro and Acc24E3 available to read the SinCos.
It's why we try to work with the PowerBrick in Macro-PWM mode.

Forum Jump:

Users browsing this thread: 1 Guest(s)