Idea Shuttle Fleet recompile for Orbiter 2016

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
So i zoom in a bit:
GK3LxX7.jpg

z3SRCCY.jpg


Redid the speed brake per SF. Not sure about the autospeedbrake though
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
So I am stumped. I have updated the VC with better textures. I got the 3 front mfd early version working. But the later one not so much. The rear CCTV which for orbiter are mfd. Max MFD is 12.
So in regular graphics if I power up the top mfd CCTV1 it comes on but it also powers CCTV2. If I power CCTV2 on just the buttons power on.

In d3d9 it seems to work good.

Not sure what to do. I can share the code if someone wants to take a look

---------- Post added 06-16-20 at 10:42 AM ---------- Previous post was 06-15-20 at 04:46 PM ----------

So I noticed in d3d9 no issues but in regular graphics issues. I redid the mesh and now a ctd in vc mode.
vOiBUaf.jpg

something to do with the
Exception thrown at 0x7AB2AAB9 (ddraw.dll) in orbiter.exe: 0xC0000005: Access violation reading location 0x00000004.

---------- Post added at 03:44 PM ---------- Previous post was at 10:42 AM ----------

Well back to one.

So not sure why it works good in d3d9 but not in regular graphics?

In regular graphics. The top mfd controls the top and bottom screens. The bottom one only turns on off the labels.

Code:
	// D. Beachy: handle power buttons
	case AID_CDR1_PWR:
	case AID_CDR2_PWR:
	case AID_PLT1_PWR:
	case AID_PLT2_PWR:
	case AID_MFD1_PWR:
	case AID_MFD2_PWR:
	case AID_MFD3_PWR:
	case AID_MFD4_PWR:
	case AID_MFD5_PWR:
	case AID_MFDA_PWR:
	case AID_CCTV1_PWR:
	case AID_CCTV2_PWR:
	{
		int mfd = id - AID_CDR1_PWR + MFD_LEFT;
		oapiSendMFDKey(mfd, OAPI_KEY_ESCAPE);
	} return true;

so it looks like D. Beachy did it.

from what I understand
Code:
int mfd = id - AID_CDR1_PWR + MFD_LEFT;
is AID_CDR1_pwr (13) +0

Code:
// D. Beachy: define power buttons
#define AID_CDR1_PWR      13
#define AID_CDR2_PWR      14
#define AID_PLT1_PWR      15
#define AID_PLT2_PWR      16
#define AID_MFD1_PWR      17
#define AID_MFD2_PWR      18
#define AID_MFD3_PWR      19
#define AID_MFD4_PWR      20
#define AID_MFD5_PWR      21
#define AID_MFDA_PWR      22
#define AID_CCTV1_PWR     23
#define AID_CCTV2_PWR     24

So running a debug line
Code:
sprintf(oapiDebugString(), "Mouse position: X %f Y %f Z %f bt%d", p.x, p.y, p.z, id);
show that when I press on the power for upper it is 23 and the lower is 24.


Code:
	static const int mfdgrp[12] = {
		GRP_CDR1_VC, GRP_CDR2_VC, GRP_PLT1_VC, GRP_PLT2_VC,
		GRP_MFD1_VC, GRP_MFD2_VC, GRP_MFD3_VC, GRP_MFD4_VC, GRP_MFD5_VC,
		GRP_MFD_AFT_VC, GRP_MFDCCTV1_VC,GRP_MFDCCTV2NEW_VC
	};

Code:
#define GRP_labelcdr1 432
#define GRP_labelcdr2 433
#define GRP_labelplt1 434
#define GRP_labelplt2 435
#define GRP_labelmd1 436
#define GRP_labelmd2 437
#define GRP_labelmd3 438
#define GRP_labelmd4 439
#define GRP_labelmd5 440
#define GRP_labelmda 441
#define GRP_labelmfCCTV1 442
#define GRP_labelmfCCTV2NEW 443
#define GRP_CDR1_VC 444
#define GRP_CDR2_VC 445
#define GRP_PLT1_VC 446
#define GRP_PLT2_VC 447
#define GRP_MFD1_VC 448
#define GRP_MFD2_VC 449
#define GRP_MFD3_VC 450
#define GRP_MFD4_VC 451
#define GRP_MFD5_VC 452
#define GRP_MFD_AFT_VC 453
#define GRP_MFDCCTV1_VC 454
#define GRP_MFDCCTV2NEW_VC 455


