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 CCS Technical Support

Someone knows what is a "simple hold" function?

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



Joined: 29 Sep 2010
Posts: 73
Location: Brazil

View user's profile Send private message MSN Messenger

Someone knows what is a "simple hold" function?
PostPosted: Sun Dec 05, 2010 11:24 pm     Reply with quote

Well, some days ago, I was making an program to give the max value of 2 analog inputs. So I looked at the examples folder and find 1 example.

Basically you read the analog channel and compare with your predefined variable to see if it is bigger. Ok! It worked.

_BUT_ my teacher tell me to do it with another way. Since my analog input has 60Hz, so an entire cycle has 1.6ms. He told me to make a read of the analog channel 120 times per cycle. Ok, this is not a problem. But he wants that I take all the 120 values and store in a table and use a function called "simple hold" to find the bigger value. But I do not know with function is that.

Someone can help me?

thanks
gpsmikey



Joined: 16 Nov 2010
Posts: 588
Location: Kirkland, WA

View user's profile Send private message

PostPosted: Sun Dec 05, 2010 11:48 pm     Reply with quote

Greetings !! I have not heard of a "simple hold" before. My best guess is something got lost in translation and the term was "sample and hold" -- see this wikipedia definition and see if that is what he is talking about.
http://en.wikipedia.org/wiki/Sample_and_hold

mikey
_________________
mikey
-- you can't have too many gadgets or too much disk space !
old engineering saying: 1+1 = 3 for sufficiently large values of 1 or small values of 3
Gabriel



Joined: 03 Aug 2009
Posts: 1067
Location: Panama

View user's profile Send private message

PostPosted: Mon Dec 06, 2010 8:59 am     Reply with quote

I think he just meant a function that stores all the values in an array
for later comparison.


g.
_________________
CCS PCM 5.078 & CCS PCH 5.093
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