Custom Hardware Stops (con't)

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

This is a continuation of the thread here: Custom Hardware Stops

Ok, the supplier of my board supplier is mouser (as I order little quantity for prototypes).

I have another issue with PWM, and it's maybe related, I'm using the PMU clock for one the four available.

After 30 sec I have

a blecm event trace pwm pmu.PNG

After this event, my PWM change frequency.

pwm trace with PMU clk.PNG

Any clue ?

Here you can find what I can extract from my schmatic. Without too much problem.

schematic.PNG

You can see that the C8 100nF is on the same side of the board, we have only 1 side where component are sold.

This was taken from all doc we could find, if something is wrong, let me know ...

pcb.PNG

0 Likes
1 Solution

When PMU_CLK is used as reference, PMW will not function during sleep. LHL_CLK on the other hand continues to function in sleep. So this is all expected. Your only option now is to disable sleep.

View solution in original post

10 Replies
asridharan
Employee
Employee
10 comments on KBA 5 comments on KBA First comment on KBA

y.farrer

What is the frequency of the PWM before and after the event? Are you using LHL_CLK as the reference clock of the PWM?

0 Likes
Anonymous
Not applicable

PMU,

aclk_configure(10000, ACLK1, ACLK_FREQ_1_MHZ);

changing ACLK_FREQ_1_MHZ with 24 doesnt change the issue.

before the event I measure a period of 255.6ms, which is 4.43 Hz

after I measure a period of 3 sec, which is 0.33Hz

This event is happening after 30 sec around, I'm not changing any pwm configuration.

If I connect my board by BLE to my tablet blecm event happen before these 30 s and I've got the same issue, but earlyier...

0 Likes

And how are you starting the PWM? What are the parameters to pwm_start()?

0 Likes
Anonymous
Not applicable

    pwm_start(pwm->pwm_number, pwm->clockReference, 0x3FF, 0);

where number is 0 and clockReference is PMU.

0 Likes

Try changing your reference clock to LHL_CLK.

0 Likes
Anonymous
Not applicable

I can, but it's not what I need.

3 other PWM are under the LHL.

This one needs to have the hability to go from  0.1Hz to 2kHz

0 Likes
Anonymous
Not applicable

I just tried SDK 2.2.1, no improvement.

At Init :

aclk_configure(256000, ACLK1, ACLK_FREQ_24_MHZ);

pwm_start(0,PMU_CLK, 0x3FF, 0);

gpio_configurePin(GPIO_PIN_P26>>4,   GPIO_PIN_P26 && 0x0F , PWM0_OUTPUT_ENABLE_P26 ,0);

then when I need to activate the PWM I do :

pwm_start(0,PMU_CLK, 0x300, 0);

(or I tried pwm_transitionToSubstituteValues(pwm->pwm_number, 0x300, 0); no difference)

That's what I get ... So it's not event working properly before the 30 sec "event"

Doesn't make any sense ...

PWM trace aclk_256000_30sec.PNG

PWM trace aclk_256000.PNG

Zoom in on a spot, Delta between 2 slops (after 30 sec), 101.2ms

PWM trace aclk_256000_ZoomIn.PNG

0 Likes
Anonymous
Not applicable

when I disable high_undirect_adv_duration to "0" sec. I have the PWM output like if I was after the 30 sec.

if I change it to 300s, to stay in "fast" operation, and afeter 5 min it goes slow.

0 Likes

When PMU_CLK is used as reference, PMW will not function during sleep. LHL_CLK on the other hand continues to function in sleep. So this is all expected. Your only option now is to disable sleep.

Anonymous
Not applicable

Man ... thanks !

For information :

// Callback called by the FW when ready to sleep/deep-sleep. Disable both by returning 0

// when there is an active download ongoing.

UINT32 automation_io_device_lpm_queriable(LowPowerModePollType type, UINT32 context)

{

    // Disable sleep.

    return 0;

}

Inside the "create" function ;

devlpm_registerForLowPowerQueries(automation_io_device_lpm_queriable, 0);

0 Likes