Jump to content

ZDOF RCS controller (new update 7/1/15)


ZodiaK

Recommended Posts

So I decided to do the thingy. yaaaay

presenting:

The ZodiaK 6DOF RCS translation controller!

GOALS:

1. To produce a 6DOF RCS controller that can connect to my computer and control a craft in KSP

2. To execute my original design to an accurate degree

3. for the overall design to be reminiscent of 1960s era NASA hardware

and thus without further ado-

Part 1: planning things and such and so-on. (4/1/15)

2Ejljjg.png

so this is my design. It will be controlled by a twinning of

1.) A MaKey MaKey board

2.) An Arduino UNO board

respectively, they look like this:

7167036798_9e490c776f.jpgArduinoUno_r2_front450px.jpg

Using the Audino to edit the makey makey's (Henceforth referred to as 'MM') makey_makey_1_4_1.ino file downloaded from GitHub to switch the 'WASDFG' pins to the translation keys 'IJKLHN'. the code for that file looks like this:



/*
/////////////////////////////////////////////////////////////////////////
// KEY MAPPINGS: WHICH KEY MAPS TO WHICH PIN ON THE MAKEY MAKEY BOARD? //
/////////////////////////////////////////////////////////////////////////

- edit the keyCodes array below to change the keys sent by the MaKey MaKey for each input
- the comments tell you which input sends that key (for example, by default 'w' is sent by pin D5)
- change the keys by replacing them. for example, you can replace 'w' with any other individual letter,
number, or symbol on your keyboard
- you can also use codes for other keys such as modifier and function keys (see the
the list of additional key codes at the bottom of this file)

*/

int keyCodes[NUM_INPUTS] = {
// top side of the makey makey board

KEY_UP_ARROW, // up arrow pad
KEY_DOWN_ARROW, // down arrow pad
KEY_LEFT_ARROW, // left arrow pad
KEY_RIGHT_ARROW, // right arrow pad
' ', // space button pad
MOUSE_LEFT, // click button pad

// female header on the back left side

'w', // pin D5
'a', // pin D4
's', // pin D3
'd', // pin D2
'f', // pin D1
'g', // pin D0

// female header on the back right side

MOUSE_MOVE_UP, // pin A5
MOUSE_MOVE_DOWN, // pin A4
MOUSE_MOVE_LEFT, // pin A3
MOUSE_MOVE_RIGHT, // pin A2
MOUSE_LEFT, // pin A1
MOUSE_RIGHT // pin A0
};

///////////////////////////
// NOISE CANCELLATION /////
///////////////////////////
#define SWITCH_THRESHOLD_OFFSET_PERC 5 // number between 1 and 49
// larger value protects better against noise oscillations, but makes it harder to press and release
// recommended values are between 2 and 20
// default value is 5

#define SWITCH_THRESHOLD_CENTER_BIAS 55 // number between 1 and 99
// larger value makes it easier to "release" keys, but harder to "press"
// smaller value makes it easier to "press" keys, but harder to "release"
// recommended values are between 30 and 70
// 50 is "middle" 2.5 volt center
// default value is 55
// 100 = 5V (never use this high)
// 0 = 0 V (never use this low


/////////////////////////
// MOUSE MOTION /////////
/////////////////////////
#define MOUSE_MOTION_UPDATE_INTERVAL 35 // how many loops to wait between
// sending mouse motion updates

#define PIXELS_PER_MOUSE_STEP 4 // a larger number will make the mouse
// move faster

#define MOUSE_RAMP_SCALE 150 // Scaling factor for mouse movement ramping
// Lower = more sensitive mouse movement
// Higher = slower ramping of speed
// 0 = Ramping off

#define MOUSE_MAX_PIXELS 10 // Max pixels per step for mouse movement

