FireFly 2011: Arduino Mega + SSC-32, Wii Nunchuk, preset walking sequences

From Electronics\Hexapod\Arduino sketches 2011-2012\hexapod_oud (banner 'Version 3.0').
This commit is contained in:
mangavalk committed 2011-10-09 15:56:03 +02:00
1 parent 160b6ec36a
commit fe472bfce9
16 files changed
+1079

No files matched your search

@@ -0,0 +1,23 @@
// Rotation.cpp
#include "Rotation.h"
void Rotation::getData(int ix[6], int iy[6], int iz[6])
{
for (int i=0; i<6; i++)
{
x[i] = ix[i];
y[i] = iy[i];
z[i] = iz[i];
}
}
int NewX, NewY;
void rotate (int x, int y, int angel)
{
NewY = x * sin(radians(angel)) + y * cos(radians(angel));
NewX = x * cos(radians(angel)) - y * sin(radians(angel));
}