cancel
Showing results for 
Search instead for 
Did you mean: 

Bug on Pinmap in SPC560B50L5 for set PWM

nooshin_1382
Associate II
Posted on April 23, 2015 at 10:11

Hi

I want to Emios-0 in SPC560B50L5 these Specific Pin (PB[11],PB[12],PB[13]) but when i set these pin in pin map as output like E0UC4 or E0UC5 ,... the pin map set the ANX Pins .

and i check in spcstudio for use these PWM pins no driver is exist only Emios-0 Group-0 exist and only can use channel 9 to 15 .

please help , about this issue

Best regards

Nazerian Vanima
4 REPLIES 4
Erwan YVIN
ST Employee
Posted on April 28, 2015 at 09:50

Hello Vanima ,

good catch, the first point is an issue and will be corrected in the next release SPC5Studio 3.5.

for the EMIOS-0 Group 0, i am checking with the experts and we will create a change request for this.

Best Regards

                    Erwan

nooshin_1382
Associate II
Posted on April 29, 2015 at 10:59

Hello Erwan

Thanks for your response

I have 2 requests :

1.Can you get me a samplecode for pwm with directly use from registers in SPC560B50L5?

or I wrote my pwm function but i saw a registers in Udesk i set correctlly but the program not work or sometimes cpu Is in halt mode.IAttach my pwm code here can you help me about this ? (this code Refrenced to Advanced light control and diagnostics using document.pdf -AN4300)

2.I Want to go in sleep mode and then wake up with one of external wakeup pin , can you help about this ?

Thanks So much Erwan

With Best Regards

Nazerian Vanima

________________

Attachments :

main.c : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006qZtX&d=%2Fa%2F0X0000000bpA%2FUplO.tkqb.Id0_.BXI8PZ6Nu3Rhe75Sa3PyPQCIWceY&asPdf=false
Erwan YVIN
ST Employee
Posted on April 29, 2015 at 17:06

Hello Vanima ,

1) I have tried your source code .. it seems to be stable. the CPU does not go in HALT Mode you can try to serve the interruption to track your interruption ..

OSAL_IRQ_HANDLER(SPC5_EMIOS0_GFR_F0F1_HANDLER) {
OSAL_IRQ_PROLOGUE();
uint32_t gfr = PWMD1.emiosp->GFR.R;
// Serve your interruption
OSAL_IRQ_EPILOGUE();
}

2- About Sleep Mode , You can use use the STOP MODE or STANDBY MODE Chapter Modes Details This mode is fully configurable by ME_STOP_MC / ME_STANDBY_MC

if
(halSPCSetRunMode(SPC5_RUNMODE_DRUN) == OSAL_FAILED) {
SPC5_CLOCK_FAILURE_HOOK();
}

/* Peripherals run and low power modes initialization.*/ by RUN_PC & RUN_LP (cf spc_clock_init()) and you should configure your correct ME_PCTL0... we have a change request to provide in SPC5Studio a Low Power Mode DEMO Application. Best Regards Erwan
Nickname2551_O
Associate III
Posted on April 30, 2015 at 14:02

Hello,

for your information, version SPC5Studio_v3.4.5, containing the fix of the pinmap wizard concerning ADC input, has just been delivered.

Best regards

Philippe