Request Single Person Spacecraft

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,605
Reaction score
2,327
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Remember that the arm would also need to be able to move sideways relative to the spacecraft, otherwise,it could only work in a single plane without the spacecraft itself moving.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Remember that the arm would also need to be able to move sideways relative to the spacecraft, otherwise,it could only work in a single plane without the spacecraft itself moving.
Sideways along the X Axis (Left to Right)? Not sure which joint would do that?
 

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,605
Reaction score
2,327
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Yeah. In your model, the rotation #2 would do that, I considered to move the mounting bracket of #1. But I think your solution is more elegant, since it keeps all mechanisms of the robot arm on the robot arm, which would make them easier to swap out for EVA repairs.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Redid the joint and textured them 6 movements.

The base is at an angle in the front section of the body.
 

Attachments

  • SPSNEWARM2B.jpg
    SPSNEWARM2B.jpg
    29.5 KB · Views: 3
  • SPSNEWARM2A.jpg
    SPSNEWARM2A.jpg
    30.2 KB · Views: 3

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
We get this now.
The arms will be rotated to fit the sides of the inside indention.
 

Attachments

  • SPSNEWARM3.jpg
    SPSNEWARM3.jpg
    25.4 KB · Views: 2

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Now this:

Both arms move and stow. Something is wrong with the attachment. What ever I attach spins.
arm1_tip[0] = _V(-.377, .307, 1.497); arm1_tip[1] = _V(0, +1, 0), arm1_tip[2] = _V(0, 0, +1);
tip is normalized.
xp1 = arm1_tip[1] - arm1_tip[0]; normalise(xp1); xr1 = arm1_tip[2] - arm1_tip[0]; normalise(xr1); SetAttachmentParams(ARM1, arm1_tip[0], xp1, xr1);

The tip follows the animation.

rms_anim[10] = new MGROUP_ROTATE(LOCALVERTEXLIST, MAKEGROUPARRAY(arm1_tip), 3, _V(-.377, .307, 1.497), _V(0, 0, 1), (float)(894 * RAD)); // -447 .. +447 anim_ARM1JOINT12 = CreateAnimation(0.0); hAC_arm = AddAnimationComponent(anim_ARM1JOINT12, 0, 1, rms_anim[10], parent);
 

Attachments

  • SPSNEWARM4.jpg
    SPSNEWARM4.jpg
    81.9 KB · Views: 4

Urwumpe

Not funny anymore
Addon Developer
Donator
Joined
Feb 6, 2008
Messages
37,605
Reaction score
2,327
Points
203
Location
Wolfsburg
Preferred Pronouns
Sire
Didn't we observe a similar bug in SSU?
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
I fixed it. It was how I was defining the tip.

On that note. Not sure if I have the tip attachment values correct. I mean the dir and rotation.

I have it as this:
Leftarm_tip[0] = _V(-.377, .307, 1.497); Leftarm_tip[1] = _V(-.377, 1.307, 1.497), Leftarm_tip[2] = _V(-.377, 0.307, 2.497);
so direction is +y and rotation +Z
 

Attachments

  • SPSATTACHMENT.jpg
    SPSATTACHMENT.jpg
    11.4 KB · Views: 0

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Working on the VC.
Lisilas developed this. But he is not doing orbiter any more.
I tried a version of the MFD. Although the labels were on there. The button were too small so the labels extended beyond the button. I tried this way and the button work. Just no labels. The right MFD has the Camera MFD
 

Attachments

  • SPSVCISSUE.jpg
    SPSVCISSUE.jpg
    73.4 KB · Views: 4

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
I got the attachments to work:)

On the VC MFD. I get this. I think the buttons need to be dark and maybe rectangles? I can do squares but need to change the font.
 

Attachments

  • SPSVCISSUE2.jpg
    SPSVCISSUE2.jpg
    67 KB · Views: 8
  • SPSATTACHMENT3.jpg
    SPSATTACHMENT3.jpg
    84.3 KB · Views: 8
  • SPSATTACHMENT2.jpg
    SPSATTACHMENT2.jpg
    135.9 KB · Views: 8

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Trying to get all 3 mfds to work. Looking at code examples. The code sample had 1 MFD so trying to get the other 2 to work and not overlap
I sunk in the mfd screen just a bit.

I suppose that pressure gauge needs to be redone to use max 9000?
 

Attachments

  • SPSVCISSUE3.jpg
    SPSVCISSUE3.jpg
    62.7 KB · Views: 4

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Going back and forth on the VC. Looking at Atlantis code which has no button mesh. Can't tell if the DG has a button mesh. What I want is 3 acting MFD screens and functioning buttons for each.
 

Max-Q

99 40
Addon Developer
Joined
Jul 5, 2021
Messages
765
Reaction score
1,183
Points
108
Location
Cislunar Space
Website
www.orbiter-forum.com
Going back and forth on the VC. Looking at Atlantis code which has no button mesh. Can't tell if the DG has a button mesh. What I want is 3 acting MFD screens and functioning buttons for each.
Take a look at my DarkEnergy code. It is a lot easier to follow than the DG since everything is in one .cpp
It has 6 fully functioning MFDs with buttons that show text.
Not sure if this will be helpful or even what you are looking for or not.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Thanks. I will look at that. I will see what the VC mesh looks like
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
@Max-Q

