diff --git a/bacnet-stack/ports/win32/bacnet/bacnet.dsp b/bacnet-stack/ports/win32/bacnet/bacnet.dsp index 20d0b1c9..5732a00a 100644 --- a/bacnet-stack/ports/win32/bacnet/bacnet.dsp +++ b/bacnet-stack/ports/win32/bacnet/bacnet.dsp @@ -67,7 +67,7 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c -# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D "BACDL_BIP" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /FR /FD /GZ /c +# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D BACDL_BIP=1 /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /D BIG_ENDIAN=0 /D USE_INADDR=0 /FR /FD /GZ /c # SUBTRACT CPP /YX # ADD BASE RSC /l 0x409 /d "_DEBUG" # ADD RSC /l 0x409 /d "_DEBUG" diff --git a/bacnet-stack/ports/win32/bacnet/bacnet.ncb b/bacnet-stack/ports/win32/bacnet/bacnet.ncb index 57dbc67e..4c36b3fe 100644 Binary files a/bacnet-stack/ports/win32/bacnet/bacnet.ncb and b/bacnet-stack/ports/win32/bacnet/bacnet.ncb differ diff --git a/bacnet-stack/ports/win32/bacnet/bacnet.opt b/bacnet-stack/ports/win32/bacnet/bacnet.opt index 74f473aa..3976004f 100644 Binary files a/bacnet-stack/ports/win32/bacnet/bacnet.opt and b/bacnet-stack/ports/win32/bacnet/bacnet.opt differ diff --git a/bacnet-stack/ports/win32/bacnet/bacnet.plg b/bacnet-stack/ports/win32/bacnet/bacnet.plg index 3871de27..e863066f 100644 --- a/bacnet-stack/ports/win32/bacnet/bacnet.plg +++ b/bacnet-stack/ports/win32/bacnet/bacnet.plg @@ -6,9 +6,9 @@ --------------------Configuration: bacnet - Win32 Debug--------------------

Command Lines

-Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with contents +Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP133F.tmp" with contents [ -/nologo /MLd /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D "BACDL_BIP" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /FR"Debug/" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c +/nologo /MLd /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D BACDL_BIP=1 /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /D BIG_ENDIAN=0 /D USE_INADDR=0 /FR"Debug/" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c "C:\code\bacnet-stack\abort.c" "C:\code\bacnet-stack\address.c" "C:\code\bacnet-stack\demo\object\ai.c" @@ -43,6 +43,7 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with conte "C:\code\bacnet-stack\indtext.c" "C:\code\bacnet-stack\demo\object\lsp.c" "C:\code\bacnet-stack\ports\win32\main.c" +"C:\code\bacnet-stack\demo\object\mso.c" "C:\code\bacnet-stack\demo\handler\noserv.c" "C:\code\bacnet-stack\npdu.c" "C:\code\bacnet-stack\reject.c" @@ -55,10 +56,9 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with conte "C:\code\bacnet-stack\demo\handler\txbuf.c" "C:\code\bacnet-stack\whois.c" "C:\code\bacnet-stack\wp.c" -"C:\code\bacnet-stack\demo\object\mso.c" ] -Creating command line "cl.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" -Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1255.tmp" with contents +Creating command line "cl.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP133F.tmp" +Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1340.tmp" with contents [ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:yes /pdb:"Debug/bacnet.pdb" /debug /machine:I386 /out:"Debug/bacnet.exe" /pdbtype:sept ".\Debug\abort.obj" @@ -95,6 +95,7 @@ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32 ".\Debug\indtext.obj" ".\Debug\lsp.obj" ".\Debug\main.obj" +".\Debug\mso.obj" ".\Debug\noserv.obj" ".\Debug\npdu.obj" ".\Debug\reject.obj" @@ -107,22 +108,17 @@ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32 ".\Debug\txbuf.obj" ".\Debug\whois.obj" ".\Debug\wp.obj" -".\Debug\mso.obj" ] -Creating command line "link.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1255.tmp" +Creating command line "link.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1340.tmp"

Output Window

