# ProjectSpace Transportation System 2016

#### gattispilot

So this is what I get for STS 6 IUS start to tilt. The date if it is 8hr 25 min MET is April 5 1:55 UTC. from MS2015 MET 27258.330

and for IUS deploy I get April 5 3:30 UTC MET 32811.250
155.66955 Nautical miles

But do we know what the shuttle hdg and pitch,..... should be historically?

Last edited:

#### gattispilot

Something that I think would enhance this is making the mission timer work.
This is from SSU:

Not sure how to get that to work. I have the SSU code. But it is Greek to me

But I wonder maybe just make it part of the HUD?

In Fred's MS2015. it has the MET displayed. And in the sts 6 test scn where I launched and ran it for 8 hrs at 100x and exited. It showed the ET-6 and the met.
 ET-6:Multistage2015 STATUS Orbiting Earth RPOS 4836691.314 1611305.264 4283931.949 RVEL -4188.2592 -2908.4982 5821.5937 AROT -38.226 29.234 -127.155 AFCMODE 7 PRPLEVEL 0:0.077531 NAVFREQ 0 0 0 0 XPDR 0 CONFIG_FILE Config\Multistage2015\Space-Shuttle_STS-6new.ini GUIDANCE_FILE Config\Multistage2015\Guidance\guidance_shuttle_STS-6real.txt CONFIGURATION 1 CURRENT_BOOSTER 3 CURRENT_STAGE 1 CURRENT_INTERSTAGE 1 CURRENT_PAYLOAD 2 FAIRING 0 MET 32811.250 BATTERY 0.000000 DENY_IGNITION STAGE_IGNITION_TIME 0.000000 STAGE_STATE 2 TELEMETRY_FILE Config\Multistage2015\Telemetry\guidance_shuttle_STS-6.txt ALT_STEPS 100.0,350.0,1400.0,35000.0 PEG_PITCH_LIMIT 35.000 PEG_MC_INTERVAL 0.100 END 

I know the Spacelab at a MET display at the front. I would try to get it to work in that before the shuttle vc.

and speaking of Spacelab. I have a crew mesh. Really not sure if we need it. Noting to do just look.

The crew is a highly textured guy and work would be needed to get joint to work.

#### gattispilot

Spacelab now has MET

I followed the ms2015 code. But I may need to modify it to add days in there.

I need to lighten it so it is always light in there.
I think that is a material setting

#### gattispilot

So ms2015 only get hrs/min/ seconds
 VECTOR3 STS09SPACELAB::hms(double time) { VECTOR3 met; if (time == 0) { met = _V(0, 0, 0); } else { time = abs(time + 0.5 * (time / abs(time) - 1)); met.x = floor(time / 3600) - 0.5 * (time / abs(time) - 1); met.y = floor((time - met.x * 3600 * (time / abs(time))) / 60) - 0.5 * (time / abs(time) - 1); met.z = floor(time - met.x * 3600 * (time / abs(time)) - met.y * 60 * (time / abs(time))); } return met; } 

Not sure how to take the MET and get days,hrs,minutes,.......
MET/86400 give how many days

#### gattispilot

I found this:
https://www.tutorialspoint.com/converting-seconds-into-days-hours-minutes-and-seconds-in-cplusplus

converting seconds into days, hours, minutes, seconds

In this example the seconds is a int. while the MET is a double.

 timenew = floor(MET); days = timenew / (24 * 3600); timenew = timenew % (24 * 3600); hours = timenew / 3600; timenew %= 3600; minutes = timenew / 60; timenew %= 60; seconds = timenew; sprintf(oapiDebugString(), "MET D: %d H: %d M: %d S: %d", days,hours,minutes,seconds); 

So to get that display to function is going to require help. I think this should be in the shuttle it always displays even in space. but then you don't have to have it every vessel?

#### gattispilot

A lot of meshes and animation but it can done this way.

where each digit would have 10 meshes and then if the hours first digit is 2 then move the 2 mesh forward,..............

it looked like the real spacelab MET timer had white background and black numbers.

Last edited:

#### gattispilot

I looked at SSU code. It looks like the way to go is to map the numbers to the mesh. So if digit1 of the seconds is 0 then map the 0 to the digit1 mesh,.......

not sure really how to do that though.

Otherwise for the MET you would have 90 mesh parts (9x10digits)

Option 2 is just leave as is. Maybe clean up the textures. The MET is shown at the bottom of the screen. Maybe add a key to turn on/off. I think if it is on the HUD if youwhich vessels you may not see it. Or just keep it on the Shuttle HUD and not at the bottom of the screen

Last edited:

#### gattispilot

on the spacelab for sts09. we get working MFDs in the VC

