CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

servo code

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
MAKInnovation



Joined: 16 Nov 2010
Posts: 61

View user's profile Send private message

servo code
PostPosted: Fri Feb 07, 2014 4:53 am     Reply with quote

Dear PCM programmer;
I am using one of your servo code in my project. link is given below:

http://www.ccsinfo.com/forum/viewtopic.php?t=44328&highlight=

now i have added some more task in my code like clocking, thermo couple reading, frequency reading etc.

when i use "while(!pulse_done_flag);" code of line, the code is become slow. i think it stuck more of the time in reading while loop.

So i made some changes, which is pasted below:
if(!pulse_done_flag); // Wait until pulse is done
{
pulse_done_flag = FALSE;
disable_interrupts(INT_TIMER1);
pulse_high_duration = pulse_high_duration1+PULSE_1MS;
enable_interrupts(INT_TIMER1);
}

With this change, every thing is working normal except the little noise in servo motor. although it does not change its required postion but it jitters some time.
What could be done to make it ok
Regards;
Ashraf
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Fri Feb 07, 2014 1:54 pm     Reply with quote

You should not address a post to me directly if you can help it.
Your problem can be looked at by anyone. I might be busy or going out,
such as right now.
MAKInnovation



Joined: 16 Nov 2010
Posts: 61

View user's profile Send private message

PostPosted: Sun Feb 09, 2014 10:52 pm     Reply with quote

Ok
MAKInnovation



Joined: 16 Nov 2010
Posts: 61

View user's profile Send private message

PostPosted: Sun Feb 09, 2014 11:20 pm     Reply with quote

Sir; I will be care full next time. Thank you for your kind support
Can any one else help me with the servo code?
Ashraf
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group