19 lines
668 B
C
19 lines
668 B
C
#ifndef MATHS_H
|
|
#define MATHS_H
|
|
|
|
#include "turret.h"
|
|
|
|
double degToRad(double deg);
|
|
double radToDeg(double rad);
|
|
void radToStep(Turret::StepRatio stepRatio, vec2<double> angle,
|
|
vec2<long> &step);
|
|
void stepToRad(Turret::StepRatio stepRatio, vec2<long> step,
|
|
vec2<double> &angle);
|
|
void cartesianToPolar(Turret::StepRatio stepRatio, Turret::Offset offset,
|
|
vec2<long> zero, vec3<double> position, vec2<long> &step);
|
|
void polarToCartesian(Turret::StepRatio stepRatio, Turret::Offset offset,
|
|
vec3<long> current, vec2<long> zero, vec2<long> step,
|
|
vec3<double> &position);
|
|
|
|
#endif
|