Jump to content

Search the Community

Showing results for tags 'kos mod'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements
    • Welcome Aboard
  • Kerbal Space Program 2
    • KSP2 Dev Updates
    • KSP2 Discussion
    • KSP2 Suggestions and Development Discussion
    • Challenges & Mission Ideas
    • The KSP2 Spacecraft Exchange
    • Mission Reports
    • KSP2 Prelaunch Archive
  • Kerbal Space Program 2 Gameplay & Technical Support
    • KSP2 Gameplay Questions and Tutorials
    • KSP2 Technical Support (PC, unmodded installs)
    • KSP2 Technical Support (PC, modded installs)
  • Kerbal Space Program 2 Mods
    • KSP2 Mod Discussions
    • KSP2 Mod Releases
    • KSP2 Mod Development
  • Kerbal Space Program 1
    • KSP1 The Daily Kerbal
    • KSP1 Discussion
    • KSP1 Suggestions & Development Discussion
    • KSP1 Challenges & Mission ideas
    • KSP1 The Spacecraft Exchange
    • KSP1 Mission Reports
    • KSP1 Gameplay and Technical Support
    • KSP1 Mods
    • KSP1 Expansions
  • Community
    • Science & Spaceflight
    • Kerbal Network
    • The Lounge
    • KSP Fan Works
  • International
    • International
  • KerbalEDU
    • KerbalEDU
    • KerbalEDU Website

Categories

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Skype


Twitter


About me


Location


Interests

Found 3 results

  1. Hello everyone, I just arrived and downloaded KSP1 essentially to use the KOS features. I installed the mod via CKAN (precisely all the files compatible with my version of the game that were offered to me and which started with KOS), however, when I write the program to run in the terminal, the following problem is shown and nothing happens: "The parser used by kos is complaining about a part of the script it can't understand. KOS uses a parser-generator tool known as TinyPG, and the text description you see from this error message comes mostly from TinyPG, not from KOS itself ." The code I'm trying to run is very simple: SET thrott TO 1. LOCK THROTTLE TO thrott. What can I do? Is there any permission I need to enable? Is the mod simply old? Thanks so much for your help and have a good day.
  2. I'm trying to make a quadcopter that's actually flyable intuitively, and to that end I'm developing a kOS script to control it. I'm using the Breaking Ground rotors and controlling them using their max RPM fields. Here's the code: // Fly-by-wire for a quadcopter // Declare variables representing the four motors, which are tagged set frontLeft to ship:partsTagged("front left")[0]. set frontRight to ship:partsTagged("front right")[0]. set rearLeft to ship:partsTagged("rear left")[0]. set rearRight to ship:partsTagged("rear right")[0]. // Use setField(rpmLimit) set frontLeftThrottle to frontLeft:getModule("ModuleRoboticServoRotor"). set frontRightThrottle to frontRight:getModule("ModuleRoboticServoRotor"). set rearLeftThrottle to rearLeft:getModule("ModuleRoboticServoRotor"). set rearRightThrottle to rearRight:getModule("ModuleRoboticServoRotor"). set motors to list("frontLeft", "frontRight", "rearLeft", "rearRight"). function throttleMotor { parameter motor, throt. // throt is a float between 0 and 1 if motor = "frontLeft" { frontLeftThrottle:setField(throt * 460). } else if motor = "frontRight" { frontRightThrottle:setField(throt * 460). } else if motor = "rearLeft" { rearLeftThrottle:setField(throt * 460). } else if motor = "rearRight" { rearRightThrottle:setField(throt * 460). } else { // Catch-all, this should never happen print("Error: invalid motor!"). } } function calcMotorSpeed { // Make the speed of each motor proportional to the main throttle plus the input from steering set rotorSpeed to 230 * pilotMainThrottle. set speedOffset to rotorSpeed * 0.25. // Pitch: If negative, front rotors slow down and rear rotors speed up // If positive, front rotors speed up and rear rotors slow down // This happens until the measured pitch is +/- 15 degrees, // at which point the four motors briefly change speed to stop the pitch // If zero, reverse pitch until forward speed is zero set pitchOutput to list(0, 0, 0, 0). if pilotPitch = -1 { set pitchOutput[0] to -speedOffset. set pitchOutput[1] to -speedOffset. set pitchOutput[2] to speedOffset. set pitchOutput[3] to speedOffset. } else if pilotPitch = 1 { set pitchOutput[0] to speedOffset. set pitchOutput[1] to speedOffset. set pitchOutput[2] to -speedOffset. set pitchOutput[3] to -speedOffset. } else { // Reverse outputs until measured forward speed is zero, then set all input offsets to 0. } // Yaw: If negative, front left and rear right rotors speed up, and rear left and front right rotors slow down // If positive, front right and rear left rotors speed up, and rear right and front left rotors slow down // If zero, set all rotors to equal speed. set yawOutput to list(0, 0, 0, 0). if pilotYaw = -1 { set pitchOutput[0] to -speedOffset. set pitchOutput[2] to -speedOffset. set pitchOutput[1] to speedOffset. set pitchOutput[3] to speedOffset. } else if pilotYaw = 1 { set yawOutput[0] to speedOffset. set yawOutput[2] to speedOffset. set yawOutput[1] to -speedOffset. set yawOutput[3] to -speedOffset. } else { set yawOutput[0] to 0. set yawOutput[1] to 0. set yawOutput[2] to 0. set yawOutput[3] to 0. } // Roll: If positive, left rotors speed up and right rotors slow down // If negative, left rotors slow down and right rotors speed up // This happens until the measured roll is +/- 15 degrees, // at which point the rotors briefly change speed to stop the roll // If zero, reverse roll until lateral speed is zero set rollOutput to list(0, 0, 0, 0). if pilotRoll = -1 { set rollOutput[0] to -speedOffset. set rollOutput[2] to -speedOffset. set rollOutput[1] to speedOffset. set rollOutput[3] to speedOffset. } else if pilotPitch = 1 { set rollOutput[0] to speedOffset. set rollOutput[2] to speedOffset. set rollOutput[1] to -speedOffset. set rollOutput[3] to -speedOffset. } else { // Reverse outputs until measured forward speed is zero, then set all input offsets to 0. } // Total: Sum all inputs and that's the final output. set totalOutput to list(0, 0, 0, 0). for element in pitchOutput { set totalOutput[element] to pitchOutput[element] + yawOutput[element] + rollOutput[element] + rotorSpeed. } for m in motors { throttleMotor(m, totalOutput[indexOf(m)]). } } I have yet to implement the auto-leveling, which I have no idea how to do. How do real drones pull it off?
  3. I am sure many people have tried to use kOS instead of mechjeb, but couldn't understand it due to its complexity. Is it possible to make a mod which can act as a cheat sheet by providing all the major commands required for basic operations, or giving an in-game tutorial on how to do your first launch, orbit, docking, etc.. This way, even people with no programming knowledge will start using kOS and learn some programming.
×
×
  • Create New...