This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PICCOLO microcontroller (F28027)

I am developing three phase power factor corrected AC to DC and DC-DC converter using PICCOLO microcontroller 320F28027, I want to use the motor controller library functions available for F2808 , like PID, sine, cosine, synchronous frame transformations ( park, ipark, clarke iclarke etc.), can somebody help me? How to include these functions for PICCOLO micro-controller, (please explain step by step procedure with one sample example).

 

Regards

 

Ghodke

  • Hi Dharmraj,

    Our block-diagram model-based software VisSim/ECD provides blocks for the transformations you mention as well as many others. It will setup libraries and calls to IQMath.lib and DMC libs so you can compile and link with no problems. Benchmarking has shown that it generates code within 5% of the performance of hand tuned assembler. To select your processor in VisSim, go to VisSim/DSP > F280x > DSP Config... and choose F28027 as target. You also choose the JTAG connection in this screen. It will correspond to the same connection that you setup in CCS Setup.

    VisSim can also create IIR or FIR filters using our filter wizard embedded in our transferFunction block. You can select floating point or fixed point implementation, simulate off-line to observe filter behavior against recorded signals or simulated signals, then use the code generation capability to automatically generate IQmath in-line code, compile and download to the target. Our JTAG link allows you to capture waveforms on the target and plot them in a digital scope on the PC.

    You can download a 2 month free trial here.

    Regards,

    Pete

  • Hi,

      I want to know if piccolo works with matlab. Piccolo suport RTDX? i want to know if you take some precaution to work without problems  (noise or static). You change the USB cable for other more protected?   Do you have problems with the emulator on board when you connect an oscilloscope? 

    Thanks.

    Gaston

  • Hi Gaston,

    I don't think that RTDX supports the XDS100 (http://tiexpressdsp.com/wiki/index.php?title=XDS100#Q:_When_using_DSP.2FBIOS_and_the_Real_Time_Analysis_setup_for_RTDX.2C_I_get_the_cpu_graph_and_real_time_logs_updating._Does_this_mean_RTDX_is_working.2Fsupported_on_the_XDS100.3F) The Piccolo control stick uses the XDS100. My guess is that if you used another emulator with Piccolo, like XDS510, RTDX would work OK. VisSim, which is a competitor to Matlab/Simulink, works fine with Piccolo. VisSim does not use RTDX for data exchange, it uses the CCS emulator drivers directly, so it is faster and not limited to RTDX support. It works fine with the USB Piccolo control stick. There is no problem using an oscilloscope with the USB Piccolo control stick for us (XDS100).

    Because of the small RAM space on the Piccolo (6K words), VisSim's generated code efficiency is very helpful in the development process. For instance, a customer of ours (Electric Motion Systems), has developed a PMSM space vector control with regenerative braking, I2C communication to EEPROM, RS485 SCI  supervisory control, security lock mode, temp status monitor, usage hour monitor etc. 100% in VisSim. It took less than 11K flash, and 2.5K RAM in the final flashable image for the f2801.

    Pete

  • HELLO I'M TRYING TO BUILD A SWITCHING REGULATOR USING THE F28027USB CONTROL STICK....I AM DRIVING A FULL MOSFET H-BRIDGE USING COMPLEMENTRY OUTPUTS FROM PWM1A AND PWM1B SINEWAVE PWM AFTER BOOTSTRAPPING...I'V IMPLEMENTED A VERY CRUDE SOFTSTART BUT IT WORKS...ONCE THE MOSFETS START SWITCHING AT A FREQUENCY OF 12.5KHz(MAX DUTY CYCLE IS 75%) THE OUTPUT IS GIVEN TO A STEP UP TRANSFORMER WHICH GIVES ME A DISTORTED SINE WAVE OF 200V ACROSS 2.5uF AC CAPACITANCE..NOW I WANT TO BOOST THE DUTY CYCLE TO GET 230VAC 50Hz..SO I RECTIFY THIS OUTPUT AND GET APPROX 1.3VDC AT MY ADC INPUT PIN A0 (PIN 3 OF THE CONTROLSTICK)..I'M USING A PRE-GENERATED LOOK-UP TABLE TO PASS DUTY CYCLE VALUES ACCORDING TO SINE THETA...I'M UNABLE TO BOOST THE DUTY CYCLE..PLEASE HELP...

    MY ADC CONFIGURATION :

        EALLOW;
        AdcRegs.ADCCTL1.bit.INTPULSEPOS    = 1;    //ADCINT1 trips after AdcResults latch
        AdcRegs.INTSEL1N2.bit.INT1E     = 1;    //Enabled ADCINT1
        AdcRegs.INTSEL1N2.bit.INT1CONT  = 0;    //enable ADCINT1 Continuous mode
        AdcRegs.INTSEL1N2.bit.INT1SEL    = 0;    //setup EOC0 to trigger ADCINT1 to fire
        AdcRegs.ADCSOC0CTL.bit.CHSEL     = 0;    //set SOC0 channel select to ADCINA0
        AdcRegs.ADCINTSOCSEL1.bit.SOC0     = 0;   
        AdcRegs.ADCSOC0CTL.bit.ACQPS     = 8;    //set SOC0 S/H Window to 7 ADC Clock Cycles, (6 ACQPS plus 1)
        AdcRegs.ADCSOC0CTL.bit.TRIGSEL     = 0;    //software trig
        EDIS;

    MY EPWM ISR :

        SOFT START:

            while(x<20)
            {
                  EPwm1Regs.CMPA.half.CMPA = (tab[i++]*x)/20;

                  i = i % 249;
                if(i==0)
                {
                    x++;
                }
                for(j=0;j<15000;j++);
            }

    NORMAL OPERATION:

               if(x>=20)
                {
                    x=20;

               

          
              
                            EPwm1Regs.CMPA.half.CMPA = (tab[i++]);
                       
                              i = i % 249;
                   
                       
                  
               
                            if(i==0)
                            {
                                AdcRegs.ADCSOCFRC1.bit.SOC0 = 1;   
                            }
                           
                    }

    //tab[i] = is my lookup table with 250 entries pre calculated...i'm triggering the ADC after evry completion of the entries

     

    MY PROGRAMMING IS VERY CRUDE BECAUSE I'M NEW TO STRUCTURES...PLEASE HELP ME OPTIMIZE MY  PROGRAM AND ACHIEVE BOTH BUCK AND BOOST ACTION...ANOTHER PROBLEM IS THAT ADC IS READING A VALUE ABOVE 3000 FOR 1.4VDC I/P TO THE PIN...I DONT UNDERSTAND WATS HAPPENIN...PLEASE HELP...ITS FRUSTRATING..

  • Salil,

    There is an errata related to the 1st sample of the ADC on rev 0 silicon.  You will need to double sample and disacrd the 1st sample and use the 2nd; this is why the data is so off base.

    http://focus.ti.com/lit/er/sprz292c/sprz292c.pdf

    Best,

    Matthew