Compiling... abort.c address.c ai.c -c:\code\bacnet-stack\demo\object\ai.c(87) : warning C4305: 'initializing' : truncation from 'const double ' to 'float ' -c:\code\bacnet-stack\demo\object\ai.c(125) : warning C4305: 'function' : truncation from 'const double ' to 'float ' ao.c -c:\code\bacnet-stack\demo\object\ao.c(163) : warning C4305: 'initializing' : truncation from 'const double ' to 'float ' apdu.c arf.c av.c -c:\code\bacnet-stack\demo\object\av.c(162) : warning C4305: 'initializing' : truncation from 'const double ' to 'float ' bacapp.c bacdcode.c bacerror.c @@ -137,8 +133,6 @@ bo.c bv.c crc.c Generating Code... -c:\code\bacnet-stack\demo\object\bacfile.c(322) : warning C4761: integral size mismatch in argument; conversion supplied -c:\code\bacnet-stack\bacapp.c(351) : warning C4761: integral size mismatch in argument; conversion supplied Compiling... datalink.c dcc.c @@ -154,31 +148,24 @@ iam.c indtext.c lsp.c main.c +mso.c noserv.c npdu.c reject.c ringbuf.c rp.c -s_rp.c Generating Code... -c:\code\bacnet-stack\demo\handler\s_rp.c(92) : warning C4761: integral size mismatch in argument; conversion supplied -c:\code\bacnet-stack\npdu.c(340) : warning C4761: integral size mismatch in argument; conversion supplied -c:\code\bacnet-stack\demo\handler\h_rp_a.c(73) : warning C4761: integral size mismatch in argument; conversion supplied Compiling... +s_rp.c s_whois.c s_wp.c tsm.c txbuf.c whois.c wp.c -mso.c -c:\code\bacnet-stack\demo\object\mso.c(308) : warning C4244: '=' : conversion from 'unsigned long ' to 'unsigned char ', possible loss of data -c:\code\bacnet-stack\demo\object\mso.c(333) : warning C4244: '=' : conversion from 'unsigned long ' to 'unsigned char ', possible loss of data Generating Code... -c:\code\bacnet-stack\wp.c(134) : warning C4761: integral size mismatch in argument; conversion supplied -c:\code\bacnet-stack\demo\handler\s_wp.c(95) : warning C4761: integral size mismatch in argument; conversion supplied Linking... -Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with contents +Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1342.tmp" with contents [ /nologo /o"Debug/bacnet.bsc" ".\Debug\abort.sbr" @@ -215,6 +202,7 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with conte ".\Debug\indtext.sbr" ".\Debug\lsp.sbr" ".\Debug\main.sbr" +".\Debug\mso.sbr" ".\Debug\noserv.sbr" ".\Debug\npdu.sbr" ".\Debug\reject.sbr" @@ -226,16 +214,15 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with conte ".\Debug\tsm.sbr" ".\Debug\txbuf.sbr" ".\Debug\whois.sbr" -".\Debug\wp.sbr" -".\Debug\mso.sbr"] -Creating command line "bscmake.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" +".\Debug\wp.sbr"] +Creating command line "bscmake.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1342.tmp" Creating browse info file...

Output Window

Results

-bacnet.exe - 0 error(s), 13 warning(s) +bacnet.exe - 0 error(s), 0 warning(s) diff --git a/bacnet-stack/ports/win32/bacnet/readme.txt b/bacnet-stack/ports/win32/bacnet/readme.txt index 34a1e05d..ef74afff 100644 --- a/bacnet-stack/ports/win32/bacnet/readme.txt +++ b/bacnet-stack/ports/win32/bacnet/readme.txt @@ -4,6 +4,30 @@ Build for Visual C++ 6.0 When building the BACnet stack using Visual C++ compiler, there are some settings that are important. +Q. Are there some global configuration options for this BACnet stack? + +A. The BACnet stack uses some preprocessor defines to configure +a number of subtle personalities. +PRINT_ENABLED=1 - enables printing to stdio +BIG_ENDIAN=0 - chooses the BACnet encoding and decoding order +BACDL_BIP=1 - chooses BACnet/IP for the datalink layer +BACDL_ETHERNET=0 - chooses BACnet Ethernet for the datalink layer +BACDL_ARCNET=0 - chooses BACnet ARCNET for the datalink layer +BACDL_MSTP=0 - chooses BACnet MS/TP for the datalink layer +USE_INADDR=1 - uses INADDR_BROADCAST for broadcast rather than CLASSx +TSM_ENABLED=1 - enables the Transaction State Machine for clients +BIP_DEBUG=1 - enables print statements for debugging +In Visual C++, add a Preprocessor Definition by: +1. Select "Project" menu +2. Select "Settings..." +3. Select the "C/C++" tab (3rd Tab) +4. Select the Category: General +5. You can see the "Preprocessor Definitions:" box +6. Type OPTION_NAME=1 or OPTION_NAME=0 in that edit box + using a comma to separate multiple options. +7. Press OK +8. Compile the entire project again... + Q. MSVC refuses to open bacnet.dsw and bacnet.dsp. A. bacnet.dsw and bacnet.dsp are text files that were retrieved @@ -51,6 +75,19 @@ its datalink layer. In Visual C++, add a Preprocessor Definition by: 7. Press OK 8. Compile the entire project again... +Q. error LNK2001: unresolved external symbol _bacapp_print + +A. The BACnet stack uses a preprocessor define to configure +printing to stdio. In Visual C++, add a Preprocessor Definition by: +1. Select "Project" menu +2. Select "Settings..." +3. Select the "C/C++" tab (3rd Tab) +4. Select the Category: General +5. You can see the "Preprocessor Definitions:" box +6. Type PRINT_ENABLED=1 in that edit box (using a comma if necessary) +7. Press OK +8. Compile the entire project again... + Q. error LNK2001: unresolved external symbol __imp__closesocket@4 A. Visual C++ needs to have the Winsock library to be happy: