Jump to content

Arduino + KSP_Serial_IO : "Odysseus"


Sputnix

Recommended Posts

This page really covers a lot of the details of how to do it right. Have fun! ;)

http://www.dairiki.org/hammond/cable-lacing-howto/

Pretty impressive techniques there, huh? :0.0:

That's awesome. I never knew there was such a 'standard' to follow.

I'm going to keep this in mind for future projects, thank you :)

BEAUTIFUL! I was thinking of doing something very similar for a mech game. This is brilliant.

Thanks :)

A mech game would be awesome fun to do. Did you see the full-on enclosure this guy built?

The BSBB -- Big Steel Battalion Box. I'd love to do similar for Kerbal (and Mulbin is working on one too!).

Also, a good reference for Mech-style games would be the old xbox game Steel Battalion which came with specific controllers.

Another style I contemplated (and originally started off designing) was switches around the monitor, similar to this guys.

I opted for a more portable version in the end (but I haven't given up my idea of around-the-monitor style just yet ;)

Link to comment
Share on other sites

Just a brief update -- I've added some temporary [though possibly may turn into permanent] labels.

I was looking for some coloured label tape for my existing labeller, when I saw that they still sold friction / embossing labellers at Officeworks (Australia's stationary warehouse).

So I got one (cheaper than the labels for my electronic / thermal labeller) and used it. I thought it gave a more kerbal-esque appearance :D

Label-Full.png

I also used the last of my electronic / thermal labeller with clear tape to label the annunciator panel. I had just enough!

Label-Anunn.png

The last two spots are open for some warning / feedback that have yet to be determined.

(Seriously, if anyone has any ideas, feel free to provide some suggestions!)

Still to do

- I've still got to wire up / label the 8 red buttons. Although these were originally 'action group' buttons, I'm in the process of rethinking that.

(They're most likely going to wind up being that anyway)

- I've got to code in the Master Alarm reaction

- Probably tidy up the rats nest inside

- Have to find a way to show proper 'times' as Days / Hours / Minutes / Seconds.

I plan on coding it to not display seconds as soon as it hits 100 days; due to lack of space.

At that point, I might defer some of the information to the LCD;

As a side note - trying to display too much data on the LCD will cause the system to choke. When I was doing the parachute safe video, I originally had the four values you see, along with the additional 6 or so. The poor little 16mhz system just couldn't keep up! It could also be the refresh rate; but I'd hazard that it was having trouble processing all that data (since the arduino is storing values, casting them, then outputting them - it's a lot to do!).

Edited by Sputnix
Link to comment
Share on other sites

I love those embossed labels. Thought about using them on my controller as well. Ended up etching labels instead, but almost everything I own now has an embossed tag. They work really well for your hardware too. :)

Link to comment
Share on other sites

I love those embossed labels. Thought about using them on my controller as well. Ended up etching labels instead, but almost everything I own now has an embossed tag. They work really well for your hardware too. :)

Thank you! I think they're quite fitting too.

Originally I had decals I thought I would attach; but as you point out, given the 'look' the embossed labels work really nicely.

If I was doing something like Mulbin, then I'd probably pay closer attention to period-specific labelling (which is what I originally wanted).

I also just managed to get the Master Alarm to fire as necessary :)

Link to comment
Share on other sites

Oh wow, that master alarm is perfect. My annunciator panel is still half-built, and I may end up borrowing your ideas. :)

I don't recall how your LCD panel is hooked up, but driving it from an arduino is always going to be a strain. Did you end up drawing boxes over the previous text before writing new values? Would that be faster if instead you write a string of spaces over the top of the previous string?

Link to comment
Share on other sites

Oh wow, that master alarm is perfect. My annunciator panel is still half-built, and I may end up borrowing your ideas. :)

I don't recall how your LCD panel is hooked up, but driving it from an arduino is always going to be a strain. Did you end up drawing boxes over the previous text before writing new values? Would that be faster if instead you write a string of spaces over the top of the previous string?

Feel free to :) I mean, I'm just borrowing the idea from the Apollo CM's 'Caution and Warning System'. :D

[Which in turn is borrowed from the aviation world... ]

The LCD is wired up to the hardware SPI lines of the Mega;

This minimises the lag somewhat (from what I read, compared to digitally assigning pins).

Yeah, I'm using little black boxes;

I'm not sure if the 'string of spaces' would be quicker / less intensive. I did try it once; but because I'm converting the data to a string, storing it to an array, and then printing out that value, it's all very convoluted. When I tried earlier on to cover it all with blank spaces, I couldn't quite get it working. Admittedly, I was still very noobish with the Arduino 'C' code at the time too, so I might revisit it and try it again.

I really dislike the way it deals with datatypes.

Link to comment
Share on other sites

Wow, that is really impressive. If you don't mind me asking where did you get those leds for the warning lights?

Thank you :)

RE: Warning Light LEDs

I got them from a local electrical store; they have a small room dedicated to surplus / cheap stuff.

You can find some on eBay from here; and their images have the model number attached - LD706YY.

Some googling will yield results for that model, such as data / spec sheet.

You can also find similar lights; just look for 'panel lamp' / 'panel light' / 'indicator lamp' or something to that effect. :)

Link to comment
Share on other sites

http://www.digikey.com/product-search/en?pv207=680&FV=fff40008%2Cfff801c0&k=hlmp+rectangle&mnonly=0&newproducts=0&ColumnSort=0&page=1&stock=1&quantity=0&ptm=0&fid=0&pageSize=100

