Hi,
I'm new to this MSP programming using CCS. I'm using CCS v5 to program my msp430g2252. The program has a simple PWM generation part which is essential for the proper functioning of other codes. This program works fine until it reaches a breakpoint in debugging mode. The moment it reaches a break point the PWM generation from the pin is halted. Can anyone please tell me how to get the PWM from the msp even when the program is at a breakpoint. Like, some changes in settings??? i tried changing the clock control in debugger but no use.
Thanks in advance.
Hi Muthu,
what breakpoint settings do you use? Typically the target is halted which likely explains the behaviour you see. If you go to View->breakpoints to open the breakpoint view you should be able to see your breakpoint. If you right click you can see the properties.
Please keep us informed.
Best Regards
Lisa
Hi Lisa,
Thanks for your response.It shows like this
Hardware Configuration
Type:Simple
Action:Halt Target
Trigger 0 :Memory Address Bus
Mask:0xffff
Access:Instruction Fetch
Trigger 1:None
Debugger Response
Condition
skip count :0
Current count :0
Action:Remain Halted
Miscellaneous
Group:Default group
Name:Breakpoint
What should i change here to get the PWM at breakpoint?
go into Project->Properties->Dedug-> and in the MSP430 settings please go to the clock settings. You will notice all clocks by default set to stop on an emulation halt. This is what you need to change to keep the pwm going.
Please give that a try and keep us informed.
Best Regards,Lisa
I just wanted to double check whether the tip was helpful and whether there is an update to your enquiry.
Best Regards,
It's nice of you to enquire about that. I tried so many times to post but didn't work.
Actually, i tried changing this clock settings earlier also. when i make them working even in breakpoint, the pwm o/p is high or low depends on the time the program reaches the breakpoint. When the clocks are stopped during a emulation halt(break point), the pwm o/p is always low. This is the only difference i saw. Any suggestions would be helpful.
Thanks & Regards,
Muthu
HI Muthu,
have a look at this post and keep us informed whether it helps you:
https://e2e.ti.com/support/development_tools/code_composer_studio/int-code_composer_studio/f/90/p/100487/352393.aspx?Redirected=true#352393
When i check that link, it says that the group not found.
ok, appologies. Here is a summary of the information I hope will help you.
this is what I observed (with both CCS 4.1 and 4.2.1). I used the example msp430x54x_ta3_04.c (from the MSP43054xx C examples download), set the clock control settings as shown below. I run the code for a bit and then halt it. When the code is halted, I view the Timer1_A3 register in Registers view, set it for continuous refresh, and see the TA1R (timer counter) changing even when device is halted. It does not actually execute the interrupt code, but the timer itself is still counting. If I check the box for Timer1_A3 to stop the associated clock on emulation halt, then the TA1R register is not updated when device is halted.
So unchecking the ACLK or TACLK alone did not do it, but they had to also uncheck the associated Timer under Properties->CCS Debug-MSP430 Properties->Clock Control->Extended, correct? Those checkboxes appear after establishing connection with the device. So after clicking "Debug Active Project", in the debug perspective, go to menu Tools->Debugger options->MSP430 Debugger Options, and those checkboxes should be visible. After making changes to these settings, make sure to click the "Remember my Settings".
I wanted to check whether the last post and tips were helpful for you?
I got up with some other project and couldn't reply.
I used MSP430G2252. For this, it showed me " No module clock control available for current msp430 device". I guess, i have to use some other chips to work it out. Suggest me some chips.
actually, let me move this to the msp forum/team for you as they may have some further thoughts on the pwm options.
Thanks Lisa
Regards,