OHM WebMFD

Look out for angle brackets... There are dependencies in the orbitersdk.h file, what is your compiler? The OrbiterSDK folder contains properties and sample files to help you get started. The easiest way is to include an extra include and lib directory into the compiler and linker search paths.
 
I dont want to sample anything, I want to compile the WebMFD...


1>------ Build started: Project: WebMFD, Configuration: Debug Win32 ------
1> Server.cpp
1>c:\users\...\documents\orbiter2010\orbitersdk\ServerMFD.h(10): fatal error C1083: Cannot open include file: 'Orbitersdk.h': No such file or directory
1> LaunchpadWebMFD.cpp
1>c:\users\...\documents\orbiter2010\orbitersdk\ServerMFD.h(10): fatal error C1083: Cannot open include file: 'Orbitersdk.h': No such file or directory
1> ServerMFD.cpp
1>c:\users\...\documents\orbiter2010\orbitersdk\ServerMFD.h(10): fatal error C1083: Cannot open include file: 'Orbitersdk.h': No such file or directory
1> WebMFD.cpp
1>c:\users\...\documents\orbiter2010\orbitersdk\ServerMFD.h(10): fatal error C1083: Cannot open include file: 'Orbitersdk.h': No such file or directory
1> Generating Code...
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

The compiler does not see these files:

#include <Orbitersdk.h>
#include <atlimage.h>


I dunno why it cant find Orbitersdk.h because its everywhere now, but atlimage.h is nowhere to be found...
Is this source uncompilable?

I have compiled C++ sources before, but never wasted 2 hours. If you waste 2 hours compiling a C++ source which is tiny and simple, then there's something wrong.
 
Last edited:
Once I install the add-on in the Orbiter folder, then start orbiter, and go in to the Modules tab, to enable the WebMFD, then click on the WebMFD checkbox, I get an error message saying that MSVCR100.dll is missing.
 
Once I install the add-on in the Orbiter folder, then start orbiter, and go in to the Modules tab, to enable the WebMFD, then click on the WebMFD checkbox, I get an error message saying that MSVCR100.dll is missing.

You could also look at earlier comments. There was already reported this, as also the solution.
 
I installed the x64 Microsoft Visual C++ 2010 Redistributable Package, as I have a 64bit version of Windows 7, and it did nothing. Same error.
 
I installed the x64 Microsoft Visual C++ 2010 Redistributable Package, as I have a 64bit version of Windows 7, and it did nothing. Same error.

You need 32 bit redistributable, as the module, and Orbiter too, are 32 bit programs.
________________________________________

The compiler does not see these files:

#include <Orbitersdk.h>
#include <atlimage.h>


I dunno why it cant find Orbitersdk.h because its everywhere now, but atlimage.h is nowhere to be found...
Is this source uncompilable?

I have compiled C++ sources before, but never wasted 2 hours. If you waste 2 hours compiling a C++ source which is tiny and simple, then there's something wrong.

From looking at WebMFD.vcxproj from the package I was able to download (Nov. 12), there's set path to Orbiter VS inherited property sheets, which set include, library, and other paths for the project for you.

Check if "OrbiterDir" macro in "Orbitersdk/resources/orbiterroot.vsprops" is set to your Orbiter's root folder. Additionally, the relative path to those properties in the project is "../../resources", so you either need to change it if you have the sources elsewhere, or move the sources to "Orbitersdk/<some directory>/WebMFD" (<some directory> can be "Samples" for example).
 
Is this source uncompilable?

I have compiled C++ sources before, but never wasted 2 hours. If you waste 2 hours compiling a C++ source which is tiny and simple, then there's something wrong.

I have compiled the source myself, so I can say that it is definitely compilable.

I have put it into /Orbitersdk/samples/Orbiter-WebMFD . No modification of the compilation settings needed for me.

regards,
Face
 
I have compiled the source myself, so I can say that it is definitely compilable.

I have put it into /Orbitersdk/samples/Orbiter-WebMFD . No modification of the compilation settings needed for me.

regards,
Face

Hi,

Now I have a problem with atlimage.h but as far as I have found, it seems to be a problem with me using VS 2010 Express instead of a standard or pro. edition. I will download the trial of Pro. and try to compile it.

Thanks!

---------- Post added at 05:39 PM ---------- Previous post was at 04:26 PM ----------

Hi again,

I did compile it without errors but Orbiter crashes when I start a browser with the WebMFD IP and Port.

Can you send me a DLL file that you have compiled successfully? I might have done something wrong throughout the process...

Thanks in advance.
 
I installed the x64 Microsoft Visual C++ 2010 Redistributable Package, as I have a 64bit version of Windows 7, and it did nothing. Same error.

On a 64bit machine you need both the x64 and x86 versions of the redistributable, since you can run both x64 and x86 software on your computer. Orbiter is x86, so you need the x86 version. I linked you directly to the correct file to download.
 
I have some questions concerning this add-on.

Are there any precompiled dlls available for one of these newer versions?

Is anyone able to actually interact with the MFD's with Firefox?
If so, what version?
If not, maybe the requirements should be changed to Chrome only.

Even with one MFD and using Chrome, I got a lockup after 1 hour and 40 minutes.
 
Last edited:
I get :
procedure entry point wmemcpy_s could not be located in msvcr100.dll

