brainwagon / angst

An Arduino/Gameduino satellite tracking and display application
http://brainwagon.org/the-arduino-n-gameduino-satellite-tracker/
13 stars 7 forks source link

Derivative motion variable (M2) has wrong formula? #1

Open jcwren opened 6 years ago

jcwren commented 6 years ago

I was looking at the output of your code vs some other code, and noticed that compared to the original G3RUH sources, you apply a different formula to the M2 variable than he does. I'm curious if you corrected an error in his code, or perhaps overlooked what he had done, or perhaps something obvious is eluding me.

In line 241, you have the following code: M2 = RADIANS(getdouble(l1, 33, 43)) ;

However, in G3RUH's code, at line 1370, he uses M2 = M2*2*PI

G3RUH's original code is at http://www.amsat.org/articles/g3ruh/111.html

Another issue that I found while in there is where a float is used instead of a double. Changing it to a double improves the accuracy.

dl9sec commented 5 years ago

I came across the same issue. Going through the code, because the prediction delivers results, which are not the same as my gpredict delivers...