Issues with Converting Binary Array to Decimal Value in MATLAB DLL for C++ Integration
Hello everyone,
I want to convert a binary array to a decimal value. When using MATLAB functions like bi2de and bit2int and then compiling them into a DLL using the library compiler, calling them from C++ results in errors indicating that the library could not be initialized. Is there an alternative MATLAB function that can be compiled into a DLL and called from C++ without issues?
I have also tried using a combination of bin2dec(num2str()), which loads the DLL correctly after compilation, but the execution results are incorrect. The result is displayed as a huge decimal number. What could be the reason for this?Hello everyone,
I want to convert a binary array to a decimal value. When using MATLAB functions like bi2de and bit2int and then compiling them into a DLL using the library compiler, calling them from C++ results in errors indicating that the library could not be initialized. Is there an alternative MATLAB function that can be compiled into a DLL and called from C++ without issues?
I have also tried using a combination of bin2dec(num2str()), which loads the DLL correctly after compilation, but the execution results are incorrect. The result is displayed as a huge decimal number. What could be the reason for this? Hello everyone,
I want to convert a binary array to a decimal value. When using MATLAB functions like bi2de and bit2int and then compiling them into a DLL using the library compiler, calling them from C++ results in errors indicating that the library could not be initialized. Is there an alternative MATLAB function that can be compiled into a DLL and called from C++ without issues?
I have also tried using a combination of bin2dec(num2str()), which loads the DLL correctly after compilation, but the execution results are incorrect. The result is displayed as a huge decimal number. What could be the reason for this? binary array, decimal value, matlab compiler, dll MATLAB Answers — New Questions