---------- Post added 06-17-20 at 11:48 AM ---------- Previous post was 06-16-20 at 03:44 PM ----------

So I may just write off as a bug.
So same code. on the left is regular graphics and on the right D3D9. See on the left out just the buttons are on. and on the right the screen and buttons
aRC0jx1.jpg
 
Last edited:

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
Are you using oapi::Sketchpad2 functionality maybe?
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
I don't think. I just used the existing Atlantis code and added 2 more MFDS
 

Donamy

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Oct 16, 2007
Messages
6,904
Reaction score
196
Points
138
Location
Cape
The screens may not be mapped correctly.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
I thought about that. But why would it only do it in non D3D9 graphics?
 

dbeachy1

O-F Administrator
Administrator
Orbiter Contributor
Addon Developer
Donator
Beta Tester
Joined
Jan 14, 2008
Messages
9,214
Reaction score
1,560
Points
203
Location
VA
Website
alteaaerospace.com
Preferred Pronouns
he/him
It's quite possible that there is a bug somewhere else in the code that is corrupting Orbiter's memory, causing odd results. If you aren't already doing it, I highly recommend running with Visual Studio's CRTDBG checks enabled for your debug builds so you can find and fix pointer-related bugs. Check out this post for details.

Also, I highly recommend using the Visual Studio C++ debugger to put breakpoints in your code and step through it where the problem occurs so you can see exactly what is wrong. Without using the debugger, development usually devolves into lots of guesswork and frustration, particularly for larger projects. Check out this post for details on how to use the Visual Studio debugger with your Orbiter code. If you use the debugger, you can step through the code that renders the MFD and see exactly what part of the code is not working.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
Thanks. So I have this set up but no scenarios are loaded.
rVsyJo6.jpg


I guess I need to figure out how orbiter knows which mesh for mfd and which mesh for the buttons.
 

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
Odd...are you sure you have a full Orbiter installation at "D:\Orbiter2016" ?

For D3D9Client the setup is a little different:
Command: [D:\Orbiter2016\Modules\Server\orbiter.exe]
Working directory: [D:\Orbiter2016]
You can also set [-s "(Current state)"] at the "Command Arguments" to directly start the last scenario again.

By the way: You should use the MAKROS for your paths, so the .vcxproj works wherever Orbiter is installed:
Command: [$(OrbiterDir)\orbiter.exe]
Command Arguments: [-s "(Current state)"]
Working directory: [$(OrbiterDir)]
...rsp. (D3D9Client):...
Command: [$(ModuleDir)\Server\orbiter.exe]
Command Arguments: [-s "(Current state)"]
Working directory: [$(OrbiterDir)]
 
Last edited:

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
Odd...are you sure you have a full Orbiter installation at "D:\Orbiter2016" ? Yes

Not sure about the paths. But my full orbiter is at D:eek:rbiter2016.

But is the label and mfd matched by the number?

So CDR1_MFD is 1 so label cdr1 should go with it?

---------- Post added 06-18-20 at 10:19 AM ---------- Previous post was 06-17-20 at 07:08 PM ----------

So I got it to debug.
The one thing that seems off is the mfd which is an int
52E4k0O.jpg

