I've been using the trig3places.h include file to compute Sjne and Cosine values. It works great.
The Help file says that the 'X' in cosX and Sinx should be integers.
Recently I had to compute the sine and cosines of values greater 32767 so I dimensioned X as a word variable and trig3places.h seemed to work.
Does anyone know if there is some upper limit on the value of X? Can it be any word or long Variable?
I realize with word or long variables, negative angles can't be computed.
If Sine and Cosine work with word and/or long variables it would nice if the Help File was updated to reflect this.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've been using the trig3places.h include file to compute Sjne and Cosine values. It works great.
The Help file says that the 'X' in cosX and Sinx should be integers.
Recently I had to compute the sine and cosines of values greater 32767 so I dimensioned X as a word variable and trig3places.h seemed to work.
Does anyone know if there is some upper limit on the value of X? Can it be any word or long Variable?
I realize with word or long variables, negative angles can't be computed.
If Sine and Cosine work with word and/or long variables it would nice if the Help File was updated to reflect this.
I have reviewed the code.
Looking at the code again. The functions accept and return integers.
Review your results and if all is OK then press on. :-)