-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds CAEDv2 #1
base: master
Are you sure you want to change the base?
Adds CAEDv2 #1
Conversation
Could you explain to me what reading the pitch, yaw, roll of the craft would output? |
A value between -2¹⁵+1 and 2¹⁵-1 where -2¹⁵+1 = -180° and 2¹⁵-1 = 180° (-2¹⁵ isn't defined then). But I'm not sure actually if that way or simply 0 = 0° and 2¹⁶ -1 = 360°. And as your definition already covered that, this might be dropped. The main reason I wanted to share that is because your device's accuracy about the altitude (you store the scalar in only on 16 bit register so your maximum value is 2¹⁶ which isn't even enough to get an altitude in meters outside Kerbin's atmosphere). Or do you wanted to know what pitch/yaw/roll value? I was thinking like the current heading you can see on the nav ball. Fabian |
That would be Pitch, Heading, Roll. But yes, I was asking about what those values would be specifically. Anyhow, see if you can get khyperia and zengei to have a look at it. |
I'm not very familiar with the official API/naming. But yep I guess the second would be heading. |
I'll take a look at this (and Cilph's specs) in detail tonight after I get home from work. |
Okay I noticed that the pressure sensor can measure until 0.0001 atm (≃ 0.01 kPa). So the pressure definition might need to be modified to allow a value below 1 kPa. With Jool's atmospheric pressure of about 1.52 MPa with 16bit the lowest step width would be 0.1 kPa. |
…n "overflow" (doesn't exist there); +pressure in 32bit mode is in Pa;
Okay the new specification supports in 32bit mode pressure intervals of 1 Pa (if needed 1 mPa intervals are also possible, 1 µPa intervals only allow a maximum pressure of about 4.2 kPa). I also looked up the official specification of the DCPU and this uses EX for overflows so I changed that too. And I noticed that the Altitude in RAM of course also won't overflow (as they don't touch the C register). |
The CAED allows software to access the sensor data. It also adds four altitude interrupts which allow altitudes in meters (48 bit, ≃ 281 Tm or ≃ 200000× farther than Eeloo) or other units like in 10ths of kilometers. With either 16bit or 32bit. Only Moho's periapsis is below 2³²-1 meters. All other planetary apsides are outside that boundary. But 32bit (in meters) are sufficient for any planetary altitude. Minmus orbit for example is within 16bit (kilometers).
Also all sensor data should be enough for most cases. 65 m/s² may not always be sufficient as this are only 6.68g, but with the 32bit extension it is possible tor read values up to 437 000g!
As I'm not sure how to exactly access KSP sensors it might be possible to change the definitions: For example if the accelerometer only is exact in cm/s², the device might should return the acceleration in cm/s².