Code:
// D. Beachy: handle power buttons
	case AID_CDR1_PWR:
	case AID_CDR2_PWR:
	case AID_PLT1_PWR:
	case AID_PLT2_PWR:
	case AID_MFD1_PWR:
	case AID_MFD2_PWR:
	case AID_MFD3_PWR:
	case AID_MFD4_PWR:
	case AID_MFD5_PWR:
	case AID_MFDA_PWR:
	case AID_CCTV1_PWR:
	case AID_CCTV2_PWR:
	{
		int mfd = id - AID_CDR1_PWR + MFD_LEFT;
		oapiSendMFDKey(mfd, OAPI_KEY_ESCAPE);
		//sprintf(oapiDebugString(), "Mouse position: X %f Y %f Z %f bt%d", p.x, p.y, p.z, id);
	} return true;
aid_CRD_pwr =13 MFD_left 0

That wasn't it. I put a break below where it figures mfd and it was correct.

So not sure where else to check So it seems the mfd 10 powers up mfd10 and mfd11 screen

So I thought about the mesh. Meshwizard seems to like it.
but this doesn't work for me
kSgTJna.jpg


I also added these lines:
Code:
DLLCLBK VESSEL *ovcInit (OBJHANDLE hvessel, int flightmodel)

{

#ifdef _DEBUG
	// NOTE: _CRTDBG_CHECK_ALWAYS_DF is too slow
	_CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF |
		_CRTDBG_CHECK_CRT_DF |
		_CRTDBG_LEAK_CHECK_DF);
#endif



	return new Atlantis (hvessel, flightmodel);
}


---------- Post added 06-19-20 at 05:58 AM ---------- Previous post was 06-18-20 at 10:19 AM ----------

So redid the mesh and still the issue. May just write it off as a bug. You can't use the cameras mfd in normal graphics anyhow.

Not sure why shipedit isn't working.
 
Last edited:

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
So got a ms2015 expert question. So to use the HD srb you have to copy and rename

Copy ShuttleOLD_lsrb and paste and rename to ShuttleOLD_lsrb_1
Copy ShuttleOLD_rsrb and paste and rename to ShuttleOLD_rsrb_1
Copy ShuttleOLD_tank and paste and rename to ShuttleOLD_tank_1

and make changes in the ini and scn.
Code:
[BOOSTER_1]
N=1
MeshName="ShuttleOLD_lsrb"
Height=38.5
Diameter=3.71 
EmptyMass=66406
FuelMass=503487
Thrust=14739770.25
angle=0.0
off=(-6.9,0.,2.115)
BurnTime=122.0
eng_1=(0.5,0.5,-22.5)
eng_diameter=2.5
ENG_PSTREAM1=solidfuel_exhaust
ENG_PSTREAM2=contrail4
ENG_TEX=Exhaust2
Speed=(-15.000,-4.000,0.000)
Rot_speed=(-0.200,0.400,0.000)
CURVE_1=(-1,0)
CURVE_2=(0,100)
CURVE_3=(30.3,100)
CURVE_4=(35.5,87)
CURVE_5=(60.0,87)
CURVE_6=(65.1,100)
CURVE_7=(103,100)
CURVE_8=(115,85)
CURVE_9=(136,5)

[BOOSTER_2]
N=1
MeshName="ShuttleOLD_rsrb"
Height=38.5
Diameter=3.71 
EmptyMass=66406
FuelMass=503487
Thrust=14739770.25
angle=0.0
off=(6.85,0.,2.115)
BurnTime=122.0
eng_1=(-0.5,0.5,-22.5)
eng_diameter=2.5
ENG_PSTREAM1=solidfuel_exhaust
ENG_PSTREAM2=contrail4
ENG_TEX=Exhaust2
Speed=(15.000,-4.000,0.000)
Rot_speed=(-0.200,-0.400,0.000)
CURVE_1=(-1,0)
CURVE_2=(0,100)
CURVE_3=(30.3,100)
CURVE_4=(35.5,87)
CURVE_5=(60.0,87)
CURVE_6=(65.1,100)
CURVE_7=(103,100)
CURVE_8=(115,85)
CURVE_9=(136,5)

