Jump to content

zitronen

Members
  • Posts

    692
  • Joined

  • Last visited

Everything posted by zitronen

  1. You need to change the cfg file, that controls how fast data is sent to the arduino, and therefore how fast your display runs.
  2. @ajden It seems like all you need to do is send serial packets to the screen so not sure why it's not working. Do you have the source code so you can see what is actually happening in "genie.WriteObject()"? If it really is taking too long you can try reducing the refresh rate in the plugin cfg file. You can also use another arduino to handle the display and just send simple serial data from your main arduino to it.
  3. Most of the time you just need to compare the new arduino demo code with yours. Most importantly, check "struct VesselData" and "struct ControlPacket" are the same, and see if you are missing any #defines. If it's not the same, copy to new code to your old code.
  4. Sounds like your plugin and arduino code versions are not compatible? I'm not quite sure what exactly you want to do, but check page 68 for the example SAS code.
  5. Do you have a compiled version of the latest debug tool? I'll link to it in the first post.
  6. @Scout1218 if you go to a electronics distributor like Farnell, Mouser or Digikey, you can find 7 segment LEDs of all kinds of colours. Also try "orange" instead of "amber".
  7. Floats are definitely slower, but not that slow in the overall scheme of things. I think most people would be contained by communication to displays and such rather than maths stuff.
  8. This still works fine for 1.3, the original rollkage stuff might need some cfg updates.
  9. Hi there's no reason why throttle wouldn't work if you can control all the other things. Did you check the config file? You may want to try setting throttleenable = 1 or 3. see first post for details.
  10. OK this is really weird, can you try setting the default port to COM9 and set "handshakedisable" to 1?
  11. Just to confirm you are using COM9 for your arduino and you are using the demo16 arduino code? Do you see any serial rx tx lights flash on your arduino when you go to launch? I could be either your arduino is not receiving anything from the plugin or for some reason it's not sending the handshake packet. Maybe increase handshake from 2500 to 5000 in the settings file? "KSP Display" is just referring to your arduino. I called it a "display" because originally I made a display with mine. Maybe I should change it to something generic. Oh I just checked the first post, the "tutorial" still linked to the older demo13 version of the arduino code, you need demo16 for the current 0.19 plugin. No sure if this is the problem but I fixed the link now.
  12. Hi you need to tell us what OS, which version of KSP and plugin you are using, and post the debug log.
  13. Hi Changine IDLETIMER is fine, it needs to be at least more than refresh time. Increasing handshake delay is also fine, the only downside is if you have lots of serial ports, the plugin can wait up to the delay for each port as it checks for a connection, so it can increase KSP load time by a lot. I don't know which screen you are using, but you also might try some of the fast tft libraries. Oh and ideally, you should put your code between case 1: // your code here break; you can also add something like case 0: //Handshake packet Handshake(); tft.print("connecting"); break; if you want
  14. OK cool, but without seeing your whole code it's hard to say if you put it in the right place. Ideally you should put it in the outputs() function, which is run every 25ms by default if you want fast updates from axes controls: controlTime = now - controlTimeOld; if (controlTime > CONTROLREFRESH){ controlTimeOld = now; controls(); Serial1.println((long)VData.ECharge); } or in inputs() which is ran whenever a packet is received from KSP if (KSPBoardReceiveData()){ deadtimeOld = now; returnValue = id; switch(id) { case 0: //Handshake packet Handshake(); break; case 1: Indicators(); Serial1.println((long)VData.ECharge); break; }
  15. have you tried putting Serial1.begin(38400); In void setup() instead of utilities? Also what is the baud rate for your bluetooth? Maybe it only works at 9600.
  16. You mean on a mega? You can't do it without software serial on a normal arduino. On a mega you can use Serial.print(), Serial1.print(), and so on. It will be much faster because they are hardware serial ports. There are also other arduino or teensy boards with more than 1 serial ports. But this is assuming your problem is caused by software serial.
  17. Have you tried without software serial? It is very slow and uses a lot of processor time. It might be slowing down everything so you don't have enough time to process the incoming packets. I would suggest getting a Mega board which has 4 hardware COM ports.
  18. Hi they are listed in the example arduino code (first tab) //Input enums #define SAS 7 #define RCS 6 #define LIGHTS 5 #define GEAR 4 #define BRAKES 3 #define PRECISION 2 #define ABORT 1 #define STAGE 0
  19. Update 0.19.0: Changes: Fixed broken axis/SAS control issues reported by @Freshmeat and @#Pseudo Rebuilt against KSP 1.3 (previous version seem to work still, so this is just in case something changed) Download link: https://sites.google.com/site/zitronfiles/KSPSerialIO_019_0.zip This now becomes the recommended version.
  20. Hi, you just need to do this: if (digitalRead(somepin)) MainControls(STAGE, HIGH); else MainControls(STAGE, LOW); You can also control RCS, SAS, LIGHTS, and other stuff this way.
  21. Yeah there's some kind of a bug in mono's COM port selection. See "known issues" in first post. You can change the number to 1-9 in windows control panel.
  22. Oh yeah excrements, I've been peer pressured into playing too much Factorio lately. I'll check the 1.3 thing this weekend, not super hyped about the update... Now KSP is owned by take two, I wonder what's going to happen with development, could be a good thing. Really miss the @HarvesteR days...
  23. If TT is smart, they should hire back the all the actual devs that quit squad after 1.2, and pay them properly. I would happily pay money for whatever DLC Harvester, Mu, Taniwha, NathanKell, Sarbian, Romfarer, Arsonide, Porkjet, and Claw comes up with.
×
×
  • Create New...