/*

///////////////////////////
// ADDITIONAL KEY CODES ///
///////////////////////////

- you can use these codes in the keyCodes array above
- to get modifier keys, function keys, etc

KEY_LEFT_CTRL
KEY_LEFT_SHIFT
KEY_LEFT_ALT
KEY_LEFT_GUI
KEY_RIGHT_CTRL
KEY_RIGHT_SHIFT
KEY_RIGHT_ALT
KEY_RIGHT_GUI

KEY_BACKSPACE
KEY_TAB
KEY_RETURN
KEY_ESC
KEY_INSERT
KEY_DELETE
KEY_PAGE_UP
KEY_PAGE_DOWN
KEY_HOME
KEY_END
KEY_CAPS_LOCK

KEY_F1
KEY_F2
KEY_F3
KEY_F4
KEY_F5
KEY_F6
KEY_F7
KEY_F8
KEY_F9
KEY_F10
KEY_F11
KEY_F12

*/
#include "Arduino.h"

The pins for the keys IJKL will surround the central column of the stick so that when the stick is moved, the earth metal connects to a pin, registering in the MM as a keyboard button press. this will act as the linear translation control

for the forwards and backwards movements, those are controlled from small metal inserts within the column, towards the bottom. another ground piece of ground metal rests between the two pieces of metal so that when the stick is pushed of pulled, it connects, registering as either H or N.

finally, a semi-taught spring is connected at the very bottom of the rod, returning it to its original position after any movements made.

thus, any movement of the stick will be transferred into key-presses of either IJKLH or N. //end log

Part 2: The Trials and tribble-ations of the makey makey (7/1/15)

so yeah.

turns out the reprogramming process wasn't a quick jaunt into the IDE as I had anticipated.

after faffing with drivers and 'Run' and such, we ran in to problems at almost EVERY corner.

and finally, when it seemed to be all peachy, it turns out that I was using the wrong computer for the gob entirely, seeing as our MM was a joylabz production, a now outdated version of the MM and recognized by windows as an Arduino Leonardo.

so we are currently retrying the whole process with my mum's mac computer and are not currently having much luck.

I guess the moral of this encounter with the land of arduino is:

never think it'll be easy, because it won't

I'm sure it'll sort out eventually, but for now no such luck.

EDIT:

IT WORKS!

after 10 gruelling minutes of uploading, we have finally gotten the cod e to compile and sent to the MM.

It may not be easy, but it might just work after all.

O1EscXH.png

// end log

Edited by ZodiaK
Link to comment
Share on other sites

it will be angled at 45 degrees, so it will take um less space in height. also, the model you see is not optimized, I have an optimized sketch on paper witch uses a lot less space.

edit: MM aqquired

Edited by ZodiaK
Link to comment
Share on other sites

Very nice. I look with awe at people building all those cool controller thingies. I am not new to building electronics from scratch, but i havent done that for 25 years... Maybe its a good and easy project to get back into stuff like this... Thank you for sharing.

Link to comment
Share on other sites

Note, as 3D design software, you might want to switch to designspark mechanical:

http://www.rs-online.com/designspark/electronics/eng/page/mechanical

It's a lot better for mechanical design then sketchup. A lot less buggy as well.

that def. looks better than sketchup. I'll take a look at that after this project

Link to comment
Share on other sites

Part 2: The Trials and tribble-ations of the makey makey (7/1/15)

(+rep to whoever names the reference)

so yeah.

turns out the reprogramming process wasn't a quick jaunt into the IDE as I had anticipated.

after faffing with drivers and 'Run' and such, we ran in to problems at almost EVERY corner.

and finally, when it seemed to be all peachy, it turns out that I was using the wrong computer for the gob entirely, seeing as our MM was a joylabz production, a now outdated version of the MM and recognized by windows as an Arduino Leonardo.

so we are currently retrying the whole process with my mum's mac computer and are not currently having much luck.

I guess the moral of this encounter with the land of arduino is:

never think it'll be easy, because it won't

I'm sure it'll sort out eventually, but for now no such luck.

EDIT:

IT WORKS!

after 10 gruelling minutes of uploading, we have finally gotten the cod e to compile and sent to the MM.

It may not be easy, but it might just work after all.

O1EscXH.png

Edited by ZodiaK
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...