[BOOSTER_3]
N=1
Height=46.88 
Diameter=8.7
EmptyMass=0.00000001
FuelMass=0.00000001
Thrust=0.00000001
BurnTime=1
BurnDelay=123
off=(6,0,13.401)
MeshName="ShuttleOLD_tank"
eng_1=(-1.6,7.93,-27.88)
eng_2=( 1.6,7.93,-27.88)
eng_3=( 0.0,11.33,-27.03)
DIR=(0.0, 0.25885, -0.96545)
eng_diameter=2.0
SPEED=(0,-90,0)
Module=SHUTTLE2016BURNTEX
ENG_TEX=Exhaust_atsme
battery=1.5
Reignitable=0

[STAGE_1]
Height=46.88 
Diameter=8.7
EmptyMass=35272
FuelMass=728715.23
Thrust=6539030.025
BurnTime=504.1
off=(-0.05,0,13.401)
MeshName="ShuttleOLD_Btank"
eng_1=(-1.6,7.93,-26.88)
eng_2=( 1.6,7.93,-26.88)
eng_3=( 0.0,11.33,-26.03)
DIR=(0.0, 0.25885, -0.96545)
eng_diameter=2.0
speed=(0,0,-10)
ENG_TEX=Exhaust_atsme
battery=1.5
Reignitable=0

[PAYLOAD_1]
MeshName="2016spaceshuttle\Columbia\ColumbiaORG2016H7"
off=(-0.00,8.13,0.0)
Diameter=23.1
Height=36.2
Mass=99453.0
Module="Shuttle2016Bearly"
Name=STS-1
SPEED=(0,0.8,0)
Rot_Speed=(0.002,0,0)
RENDER=1
LIVE=1
and scn
Code:
BEGIN_SHIPS
ET-1:Multistage2015
  STATUS Landed Earth
  POS -80.6208630 28.6270927
  HEADING 180.57
  ALT 47.361
  AROT 151.065 -8.240 4.530
  ATTACHED 0:0,MS_LaunchPad_ET-1
  AFCMODE 7
  PRPLEVEL 0:1.000000 1:1.000000 2:1.000000 3:1.000000
  NAVFREQ 0 0 0 0
  XPDR 0
  CONFIG_FILE Config\Multistage2015\Space-Shuttle_STS-1HD.ini
  GUIDANCE_FILE Config\Multistage2015\Guidance\guidance_shuttle_STS-3real.txt
  CONFIGURATION 0
  CURRENT_BOOSTER 1
  CURRENT_STAGE 1
  CURRENT_INTERSTAGE 1
  CURRENT_PAYLOAD 1
  FAIRING 0
  GNC_RUN 1
  MET -540.000
  BATTERY 5400.000000
  STAGE_IGNITION_TIME 0.000000
  STAGE_STATE 1
  TELEMETRY_FILE Config\Multistage2015\Telemetry\guidance_shuttle_STS-1.txt
  ALT_STEPS 100.0,350.0,1400.0,35000.0
  PEG_PITCH_LIMIT 35.000
  PEG_MC_INTERVAL 0.100
  RAMP 
END
MS_LaunchPad_ET-1:EmptyModule
  STATUS Landed Earth
  POS -80.6041230 28.6086670
  HEADING 0.00
  ALT -2.000
  AROT 151.065 -8.240 4.530
  AFCMODE 7
  NAVFREQ 0 0
END
MS_Camera:MS_Camera
  STATUS Landed Earth
  POS -80.6238630 28.6070927
  HEADING 180.57
  ALT 0.000
  AROT -118.284 -4.474 171.752
  AFCMODE 7
  NAVFREQ 0 0
  TARGET ET-1
END
STS-1:Shuttle2016Bearly


So everything works you get the non burnt texture ET

BUt for some reason both SRB seperate at different times and ET changes later.

