Jump to content

Sputnix

Members
  • Posts

    234
  • Joined

  • Last visited

Everything posted by Sputnix

  1. I'm not aware of your background, so I'll answer this to try make sure all readers understand Each line of code is a series of instructions to be interpreted by the processor. Each cycle of the processor (clock-tick) allows for a certain amount of cycles. Hertz (Hz) = 1 cycle per second; 1 mega hertz (MHz) is a million cycles per second. Thus, the Mega has 16 million cycles per second, the Due 84 million. I'm not sure of the specifics, but each instruction (line or lines of code) takes a certain amount of cycles to process; I know that 16 million cycles per second seems a lot (and it is) - when you start doing a lot of mathematical based functions, or 'casting' (changing the nature of the variables) it gets quite processor intensive. I remember doing stuff in my Computer Architecture class where we would manually do the 'processing' of a single part of an instruction set. There's a lot going on under the hood! On my controller I have a small LCD display, along with 6x 7-segment displays, along with the various other IO, and 'checking' to see if lights need to be lit, etc. Most of the power is going to displaying, and doing tricky things with the values to make them show up as I need to so that they're meaningful to me. I've hit choke points already where I've had to slow down the refresh rate (from .2 of a second, to .3) and also increase the baud rate of the serial packets because it just wasn't keeping up. Now sure, I'll be the first to admit - my code is not lean. I'm not a computer scientist (though sometimes I wish I was! ), so I don't quite know the intricacies of the effects of using if loops instead of while loops, etc. So perhaps there is a way to get the code 'leaner' to make more efficient use of the Mega processor (and honestly - you have sparked an inquisitive interest in me to do so -- Thank you! ). In everything I've read though, the more 'number crunching' you are doing (I suppose that goes also for casting / converting, etc) - the more clock speed you need. @zitronen was super smart with his example of the 'all in one' display with the dial. Because that only shows the information based on the selected screen. So all other maths can be 'hidden' and not processed unless on-screen (unless it is still doing it in the background...) So I suppose, at the end of the day, it depends what you're trying to achieve with the controller, and what you're pushing it to do. It's all fun and experimentation! But I figure if I can get 5x the power, I might be able to do a few more cooler things - just opens up the opportunities Another way is to use more processors; some people are using multiple processors in their builds. So a single Mega (usually) is the 'gate keeper' shuttling instructions between the computer and then other arduinos (via serial connection), where the processing of the instructions is done on those devices. This means the mega is just pushing data packets to them, and then the sub-processors can do all the maths and creative trickery like visualising navigation balls (eh, @stibbons ). Remember: a 600 mhz computer would run Windows 98 or Windows 2000 very nicely. It would struggle with anything newer (XP, passable; Vista / 7 / 10 - borderline). The stuff going on in the background has increased. Likewise, I think once we try to do more and more with our controllers, we start wanting needing more power! In fact, what I'm looking at doing is a combination of both. Use a Due as the 'gatekeeper', do some of the LCD stuff on it, but then shuttle off instructions to sub processors (either a couple Mega's, or maybe Uno's - not sure yet).
  2. It's the best way to learn - I find - by focusing on a project that 'forces' the learning If you're ever wanting some help with the code - feel free to PM me. I've helped a couple other people out on the forums; I've been inactive for a while, but wanting to jump back in and get involved again I think your background will put you in good stead. One possible suggestion: in the lunar lander (or was it the command module - I can't recall) -- anyway, there were duplicate controls; so that people either side could activate things. This becomes somewhat problematic with the programming, but it could allow a nice way to fill the void. Of course, that means twice the cost (in switches, buttons, labels, wires, etc). You could also possibly put some nicely designed signage / posters up reminding you of the steps to key things (ie. orbital rendevous. That's something I keep having to look back on, as I don't play nearly enough KSP to remember between the 6 months I play )
  3. I love this. So amazing (and such progress too!). I'm incredibly jealous of people like you that have the space to build something like this! I think it's amazing that you're taking the opportunity and doing it! When I conceived of a 'cockpit' idea, I considered having the entire thing move. Simple tilt (lying down on planet earth, and slowly putting you up to a normal sitting position once in space) - just to give the sense of lying + gravity pushing you down. Of course that would be its own engineering nightmare - but would be so awesome! Definitely gonna keep following this thread! Keep up the amazing work! Oh, and I love how so many people have cats (which appear in build logs) Given there's actually a fairly limited amount of 'controls' in game (as opposed to real life) will you just leave most of the cockpit panels empty, or will you duplicate controls around the place?
  4. I've just found it inconsistently happens when I place vehicle on launch from my list of saved vehicles. :/ so, editing the vehicle, and retracting gears seems to help (why the hell would I have set it to extend at launch?) Thanks @stibbons
  5. I think we've discovered a pattern with @zitronen's sleep patterns There's an old saying: "Fool me once - shame on you; fool me two or three times - shame on me". Yeah, I was confused with the (2) after the file name in my downloads folder... but figured I must've accidentally clicked it twice It's all good Anyway -- onto the testing: x64 & x32 - working no problems. All the switches respond as needed, all outputs seem to be working fine. I have noticed that going to the pad, the landing gears are extended (active) by default (even though all switches are 'off'). When I unplug the controller, this seems to happen too; can anyone else confirm this before I post a bug to squad? (Seems unrelated to KSPSerialIO)
  6. You're right. It is. Unless you're doing a lot of mathematics and conversions On v2, I am looking at using LCDs and trying to do a few other more tricky / clever things. So I figure the more power I can throw at it, the less issues. Right? RIGHT?!
  7. Crikey! and I thought my move to a Due was overkill!
  8. Doing tests; get comms before launch pad loads (blinky lights) but that's all. I haven't done an update to my code since 1.1; but I didn't think there was anything new introduced to the Arduino side of things; [A quick check of the code supports this] Log file stuff
  9. So, I'm in the process of embarking on a v2 controller... (madness, I know... v1 isn't even completed fully! ) This version I was going to use a Due, with serial links to two Mega's to try offload some of the processing, and try leverage the Due's 84mhz processor. Would the Due's open up more possibility, or would we still hit limits? [I mean, we'll always hit a limit somewhere - but would targeting the Due be feasible] I'm just going off the specs of the two: DUE Mega2560 Flash Memory 512 KB all available for the user applications SRAM 96 KB (two banks: 64KB and 32KB) Clock Speed 84 MHz Flash Memory 256 KB of which 8 KB used by bootloader SRAM 8 KB EEPROM 4 KB Clock Speed 16 MHz
  10. Only if you're mixing paints; If I recall correctly, lights are a different beast
  11. I remember prying LEDs off boards from old TVs and VCRs as a kid... Best way to master the 'iron! I'm actually jealous of your collection of bar LEDs How did you find those parts? I often think it'd be awesome to strip down things like Medical equipment (cos they tend to have really ridiculously awesome stuff) -- but I don't have the faintest idea where to find these things.
  12. Man... you zone out for a couple days and this place blows up! Exciting to see! @stibbons -- I got myself a couple of these a few months back for controller V2 (Which I'll reveal shortly); people should check them out. Not necessary by any means, but quite a neat way to daisy-chain Shift Registers: http://www.ebay.com.au/itm/pcb-quad-shift-register-breakout-board-74hc595-microcontollers-etc/261669708081?hash=item3cecbae131 @richfiles & @Antipaten -- I think the 'back in my day' stories are great anecdotes; and it definitely shows in the information and knowledge you have to share with this small but bustling community - don't ever stop or feel bad about those moments @Pvt. KASA -- I've sent you a PM!
  13. There's some neat tools out there for generating gears / cogs for 3D printing; some over on tinkercad (Web-based 3D modelling), also a few SCAD stuff flying around.
  14. Learning is the main objective of anything, especially kerbal-related Now, that huge 18mm(?) MDF on the base, is that what you're carving the panel out of, or is that just there to sit your piece of wood on?
  15. You should be able to find what you need here (including a small guide / wiki) https://github.com/unixunion/KSPSerialIO [Web archive of the original kerbalstuff site here] A word of warning though -- that's some pretty old code; @zitronen had issues adapting to v1.1 of the game (not sure which version you've got going). There's a good chance that it may not work. But not being in Mac-land, I cannot confirm this.
  16. Ah yes, got you. I completely agree. I've found it an adequate solution - but that feedback you talk of would be so darn nice! I'll be following your progress! Definitely interested to see what you come up with
  17. Heya, Sorry for the delay in this - but I wound up getting myself a 3D Connexion Space Navigator, after I saw similar discussions on the forum about it. They're designed more for navigation in 3D modelling environments, but it works great in KSP for translation control. And it works just as you'd expect. What's more, from what I understand, an early version was used on Columbia (Space shuttle) to control the arm. It's pretty much plug-and-play (once you install the drivers). All you have to do is hit 'scroll lock' to enable / disable the 3D mouse from being used for translation controls. Not sure if this defeats the idea of what you're wanting to do (ie. build one / DIY) but it does meet the requirements of
  18. Not sure if this is going to help; I had issues with my 7-segment controllers too (6 in total, all connected together). You can read about it here. Or you can query this post I found talking about it. In short: This may help eliminate issues. It did for me! Oh and excellent work It's looking amazing! I would definitely go with a fully mobile simpit (if I had time, money, space) - but a fully enclosed experience is just as good!
  19. That is seriously awesome. I love it. Would work so nicely along with your built controller. In fact, you should just use the novation launchpad just for inputs and use the power of your controller just to display information
  20. Heya! Normally what I do is work out the code to get a single thing working (in this case the LCD). Program it up, make sure it's working with sample code either from official Arduino site or from another geek/arduino site. Then, take that code, and transfer it into the kspSerialio 'demo' program. If the demo is working fine with the bare-bones configuration that @zitronen posted / explained, then you shouldn't have any problems adding the additional code for the LCD.
  21. @richfiles You really are awe-inspiring! Keep up the amazing work. I'm loving seeing you reused older stuff so much. It truly is the spirit of maker-culture! You'll be pro by the time you've done all those edgewise meters! @Antipaten -- I still struggle to find time to play, and make use of my controller! I think I have to re-evalute my work / life / KSP balance xD Welcome @Monsterlunch! We look forward to seeing your progress too! Do create a new thread, and let us know about it. I for one will be watching your development too! Keep up the amazing work all!
  22. That's seriously amazingly beautiful! Loving the work you're doing! Keep it up!
  23. Normally I don't mind challenges being assigned to me... but I'm afraid I'm not sure where to begin with something like this I believe it's @stibbons that's doing (and accomplished - to some degree) this feat of awesomeness
×
×
  • Create New...