Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A-10C data stops exporting after start #151

Closed
charliefoxtwo opened this issue Mar 11, 2023 · 12 comments
Closed

A-10C data stops exporting after start #151

charliefoxtwo opened this issue Mar 11, 2023 · 12 comments

Comments

@charliefoxtwo
Copy link
Member

The A10 will initially push data, and then it seems as if bios is crashing or something. Commenting out the old VHF and UHF code seems to fix this (however, these radios are used in the original A-10C so we probably can't just remove these lines).

@WarLord211
Copy link
Member

WarLord211 commented Mar 12, 2023

I have no problems at all?!

with the old radios maybe something can be done like:

if a-10C then old radios
if a-10C2 the new radios

@charliefoxtwo
Copy link
Member Author

I think we should figure out why you aren't having problems but other users are 🤔

It's happening for me in single and multithread openbeta.

@WarLord211
Copy link
Member

@WarLord211
Copy link
Member

still an issue?

@charliefoxtwo
Copy link
Member Author

Still having this issue. I can receive some string data, but not any integer data (update counter never moves).

Attached dcs.log and dcs-bios.log.

the bios log is almost entirely the following:

Util.lua: value -3.000000 is too small for address 4494 mask 15

Note that address 4494 mask 15 is VHFAM_FREQ1, which would have been affected by the arc-210 update.

DCS-BIOS.log
dcs.log

@WarLord211
Copy link
Member

These Entries in DCS_BIOS.log are there since i started with bios. They are no gamebrakers.
I dont know how i should handle them, since arguments/valves can physicaly only have a valve between -1 and 1. more is not possible. (modelviewer as reference)

but what crashes your output is in the DCS.log

BIOS related:
ERROR Lua::Config (Main): Call error LuaExportAfterNextFrame:[string "C:\Users\XXXXXXXX\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:142: bad argument #2 to 'format' (string expected, got table)

also a crash, but i dont know the programm:
ERROR Lua::Config (Main): Call error LuaExportStop:[string "C:\Users\XXXXXXX\Saved Games\DCS.openbeta\Scripts\Export_BEH_Motion_Cls.lua"]:133: attempt to index global 'c' (a nil value)

to the bios related:
What do you do in the plane? i cant repeat your error.
i start the A-10C2 hot and runing and parking on runway. i have no issues or log enries in the dcs.log

maybe booth programms work together? may concider testing without Export_BEH_Motion_Cls.lua

@charliefoxtwo
Copy link
Member Author

This occurred in one of the hot start missions on Sinai. It also happened earlier on a different in-flight hot start, also on Sinai.

I believe the BEH motion lua is for the Brunner device I have. I don't use it with dcs so I can certainly disable that lua and see if it makes a difference.

It's certainly possible for us to read a value outside of the expected range. When we build the luas for each plane we're just providing an address for each control. If we were to provide the wrong address, for example, then we could end up reading a different memory address than we expect and end up with some weird data.

@WarLord211
Copy link
Member

WarLord211 commented Jun 26, 2023

A-10C_Test.zip
This is the Test Mission i use. (in your log your'e using syria)

no BIOS log entries in DCS.log
dcs.log

DCS_BIOS.log looks different than yours
DCS-BIOS.log

this is my export lua.
Export.txt

Update Counter runs
2023-06-26

Master branch and my local dev branch atm the same.
DCS is latest open Beta i tested MT and single also standalone and steam
I can do what i want, i cant reproduce the problem :( Everything runs fine!

@emcek
Copy link
Contributor

emcek commented Sep 3, 2023

I have similar problem and it looks like it is somehow connected to SimShaker, with:

dofile(lfs.writedir()..[[Scripts\DCS-BIOS\BIOS.lua]])

dofile(lfs.writedir()..[[Scripts\SimShaker-export-core\ExportCore.lua]])
local SimShakerlfs=require('lfs'); dofile(SimShakerlfs.writedir()..'Scripts/SimShaker.lua')

I got error in dcs.log:

2023-09-03 11:34:23.428 INFO    TACVIEW.DLL (Main): Recording flight data in [D:\Users\mplic\Documents\Tacview\Tacview-20230903-133424-DCS-IA-A10CII-Caucasus-Takeoff.zip.acmi]
2023-09-03 11:34:23.499 ERROR   Lua::Config (Main): Call error LuaExportAfterNextFrame:[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:167: bad argument #2 to 'format' (string expected, got table)
stack traceback:
	[C]: ?
	[C]: in function 'format'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:167: in function 'setValue'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:663: in function 'v'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Protocol.lua"]:241: in function 'step'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\BIOS.lua"]:139: in function 'LuaExportAfterNextFrame'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\SimShaker-export-core\ExportCore.lua"]:62: in function 'SimLuaExportAfterNextFrame'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts/SimShaker.lua"]:575: in function <[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts/SimShaker.lua"]:572>.
2023-09-03 11:34:25.242 WARNING LOG (2700): 43 duplicate message(s) skipped.
2023-09-03 11:34:25.242 WARNING WORLD (Main): ModelTimeQuantizer: SAME MODEL TIME
2023-09-03 11:34:25.276 ERROR   Lua::Config (Main): Call error LuaExportAfterNextFrame:[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:167: bad argument #2 to 'format' (string expected, got table)
stack traceback:
	[C]: ?
	[C]: in function 'format'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:167: in function 'setValue'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Util.lua"]:663: in function 'v'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\lib\Protocol.lua"]:241: in function 'step'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\DCS-BIOS\BIOS.lua"]:139: in function 'LuaExportAfterNextFrame'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts\SimShaker-export-core\ExportCore.lua"]:62: in function 'SimLuaExportAfterNextFrame'
	[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts/SimShaker.lua"]:575: in function <[string "D:\Users\mplic\Saved Games\DCS.openbeta\Scripts/SimShaker.lua"]:572>.

and I can not see A-10C radio data.

Without SimShaker it is working. Looks like ptoblem is only related to A-10C since other planes are working correctlly.
I test it with SimShaker Beta 2.6.8 and both 0.7.49 and d1661d1

charliefoxtwo added a commit to charliefoxtwo/dcs-bios that referenced this issue Sep 14, 2023
Removes attempt to stringify a global variable which is never set (but can be set by other plugins). SimShaker had a table stored in a global variable `msg` for some reason, and when `setValue()` was called with a`nil` argument (which happens sometimes in the A-10, though that may be a separate issue) it attempted to format the table as a string, which is not supported.
@charliefoxtwo
Copy link
Member Author

WarLord211 added a commit that referenced this issue Sep 17, 2023
@charliefoxtwo
Copy link
Member Author

This should be fixed with the latest update. @emcek are you able to confirm?

@emcek
Copy link
Contributor

emcek commented Sep 18, 2023

Yes, both:

dofile(lfs.writedir()..[[Scripts\DCS-BIOS\BIOS.lua]])
dofile(lfs.writedir()..[[Scripts\SimShaker-export-core\ExportCore.lua]])
local SimShakerlfs=require('lfs'); dofile(SimShakerlfs.writedir()..'Scripts/SimShaker.lua')

and

dofile(lfs.writedir()..[[Scripts\SimShaker-export-core\ExportCore.lua]])
local SimShakerlfs=require('lfs'); dofile(SimShakerlfs.writedir()..'Scripts/SimShaker.lua')
dofile(lfs.writedir()..[[Scripts\DCS-BIOS\BIOS.lua]])

are working fine with: 8fa573f

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants