process_result.h 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. #ifndef _PRECESS_RESULT_H_
  2. #define _PRECESS_RESULT_H_
  3. #include "main.h"
  4. #include "motion_config.h"
  5. #include "host_shoes.h"
  6. #include "slave_shoes.h"
  7. #include "send_data.h"
  8. #if SH_NUMBER == 1
  9. float accBias[3] = {-0.0116f, 0.0122f, -0.0172f,};
  10. float accScale[3] = {1.0015f, 1.0010f, 0.9884f,};
  11. //float magBias[3] = { 377.7242f, 111.6333f, 258.3704f};
  12. float magBias[3] = { 521.4416f, 311.3539f, 203.1051f};
  13. float magScale[3] = {0.0040f, 0.0038f, 0.0037,};
  14. #elif SH_NUMBER == 2
  15. float accBias[3] = {-0.0143f, 0.0020f, -0.0295f};
  16. float accScale[3] = {1.0026f, 1.0017f, 0.9876f};
  17. float magBias[3] = {208.19076f, 676.30954f, -1314.16369f};
  18. float magScale[3] = {0.0040f, 0.0038f, 0.0039f};
  19. #elif SH_NUMBER == 3
  20. float accBias[3] = {-0.0073f, 0.0112f, -0.0120f,};
  21. float accScale[3] = {1.0011f, 0.9997f, 0.9932f};
  22. //float magBias[3] = { -91.4046f, -173.7336f, -16.4311f};
  23. //float magBias[3] = { -33.7960f, -182.2888f, -72.0429f};
  24. //float magBias[3] = { 98.2326f, -244.3920f, -112.4380f};
  25. float magBias[3] = { -2394.65484f, 6539.55844f, -1429.03f};
  26. float magScale[3] = { 0.004f , 0.0038f , 0.0037f,};
  27. #elif SH_NUMBER == 4
  28. float accBias[3] = { -0.0000f, 0.0096f, -0.0308f};
  29. float accScale[3] = {1.0002f, 1.0009f, 0.9910f};
  30. //float magBias[3] = {29.8783f, 142.8769f, -149.3421f};
  31. //float magBias[3] = { 18.2790f, 93.3995f, -146.4823};
  32. //float magBias[3] = { -15.8519f, 70.4827f, -128.3174f};
  33. float magBias[3] = {-72.9602f, -149.2124f, -154.5789f};
  34. float magScale[3] = { 0.0040f, 0.0040f, 0.0040f};
  35. #elif SH_NUMBER == 5
  36. float accBias[3] = { 0.0208f, 0.0066f, -0.0281f,};
  37. float accScale[3] = {1.0011f, 1.0004f, 0.9955f,};
  38. float magBias[3] = { 63.2058f , 113.6578f , -539.3837f};
  39. float magScale[3] = {0.0038f , 0.0038f , 0.0037f,};
  40. #elif SH_NUMBER == 6
  41. float accBias[3] = { -0.0173f, 0.0078f, -0.1042f};
  42. float accScale[3] = {1.0015f, 1.0002f, 0.9861f};
  43. float magBias[3] = {97.0186f, 685.1305f, -513.0043f};
  44. float magScale[3] = {0.0038f, 0.0039f, 0.0037f};
  45. #elif SH_NUMBER == 7
  46. float accBias[3] = { 0.0208f, 0.0066f, -0.0281f,};
  47. float accScale[3] = {1.0011f, 1.0004f, 0.9955f,};
  48. float magBias[3] = { 63.2058f , 113.6578f , -539.3837f};
  49. float magScale[3] = {0.0038f , 0.0038f , 0.0037f,};
  50. #elif SH_NUMBER == 8
  51. float accBias[3] = { -0.0055f, 0.0097f, -0.0550f};
  52. float accScale[3] = {1.0004f, 0.9991f, 1.0000f};
  53. float magBias[3] = {-80.7255f, 715.1156f, -870.1321f};
  54. float magScale[3] = {0.0037f, 0.0038f, 0.0036f};
  55. #elif SH_NUMBER == 9
  56. float accBias[3] = {-0.0178f, 0.0056f, -0.1022f};
  57. float accScale[3] = {1.0005f, 1.0017f, 0.9880f};
  58. float magBias[3] = {-86.6536f, 341.2955f, -674.9064f};
  59. float magScale[3] = {0.0039f, 0.0039f , 0.0040f,};
  60. #elif SH_NUMBER == 10
  61. float accBias[3] = { -0.0069f , 0.0141f , -0.0498f};
  62. float accScale[3] = {1.0007f , 1.0031f , 0.9970f};
  63. float magBias[3] = { -77.8889f, 482.7083f, -616.4837f};
  64. float magScale[3] = { 0.0040f, 0.0040f, 0.0039f,};
  65. #elif SH_NUMBER == 11
  66. float accBias[3] = {0.0149f, 0.0208f, -0.0272f};
  67. float accScale[3] = {1.0010f , 1.0008f , 0.9969f};
  68. //float magBias[3] = { -66.0267f, 473.8725f, -529.6988f};
  69. //float magScale[3] = {0.0040f, 0.0040f, 0.0040f};
  70. float magBias[3] = { -79.0751f, 471.0133f, -600.3712f};
  71. float magScale[3] = {0.0040f, 0.0041f , 0.0039f};
  72. #elif SH_NUMBER == 12
  73. float accBias[3] = {0.0025f, 0.0086f, -0.0016f,};
  74. float accScale[3] = {1.0007f, 1.0009f, 0.9948f,};
  75. //float magBias[3] = {54.5925f, 293.4265f, -684.2667f,};
  76. float magBias[3] = {36.3369f, 314.0196f, -709.6340f,};
  77. float magScale[3] = {0.0040f, 0.0040f, 0.0041f,};
  78. #elif SH_NUMBER == 13
  79. float accBias[3] = {0.0063f, 0.0053f, 0.0138f,};
  80. float accScale[3] = {0.9993f, 1.0022f, 0.9883f,};
  81. float magBias[3] = {292.1026f, 633.6321f, -664.0924f,};
  82. float magScale[3] = {0.0039f, 0.0039f, 0.0037f};
  83. #elif SH_NUMBER == 14
  84. float accBias[3] = {0.0244f, 0.0082f, 0.0898f,};
  85. float accScale[3] = {0.9992f, 1.0024f, 0.9848f,};
  86. float magBias[3] = {82.3285f, 418.0601f, -636.9080f};
  87. float magScale[3] = {0.0041f , 0.0042f, 0.0040f};
  88. #elif SH_NUMBER == 15
  89. float accBias[3] = {-0.0199f , 0.0149f , -0.0832f,};
  90. float accScale[3] = {1.0006f , 1.0012f , 0.9883f,};
  91. float magBias[3] = { -83.9929f, 378.1395f, -683.2781f};
  92. float magScale[3] = {0.0039f, 0.0040f, 0.0041f};
  93. #elif SH_NUMBER == 16
  94. float accBias[3] = {-0.0062f, 0.0176f, -0.0461f};
  95. float accScale[3] = {1.0006f, 1.0030f, 0.9965f};
  96. float magBias[3] = {-66.5185f, 497.9997f, -618.6814f};
  97. float magScale[3] = {0.0040f, 0.0041f, 0.0040f};
  98. #elif SH_NUMBER == 17
  99. float accBias[3] = {0.0201f, 0.0207f, 0.1268f};
  100. float accScale[3] = {0.9984f, 1.0027f, 0.9927f};
  101. float magBias[3] = {1238.45506f, 553.76179f, -466.85981f};
  102. float magScale[3] = {0.0041f, 0.0045f, 0.0043f};
  103. #elif SH_NUMBER == 18
  104. float accBias[3] = {-0.0338f, 0.0088f, -0.0118f};
  105. float accScale[3] = { 0.9995f, 1.0009f, 0.9926f};
  106. float magBias[3] = {1471.773663f, 551.73478f, -348.20543f};
  107. float magScale[3] = {0.0041f, 0.0046f, 0.0043f};
  108. #elif SH_NUMBER == 19
  109. float accBias[3] = {-0.017644f, 0.0044866f, -0.048548f};
  110. float accScale[3] = { 1.0011f, 1.0001f, 0.9911f};
  111. float magBias[3] = {294.8f, 1054.5f, -254.15f};
  112. float magScale[3] = {0.004482f, 0.0041116f, 0.004236f};
  113. #elif SH_NUMBER == 20
  114. float accBias[3] = {-0.02376f, 0.01068f, 0.069101f};
  115. float accScale[3] = { 0.99977f, 1.0007f, 0.99655f};
  116. float magBias[3] = { 285.12f, 1218.7f, -416.98f};
  117. float magScale[3] = {0.004411f, 0.0040035f, 0.0041864f};
  118. #elif SH_NUMBER == 21
  119. float accBias[3] = { 0.0176f, 0.0217f, 0.1217f};
  120. float accScale[3] = { 1.0032f, 1.0025f, 0.9973f};
  121. float magBias[3] = {357.05161f, 1111.658506f, -434.721060f};
  122. float magScale[3] = {0.0044f, 0.004f, 0.0042f};
  123. #elif SH_NUMBER == 22
  124. float accBias[3] = { -0.0371f, 0.0082f, -0.0177f};
  125. float accScale[3] = { 1.0032f, 1.0025f, 0.9973f};
  126. float magBias[3] = {443.781061f, 1401.779316f, -264.01198f};
  127. float magScale[3] = {0.0046f, 0.0041f, 0.0043f};
  128. #elif SH_NUMBER == 23
  129. float accBias[3] = { -0.0294f, 0.0088f, 0.0213f};
  130. float accScale[3] = { 1.0037f, 0.9976f, 0.9940f};
  131. float magBias[3] = {508.4243192f, 1189.075561f, -373.32054f};
  132. float magScale[3] = {0.0046f, 0.0042f, 0.0041};
  133. #elif SH_NUMBER == 24
  134. float accBias[3] = { -0.0119f, -0.0012f, 0.0454f};
  135. float accScale[3] = { 1.0002f, 0.9956f, 1.0038f};
  136. float magBias[3] = {726.44178f, 710.183522f, -510.867688f};
  137. float magScale[3] = {0.0045f, 0.0041f, 0.0042f};
  138. #elif SH_NUMBER == 25
  139. float accBias[3] = { -0.0065f, 0.0027f, 0.0271f};
  140. float accScale[3] = { 1.0005f, 0.9992f, 0.9952f};
  141. float magBias[3] = {213.41965895f, 1127.6071397f, -188.07170366f};
  142. float magScale[3] = {0.0044f, 0.004f, 0.0041f};
  143. #elif SH_NUMBER == 26
  144. float accBias[3] = { -0.0132f, 0.0037f, -0.0090f};
  145. float accScale[3] = { 1.0022f, 1.0008f, 0.9946f};
  146. float magBias[3] = {705.2909f, 888.2859f, -162.9662f};
  147. float magScale[3] = { 0.0045f, 0.0041f, 0.0043f};
  148. #endif
  149. #ifdef WHITE_SH0
  150. #if IS_HOST
  151. float accBias[3] = { -0.0055f, 0.0114f, -0.0075f};
  152. float accScale[3] = {1.0011f, 0.9997f, 0.9930f};
  153. float magBias[3] = { 98.5793f, -199.4005f, -188.8333f};
  154. float magScale[3] = {0.0040f, 0.0040f, 0.0037f};
  155. #else
  156. /* slave*/
  157. float accBias[3] = { 0.0009f, 0.0062f, -0.0224f};
  158. float accScale[3] = {1.0000f, 1.0006f, 0.9913f};
  159. float magBias[3] = { -75.9748f, 80.7247, -134.6379f};
  160. float magScale[3] = { 0.0039f, 0.0037f, 0.0037f};
  161. #endif
  162. #elif defined BLUE_SHO
  163. #if IS_HOST
  164. float accBias[3] = { -0.0118f , 0.0130f , -0.0026f};
  165. float accScale[3] = {1.0015f , 1.0011f , 0.9896f};
  166. float magBias[3] = { 569.5943f , 271.8484f , 298.8276f};
  167. float magScale[3] = {0.0040f , 0.0037f , 0.0039f};
  168. #else
  169. /* slave*/
  170. float accBias[3] = {-0.0299f, 0.0114f , -0.0716f};
  171. float accScale[3] = {1.0017f, 1.0023f, 0.9884f};
  172. float magBias[3] = {324.02837f, 599.89072f, -1323.1148f};
  173. float magScale[3] = {0.0039f, 0.0037f, 0.0037f};
  174. #endif
  175. #endif
  176. #endif