This is a selection of new LED bars. You can get them in a variety of colors and sizes. I filtered by what's in stock, and what's in a wide package. These are all 19x9 mm (approximately). THey have 8 LED elements inside, so you get a VERY uniform illumination. You can get them in red, green and yellow, and the red and green ones are the cheapest. There's also a good price break at >10 units. Red and green units, are about $20 USD for 10, and the Yellows are about $30 USD for ten. I actually salvage these from medical equipment and photocopiers very often... as annunciator style indicators, illuminating a block of text! I picked up a circuit board from a surplus store for $0.75 USD... LESS than a dollar... that has 4 1x4 LED and 3 1x2 LED half width LED bars. The ones I linked are 2x4 LED bars.

Edited by richfiles
Link to comment
Share on other sites

http://www.digikey.com/product-search/en?pv207=680&FV=fff40008%2Cfff801c0&k=hlmp+rectangle&mnonly=0&newproducts=0&ColumnSort=0&page=1&stock=1&quantity=0&ptm=0&fid=0&pageSize=100

This is a selection of new LED bars. You can get them in a variety of colors and sizes. I filtered by what's in stock, and what's in a wide package. These are all 19x9 mm (approximately). THey have 8 LED elements inside, so you get a VERY uniform illumination. You can get them in red, green and yellow, and the red and green ones are the cheapest. There's also a good price break at >10 units. Red and green units, are about $20 USD for 10, and the Yellows are about $30 USD for ten. I actually salvage these from medical equipment and photocopiers very often... as annunciator style indicators, illuminating a block of text! I picked up a circuit board from a surplus store for $0.75 USD... LESS than a dollar... that has 4 1x4 LED and 3 1x2 LED half width LED bars. The ones I linked are 2x4 LED bars.

Thanks for that.

You USA guys get all the perks! :P

I've seen those around (I had a couple back when I was a kid, no idea what happened to them); they'd be perfect too! They'd be awesome to get more onto an annunciator panel.

I either need a bigger display, or smaller lights :)

Link to comment
Share on other sites

You USA guys get all the perks! :P

Digikey does do international shipping, so if you get yourself a good chunky order, you might be able to offset the cost. Either way, depending on what country you're in, you might have alternatives. I think I saw an Australian ebay listing, so using that as an example, Digikey charges a flat shipping charge of $34 AUD on all orders of less than $200 AUD. Free shipping is offered for all orders of $200 AUD and greater. It just depends on location and size of order. If you snag several items from them, that one 34 AUD charge might end up less that the cost of shipping several different things on ebay.

Or not! :rolleyes:

YOu just have to do the math and find out what works best for you. Consider though, that it's often possible to search for parts there, and then pick out manufacturer part numbers, to see if they are available locally from a closer distributer.

Link to comment
Share on other sites

Now that is amazing... I've got one operational suggestion, however - instead of the Periapsis and/or Apoapsis screen showing negatives or NaNs if on an escape/suborbital trajectory, I'd suggest programming them to show something like N/A instead.

-FCI

Link to comment
Share on other sites

Now that is amazing... I've got one operational suggestion, however - instead of the Periapsis and/or Apoapsis screen showing negatives or NaNs if on an escape/suborbital trajectory, I'd suggest programming them to show something like N/A instead.

-FCI

Thank you :)

Yes, that's the stuff I'm 'fine tuning' at the moment.

I did a test recently (was testing the mission times / time to Ap and Pe) and I managed to escape kerbin...

And the numbers I got on the Ap and Pe were - well - mostly indecipherable :P

I'm in the process of working out conditions based on the numbers, and putting in some decimal points to denote different orders of magnitude.

But I definitely like your idea for negative or NaNs values.

Thanks for the input! :)

Edited by Sputnix
Link to comment
Share on other sites

  • 4 weeks later...
Updated your pic on the megathread... looks very, very pretty now it's all lit up ;)

Haha, thanks for that :)

I was going to upload a newer pic, and call it the same you had linked to make it easier for you :)

But you beat me to it! ;)

Link to comment
Share on other sites

  • 7 months later...

Amazing work you've done here! You were among the people that made me think "sure, let's do it too!" so I did start a KSP controller (of which I'll put pictures soon).

It was a great occasion to learn Arduino. I still have some difficulties (we don't have too much programming in architecture studies :P) but things are slowly moving into place.

I saw that you might plan on releasing your arduino code here, that would be amazing for me! I spent the whole day fighting with 8 7 digit displays and I came to something, but I'd like to see another kerbonaut's approach.

Keep up the good work!

Link to comment
Share on other sites

  • 1 month later...

Thanks for the kind words, @Marcells:) [and sorry for the delay -- I didn't get a notification, and I was still trying to get back into the swing of things with forum-ing again, and get my head around this new forum style / layout].

I have neglected the forums and my controller for a little bit because of work / life commitments, and then the issues of incompatibility, and although I can kind of hack my way through various pieces of code, could never quite get the hang of the plugin stuff...

Thankfully (luckily) @zitronen has recently worked out most of the issues with the 1.1 release of KSP.

I still intend on releasing the code -- but I think I want to refine it a bit; but before that, I'll probably release some videos on the process of designing and then building a controller (as a lot of the stuff I've learnt, both from myself and by talking to others) is something I think many others may find useful / beneficial.

Is there a specific issue you've been having issues with? I'm actually using a customised library from @AmeliaEatyaheart for my 7-segment displays. Unfortunately, word is you can only a maximum of 6 displays inline. But I found that to be enough; alternatively, you can get some LCD screens and do a 'glass cockpit': possibly not as cool / visually effective - but a lot more practical and easily upgrade-able / modifiable. 

Be sure to start your own thread here, and share your own progress - trials, tribulations, etc. That way if you have a problem, we can help you out, and it will be documented for others to see too :)

Build wild! 

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...