Re: MAX MIN vs IF

Originally Posted by
netstranger.nz
Hi Guys
as the syntax seems upside down TO ME.?
Just understand it as MIN or MAX of the two values ...
BTW ... your use here seems a bit strange ... @ the speed you run Why not make use of a Hardware comparator or an ADC measure ???
the 1.5v trip limit of the inputs is ... not so precise ( absolute value ) ... especially if some capacitive circuitry around ... added to the high slew-rate of your signals, the result is quite predictable ... 
The difference in time you see is due to the different working values comparing macros ... just have a look to the produced .asm, and you'll understand that ...
AND .. YES, MIN and MAX commands are slower than IF-THEN ...
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Bookmarks