000065.534: ET-1 Booster n: 1 ignited @0.0
000065.534: ET-1 Booster n: 2 ignited @0.0
000065.559: Detached from Launchpad
000065.808: ET-1 Stage n: 1 ignited @0.3
000073.045: LaunchPad Deleted from Scenery
000153.565: RESET PEG
000185.541: ET-1: Booster n.1 jettisoned name: ShuttleOLD_lsrb_1 @120.006
000188.532: ET-1 Booster n: 3 ignited @123.0
000281.078: ET-1: Booster n.2 jettisoned name: ShuttleOLD_rsrb_1 @133.758
000281.080: ET-1: Booster n.3 jettisoned name: ShuttleOLD_tank_1 @133.759

9X8l1Nx.jpg

9X8l1Nx.jpg

o6d6FkL.jpg

after 1 srb leaves
IuAWLA8.jpg
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
So working on STS 49 with ASEM and MPESS
qTNifCN.jpg


But I am stumped on why the RMS will not grapple the MPESS. It would when just a mesh and cfg. But make it a dll and use the same attachment info it will not attach.
 

Donamy

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Oct 16, 2007
Messages
6,904
Reaction score
196
Points
138
Location
Cape
Does it need an ID ?
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
yes.
Code:
BEGIN_ATTACHMENT
P 0 .5 0  0 -1 0  0 0 -1 XS ; TO SHUTTLE
P 0 3.2 0  0 1 0  0 0 1 GS ; TO RMS
END_ATTACHMENT
rms needs id of "GS"

So if I used this cfg:
Code:
; === Configuration file for vessel class NASA ASEM ===
ClassName = MPESS2
Module = MPESS2

BEGIN_ATTACHMENT
P 0 .5 0  0 -1 0  0 0 -1 XS ; TO SHUTTLE
P 0 3.2 0  0 1 0  0 0 1 GS ; TO RMS
END_ATTACHMENT
THIS WILL NOT ATTACH.

But if I use this it will:
Code:
ClassName = MPESS
MeshName = STS_PAYLOADSNEW\\MPESS
Mass = 1124
Size = 4

BEGIN_ATTACHMENT
P 0 .5 0  0 -1 0  0 0 -1 XS ; TO SHUTTLE
P 0 3.2 0  0 1 0  0 0 1 GS ; TO RMS
END_ATTACHMENT
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
So fixed the attachment issue with the MPess:)

So been trying to do the sts 49 mission. So built the rms clamp for the pfr. Got it to hang on the front bulkhead. The eva guy can get it.

BUt then it was attached to the rms latch. Here is where we have a problem. Benn listed as a bug so not sure if a fix. The issue is when the rms attaches to the clamp it is in wrong position. exit and restart all is good.

Here the guy got the capture bar and going to try to get the sat.

VUGFBG6.jpg
 

Donamy

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Oct 16, 2007
Messages
6,904
Reaction score
196
Points
138
Location
Cape
I thought the issue was fixed in D3D9 ? Or was that just SSU ?
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
I thought the issue was fixed in D3D9 ? Or was that just SSU ?

Not sure. In d3D9 it is bad. If the SSu guys fixed it that would be great.

I thought the rms for the ISS had a fix for it. But the code isn't available. Somehow a reset is needed
 

Donamy

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Oct 16, 2007
Messages
6,904
Reaction score
196
Points
138
Location
Cape
The JEMRMS works only if not attached/docked when scenario begins. I need attachment manager to attach it for use. David413 did the code. The Canadarm2 code is available IIRC.
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
gattispilot: If you're using the latest D3D9Client version, make sure "Enable absolute animation handling" is checked in the D3D9Client Advanced Setup window. This will fix the sliding RMS End Effector attachment point issue.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,636
Reaction score
2,613
Points
203
Location
Dallas, TX
Thanks I download and installed this version and press the box for animation:
WOdA7Sj.jpg


So did a few shots. Here the eva is getting the pfr with RMS attachment off the forward bulkhead wall
wYJn7j6.jpg

and then he proceeds to aft and the rms is moved it.

And the PFR/RMS is attached.
NkVF5nh.jpg


but look at the gap. So I exited and restarted and now it is correct.
nfYWdDv.jpg


and then mounted the pfr and moved it and rms to the cradle bar and get the bar
YdIZaEX.jpg
 
Top