msvcr100.dll ver 10.00.20327.1

This on Win XP sp3
 
I tried to compile Face1-Orbiter-WebMFD-v0.1-0-gf819974.zip and SalomonBrys-Orbiter-WebMFD-v0.1-0-gf24d0a8.zip and both compiled with a linker warning that I assumed I should ignore because of the automatic placement of the DLL in the plugins folder.

Unfortunately, when I connect I now just a get a blank screen where the MFD information should be. I can still see and interact with the buttons but no screen appears. I have tried the html that comes with the release, and both examples of html that come with the source but with the same result.

I don't think the the fix for the MFD was to blank the screen so I may have done something wrong in the compile process. I tried both release and debug versions of the DLL for both downloads. Do I have to use git to download the correct changes to the code?
 
Unfortunately, when I connect I now just a get a blank screen where the MFD information should be. I can still see and interact with the buttons but no screen appears. I have tried the html that comes with the release, and both examples of html that come with the source but with the same result.

I don't think the the fix for the MFD was to blank the screen so I may have done something wrong in the compile process. I tried both release and debug versions of the DLL for both downloads. Do I have to use git to download the correct changes to the code?

Did you try Chrome? I never got it to work with something else.

If you downloaded the tree-zip from github, the content should be exactly what you'd get with git itself. OTOH, I don't trust git too much, so maybe I'm wrong here.

regards,
Face
 
Yeah this is a strange problem. The released version (the one on OH) worked fine aside from the random lockups. I have tested with Chromium 6.0.472 on FreeBSD and Chrome 9.0.597 on Windows 7.

One reason I asked is the treezip is the same size and filename between branches. "master" "bitbltperformance" and "memoryleakfix" all have the file "Face1-Orbiter-WebMFD-v0.1-0-gf819974.zip" in their downloads section. Pretty confusing stuff.
 
One reason I asked is the treezip is the same size and filename between branches. "master" "bitbltperformance" and "memoryleakfix" all have the file "Face1-Orbiter-WebMFD-v0.1-0-gf819974.zip" in their downloads section. Pretty confusing stuff.

Git's "branches" are just pointers. They all point to commits, with the later being identified with hash-codes.

I don't know how you got the zip from the github side, but it seems to be the wrong hash-code. f819974 is the parent of my last memory-leak-fix, which is f24d0a8. Anyway, this link should give you the tip commit content: http://github.com/SalomonBrys/Orbiter-WebMFD/zipball/master

And I agree, git - and especially github - is pretty confusing at first encounter. Done by hackers - for hackers ;) .

regards,
Face
 
Thanks for that file. It is slightly different from the others I downloaded. I still get the same blank MFD though.

My exact steps on a clean Orbiter installation:
1.unzip folder to the orbiter sdk samples directory
2.open project in visual studio 2010 professional
3.clean project
4.build project
5.make sure module is enabled
6.start atlantis satellite launch scenario
7.connect with laptop with Chromium or with Chrome running on host pc
8.see a blank MFD with only buttons

Both web styles with both debug and release (4 combinations) seem to have a blank MFD.
 
Unexpected Response Code

I am attempting to use WebSockets to access WebMFD. I get "Unexpected Response Code: 400". This occurs on the first button connection request. The html transfer of the MFD body works OK. I am using the WebMFD.dll version: 10/31/2010 from OrbitHangar. Please help.

Thanks.

Here is the Chrome net-internals log:

WEB_SOCKET_SEND_REQUEST_HEADERS
--> GET /btn/?key=1 HTTP/1.1
Upgrade: websocket
Connection: Upgrade
Host: 127.0.0.1:8042
Origin: http://127.0.0.1:8042
Sec-WebSocket-Key: bSmimYpsePNYkZi38BqsNA==
Sec-WebSocket-Version: 13
Sec-WebSocket-Extensions: x-webkit-deflate-frame


SOCKET_STREAM_SENT
SOCKET_STREAM_RECEIVED
WEB_SOCKET_READ_RESPONSE_HEADERS
--> HTTP/1.0 400 BAD REQUEST

I looked at the source code and I see that 400 Bad Request can be for several reasons but I can't figure out how to get Chrome logging to show the next line of the response (after \r\n\r\n).

6/11/2012 - After lots of break points, I've found that new WebSocket only throws onclose with 1006 error code which is a user reserved code. It does not throw onerror. I still can't find the next line of the 400 Bad Request. I'm thinking my version 13 of WebSocket will not work with the old WebMFD.dll. I'm playing with subprotocols and binaryType. Suggestions appreciated.

6/18/2012 - It is a version problem. The Websocket button request in the current WebMFD expects an earlier, draft version of Websockets. The new RFC websockets has just sec-websocket-key and not sec-websocket-key1 and sec-websocket-key2. I optimistically attempted to change the code to look for just "key" but of course that causes failures in the response key code. From what I've read, the change to the RFC version of websockets by most browser has caused problems a lot more servers than WebMFD.
 
Last edited:
Would anybody venture to guess if this will work with an iPAD?

I just downloaded it and tried that. Works great so far! But I haven't extensively tested it yet.

The surface MFD updates rapidly. So far no performance issues.

This is exactly the thing I wanted for my iPad. Can't wait to test it further.
 
Back
Top