and a working MET

The MET time is drawn on to the texture of the MET box. The only draw back is it is only for the VC view.
I had internal view camera positions set. So I may change them to the VC view.

So with this. I think I can update the shuttle with the MET. I see the shuttle MET digits are red.

Might could get the event timer to work also?

#### gattispilot

STS5 I have redone the equipment,..... Launched and advance to 6:30 MET for sbs deploy

The orbit is close. But is the orbiter heading/pitch correct?
BUt this is where it gets confusing:

Here the SBS OMS is 1 day and 13:25

But here the burn is more 8.25 MET

I am working on the event timer and MET for the shuttle.

#### gattispilot

so real sts 5

looks like the one with the earth is the view port
BUt now the ASE is open where is the Earth?

And the bay looks lit from the Sun?
Here is the Earth and Sat

Ugh, Look at the bottom of the case. Angled rather than rounded

#### gattispilot

I found this.

Not sure how to implement

#### gattispilot

I made a test VC and got the MET to work and the Event timer. What I did was paint the numbers on the texture. Hopefully the FPS will not bad.

GMT time

Next will be remaking the VC. On the scenarios MET will be need to be added. It looks like in SF on the GPC the MET was display but it seems it was not correct. Animation of the switches will need to be done. And animation of the white minute/second selection. It looks like there are 2 event timers. One in the front and one in the aft.

#### gattispilot

Starting to rebuild the early shuttle vc. After reading the shuttle manual. There is a MET on the front Overhead panel
This is it now:

You can see where the MET display should go. I can do that easily. But there is a switch to control it. That whole panel is just a texture. I might just leave it as is but add the display. OPtion2 which would take more work is to use the SSU front section?

Here is the front of the VC

I will add a new texture so the event timer will work. The other thing I might could do is the Surface body indicator. Maybe make the orange triangles as meshes and move them. Not sure if anyone would notice as they are trying to land

#### gattispilot

Got the front MET display to work

and front Event timer to work

Thing I haven't figured out is the spring load switches.

Right now if a switch is selected the anim_state is 0 or 1. the default being .5

As I see it a spring loaded switch would go to 0 or 1 and then reset to .5

But that happens so fast it looks like no change. Not sure if I need a delay?

#### Arvil

##### Member
I imagine it depresses in one frame and resets the next. The brain ain’t fast enough to register that. Maybe find a real switch like that, l like a radio or TV. Time yourself pressing the switch ten times. Divide by ten to get cycle time for your finger, half that is depress cycle, the other half is release, then apply the delay?

#### gattispilot

Thanks. In SSU i noticed if I held the mouse key down the key stayed down until I released.

I guess something like key pressed. start timer and then after time is up reset position.

#### gattispilot

new aft view

As far as the spring loaded switch. I add this function panel switch. How I think it should work is. press the switch the initial position is set. go to panel switch function. Then the timer is set. When the timer gets to 10 return back and reset switch.

BUt if stops at 1.
here is where when you click it does something.

 case AID_AFTEVENTSET: { SetAnimation(anim_AFTSETRESET, 0); panelswitch(); SetAnimation(anim_AFTSETRESET, .5); } return true; 
 void Atlantis::panelswitch() { int switchtimer; switchtimer = 0; switchtimer = (switchtimer + 1);// count up sprintf(oapiDebugString(), "timer M: %d ", switchtimer); if (switchtimer > 10)switchtimer = 0; // if timer reaches point reset timer if (switchtimer == 0)return;//return since timer reached end } 

#### gattispilot

Not sure why the switch timer is not working.
 void Atlantis::panelswitch() { int switchtimer; switchtimer = 0; switchtimer = (switchtimer + 1);// count up sprintf(oapiDebugString(), "timer M: %d ", switchtimer); if (switchtimer > 10)switchtimer = 0; // if timer reaches point reset timer if (switchtimer == 0)return;//return since timer reached end } 

It goes there and just shows 1. As I understand it. It should keep counting until it gets to 10 then return
So when the mouse hits the area it goes to this code
it sets the animation of the switch to 0 and then should go to the timer. Then when the timer returns. set the switch back to .5

It real life and I guess like SSU has it. the switch is flipped up when the mouse hits that area. and when you release the mouse button is goes back.

 case AID_AFTEVENTSET: { SetAnimation(anim_AFTSETRESET, 0); panelswitch(); TimerSetAFT = 1; //SetAnimation(anim_AFTSETRESET, .5); } return true; 

#### kuddel

##### Donator
Donator
Please read your code! The error almost SCREAMS at you: Every time the panelswitch method is called you set the value of the local variable switchtimer to zero!
So what do you expect!