Thanks. Trying to figure your code out. I got the buttons to paint. The font is way too small.

But I can't get the mfd to come on and click area. I have the mfd screens defined.
cdr1_mfd = { GRP_LeftMFDScreen }; plt1_mfd = { GRP_RightMFDScreen }; cntr1_mfd = { GRP_CentertMFDScreen };

bool SPS::clbkLoadVC(int id) { SetCameraOffset(_V(0, .595, 0)); SetCameraDefaultDirection(_V(0, -0.1908, 0.9816)); DefineMFDButtons(); oapiVCRegisterMFD(MFD_LEFT, &cdr1_mfd); oapiVCRegisterMFD(MFD_RIGHT, &plt1_mfd); oapiVCRegisterMFD(MFD_USER1, &cntr1_mfd); check_mfds = true; return true; }
 

Attachments

  • mfdissuefont.jpg
    mfdissuefont.jpg
    27.9 KB · Views: 1

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
Some progress and set back.

For some reason I get 2 out of 3 MFD to work.

All 3 mfd display the key data for mfd1. If I turn it off all the button display is gone.

Still can't turn on/off, change the displays


It nevers hit the vcmouseevent.

void SPS::clbkMFDMode(int mfd, int mode) { oapiVCTriggerRedrawArea(-1, ALL_MFD_BUTTONS); } //------------------------------------------------------------------------- bool SPS::clbkLoadVC(int id) { SetCameraOffset(_V(0, .595, 0)); SetCameraDefaultDirection(_V(0, -0.1908, 0.9816)); DefineMFDButtons(); oapiVCRegisterMFD(MFD_LEFT, &cdr1_mfd); oapiVCRegisterMFD(MFD_RIGHT, &plt1_mfd); oapiVCRegisterMFD(MFD_USER1, &cntr1_mfd); check_mfds = true; return true; } //------------------------------------------------------------------------- bool SPS::clbkVCMouseEvent(int id, int event, VECTOR3& p) { sprintf(oapiDebugString(), "Mouse position: X %f Y %f Z %f bt%d", p.x, p.y, p.z, id); if (id == CDR1_PWR) { if (fail_mfd[0] == 0) { oapiSendMFDKey(MFD_LEFT, OAPI_KEY_ESCAPE); } return true; }
bool SPS::clbkVCRedrawEvent(int id, int event, SURFHANDLE surf) { bool return_value = false; if (id == ALL_MFD_BUTTONS) { PaintMFDButtons(surf); return_value = true; } return return_value; } void SPS::PaintMFDButtons(SURFHANDLE surf) { HDC hDC = oapiGetDC(surf); for (int mfd = 0; mfd < 3; mfd++) { // D. Beachy: BUGFIX: if MFD powered off, do not paint buttons if (oapiGetMFDMode(mfd) == MFD_NONE) { } else { // MFD powered on sprintf(oapiDebugString(), "MFD MODE %d MFD %d ", oapiGetMFDMode(mfd), mfd); HFONT pFont = (HFONT)SelectObject(hDC, g_Param.font[0]); SetTextColor(hDC, RGB(255, 255, 255)); SetTextAlign(hDC, TA_CENTER); SetBkMode(hDC, TRANSPARENT); const char* label; int y = 16; for (int bt = 0; bt < 6; bt++) { if (label = oapiMFDButtonLabel(mfd, bt)) { TextOut(hDC, mfd_buttons_ypos[mfd], y, label, strlen(label)); y += 64; } else break; } int y2 = 16; for (int bt = 6; bt < 12; bt++) { if (label = oapiMFDButtonLabel(mfd, bt)) { TextOut(hDC, mfd_buttons_ypos[mfd] + 128, y2, label, strlen(label)); y2 += 64; } else break; } //TextOut (hDC, 234, 1, "PG", 2); SelectObject(hDC, pFont); } } oapiReleaseDC(surf, hDC); }
 

Attachments

  • spsdebug1.jpg
    spsdebug1.jpg
    39.9 KB · Views: 2
  • SPSMFDISSUE1.jpg
    SPSMFDISSUE1.jpg
    52.8 KB · Views: 2

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,693
Reaction score
2,671
Points
203
Location
Dallas, TX
SO following the dark Energy example. The texture/mesh for all 3 mfd are the same group. ( 1 group for the texture and 1 group for the button base. I wonder if they need to be separate? So each MFD has its own mesh group of buttons and textures?
 

Max-Q

99 40
Addon Developer
Joined
Jul 5, 2021
Messages
765
Reaction score
1,183
Points
108
Location
Cislunar Space
Website
www.orbiter-forum.com
On group and texture is fine, but each button needs is it's own area of the texture.
Did you define the VC buttons active areas in DefineMFDButtons() with correct xyz coordinates?
 
Last edited:
Top