Although I've worked n the code, I don't know how the export works. Javelin was the last to work on that area, I think, so he'd probably be your best bet. But the forums have been pretty quiet, so not sure who's still around.
Hi Andy, I have no idea how to use the data, I've never done that. I only know that the exported values are listed in the Values.cpp file. The CommSIOCClient and CommUDPServer work with the game engine to export the values to the Client, which you somehow link to your gauges. You need to talk to someone who actually has a cockpit with working gauges. Sorry I'm not any help. Javelin
Hi, Andy. sorry for disappearance - my win7 died, and outdated comm programs doesn't seem to work with latest version. Can be fixed by recompiling client/server or game exe, but don't really have time to configure all that from scratch. But I can propose some code analyzes instead.
Most related ingame code stored in "sharedmem.c" file. Here script create object "shared_memory_t" type with "EECHSharedMemory" name (it is important) that will be used as data container for lamps states, upfront display, basic dynamics - pitch roll engines data etc. Full list in update_dynamics_shared_mem() function, also waypoints and weapons. Problem in any of the function can stop process, so it's worth to check debug version in case some asserts triggered (or at least enabled debug logging option in eech.ini).
Shared memory initialization happen on game load, single message should appear: Initialising Shared Memory
And another one can appear after it if something wrong: Failed to initialise shared memory
Last changes in this file:
by javelin 20.07.2019 (Commserver Fix, Joystick Deadbands Fix, Havoc Engine Gauges Added) Two new variables was added - num_flares and num_chaff. looks safe, even if these values can be extracted from weapons data array (I guess, maybe not). Version was changed from 3 to 4 (so only latest version of commserver/client can be used - i.e. compiled after value was changed).
by messyhead 27.03.2020 (Updating ekran display) ka50 ekran data added, looks ok. version was not changed.
And now how EECHCommUDPServer.exe reading and sending shared data.
Program using CreateFileMapping function to load shared file "EECHSharedMemory", parse it data and send to the client by TCP or UDP (not sure how it chose which one is required). To debug network exchange, you can add debugLevel value to the application args, like:
> EECHCommUDPServer 1234 1
so you will see in the console what is going on between client and server.
So first thing to check that your server/client EXEs was compiled after 20.07.2019 so they have new version number. or even maybe after 27.03.2020 as server uses same variables list? not sure but it may be an issue you experiencing. Maybe some programs exists that can load shared memory file by name so you will see that game pushing some data. Hope this information helps somehow. If not, I may try to make compilers work and test whole process some day.
Sorry to hear about your Windows dying. Hope you can get it fixed OK.
I tried running EECH 1.16.1 (didn't see any messages about Shared Memory during starting up) and used EECHCommUDPSpeed program (with the debug option enabled) that was in the cohokum folder when game installed. I assume it is the correct version as it was bundled with it.
I took a screenshot of the results from the CommUDPSpeed window.
In the UDPSpeed.log file there are only numerous lines (9 per second) stating "Error in data".
It looks to me like the program is outputing data but not in a form that the others can understand.
He had sent me a file "cohokum-test-14.exe" which I renamed to "cohokum.exe" and copied to cohokum folder (after renaming original).
Created a shortcut to file "EECHCommUDPServer" that he also sent me. This files timestamp is 07/07/2019.
Got everything fired up and going. Some of the data works !! All the floating point stuff can be seen changing in the debug window (heading,airspeed,vert speed,bar altitude, rad altitude combined torque,g force,fuel weight and time of day).
Switched over to original cohokum.exe and it's exactly the same. Floating point data changing on debug window. Still getting "INVALID COMMAND" responses and noting changes in UDPSpeed screen.
Very strange !!! It concerns me more than just for the UDPSpeed stuff. I was intending updating my simpit to the latest version, but I'm worried that it will stop all the indicators in the pit working.
I installed a package called "Packet Sender" on my laptop.
I started EECH and started up EECHCommUDPServer in debug mode.
I then sent a request string from my laptop to it "R/518" (navigation lights status). On the debug screen I saw the request listed and the reply also show as zero.
I then went in to the game and switched the navigation lights on. I repeated the above and the reply this time was "1".
So, from this test I think we can assume that EECHCommUDPServer is indeed working and returning data for proper requests.
It looks as if the problems are with the UDPSpeed program not asking for the data in the correct manner.
I also tried Javalin's "TestCommServer" in debug mode. I had to switch to TCP on the Packet Sender program, but the request was received. Unfortunately TestCommServer then closed down without a response.
Anyway, I think I'm getting somewhere, I'm just not sure where exactly !!!!
In the UDPSpeed folder there are a load of folders. In each folder is a .ini file. By opening them in turn I noticed that the parts that make up the frame of the dash (MFDs Top, Left, Middle, Right and Bottom) were all sending request strings of "1". I changed this to 20 (time of day) and the "INVALID" messages dissappeared.
I accidentally switched the top left panel to label mode instead of exiting and - everything started working. All the values and indicators. I opened the ini file in the "01 Left Panel" folder and noticed that one of the lines for the graphics didn't match. Instead of "Bitmap=Commanche_gearfail_L.bmp" which is the name of the graphic, it had "Bitmap=Commanche_gearfail_lit.bmp". I changed the line to match the graphic name and saved it. Unfortunately when I made the panel "Pibor" all the data stopped working. Switch it back to "Label" and the data works (but you can't see the landing gear panel).
Obviously at some point in the past somebody has changed the graphic and forgot to update the line in the ini file.
What's the program you're using on the 2nd monitor?
I've never used data export until recently as I've not had 2 monitors till now. But I only had it set to export MFD on the extra monitor (which is just my laptop main screen, and I play using the external monitor)
Stick the UDPSpeed folder in the C:\ drive and put the EECHCommUDPServer.exe in the root of the C:\.
Create a shortcut to the EECHCommUDPSpeedServer.exe on your desktop adding "10000" after the location. This tells it to listen on port 10000. Double click the UDPSpeed.exe file in the UDPSpeed folder. That should bring up the dashboard. You may need to move the graphics around to suit your screen. Start EECH and when you get to the first menu do ALT+TAB back to the desktop. Double click the shortcut you made earlier on the desktop. You should get a DOS style box saying "Listening on port 10000". Go back to the game and continue. When you get in to the cockpit you should see all the indicators working. There is still a problem with the top left section with the landing gear indicators that I'm working on.
You will have to play about with the MFD export locatiosn in EECH to get them in the two windows.