|
@@ -726,14 +726,15 @@ void GcodeSuite::G26() {
|
726
|
726
|
* All angles are offset by 15 degrees to allow for a smaller table.
|
727
|
727
|
*/
|
728
|
728
|
#define A_CNT ((360 / 30) / 2)
|
729
|
|
- #define _COS(A) (trig_table[((N + A_CNT * 8) % A_CNT)] * (A >= A_CNT ? -1 : 1))
|
|
729
|
+ #define _COS(A) (trig_table[((A + A_CNT * 8) % A_CNT)] * (A >= A_CNT ? -1 : 1))
|
730
|
730
|
#define _SIN(A) (-_COS((A + A_CNT / 2) % (A_CNT * 2)))
|
731
|
731
|
float trig_table[A_CNT];
|
732
|
732
|
for (uint8_t i = 0; i < A_CNT; i++)
|
733
|
733
|
trig_table[i] = INTERSECTION_CIRCLE_RADIUS * cos(RADIANS(i * 30 + 15));
|
734
|
734
|
|
|
735
|
+ mesh_index_pair location;
|
735
|
736
|
do {
|
736
|
|
- const mesh_index_pair location = g26_continue_with_closest
|
|
737
|
+ location = g26_continue_with_closest
|
737
|
738
|
? find_closest_circle_to_print(current_position[X_AXIS], current_position[Y_AXIS])
|
738
|
739
|
: find_closest_circle_to_print(g26_x_pos, g26_y_pos); // Find the closest Mesh Intersection to where we are now.
|
739
|
740
|
|