InpOut32.h has syntax errrors

My x64 port of InpOut32
Post Reply
rchan
New User
Posts: 3
Joined: Tue Mar 24, 2009 5:59 pm

InpOut32.h has syntax errrors

Post by rchan »

Hi there,
firstly thanks Phil for the driver. Been trying to get TTL pulse going from the parallel port of XP 64 bit box for the last week or so. With your software it now DONE!

Problem is I had to comment out all the functions in the header file except Inp32 and Out32 because of the errors. Any clues why? I'm running a Dell Precision T5400 with XP 64 Professional. Code was linked with both Visual C++ Express 2008 and Mathlab 2008b with similar errors.

Cheers,
Raymond
User avatar
phil
Site Admin
Posts: 7664
Joined: Sun Apr 06, 2003 11:12 pm

Re: InpOut32.h has syntax errrors

Post by phil »

Urr, it might help if you actually told me what syntax errors you are seeing!
Without that information it is completely impossible to tell!

Paste the compiler output/log here and maybe all will become clear. :)

Thanks,
Phil
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
rchan
New User
Posts: 3
Joined: Tue Mar 24, 2009 5:59 pm

Re: InpOut32.h has syntax errrors

Post by rchan »

Hi,
that was incredibly silly of me. Here is the Visual C++ compilation error

1>------ Build started: Project: InpOut32, Configuration: Debug Win32 ------
1>Compiling...
1>test1.c
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(10) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(11) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(14) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(14) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(14) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(14) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(14) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(15) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(15) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(15) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(15) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(15) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(17) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(17) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(17) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(17) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(17) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(18) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(18) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(18) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(18) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(18) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(20) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(20) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(20) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(20) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(20) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(21) : error C2146: syntax error : missing ')' before identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(21) : error C2061: syntax error : identifier 'port'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(21) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(21) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(21) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2146: syntax error : missing ')' before identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2061: syntax error : identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(24) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2146: syntax error : missing ')' before identifier 'PhysicalMemoryHandle'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2061: syntax error : identifier 'PhysicalMemoryHandle'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(25) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2146: syntax error : missing ')' before identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2061: syntax error : identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(26) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2143: syntax error : missing '{' before '__stdcall'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2146: syntax error : missing ')' before identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2061: syntax error : identifier 'pbPhysAddr'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2059: syntax error : ';'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2059: syntax error : ','
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\inpout32.h(27) : error C2059: syntax error : ')'
1>c:\documents and settings\rchan\my documents\visual studio 2008\projects\inpout32\inpout32\test1.c(5) : warning C4020: 'Inp32' : too many actual parameters
1>Build log was saved at "file://c:\Documents and Settings\rchan\My Documents\Visual Studio 2008\Projects\InpOut32\InpOut32\Debug\BuildLog.htm"
1>InpOut32 - 56 error(s), 1 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

The mathlab less of the of them but they intersect with the C++ ones.
User avatar
phil
Site Admin
Posts: 7664
Joined: Sun Apr 06, 2003 11:12 pm

Re: InpOut32.h has syntax errrors

Post by phil »

I'm guessing that for some reason your don't have definitions for
BOOL, UCHAR, USHORT, ULONG, PBYTE and bool

I thought these are C++ types so I don't know why your environment would not have those defined - maybe its more MS specific than I thought or maybe your missing an include somewhere.

Either way it is safe to remove everything after the comment line
//My extra functions for making life easy

Unless you really want to call one of my "make life easy" functions, in which case you will have to include the relevant file that defines those types

Does that make sense?

Thanks,
Phil
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9/G604/M720/MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, AMD Ryzen 5900x, MSI x570 Tomahawk, 32GB DDR4,
nVidia RTX 2070s, Evo 970 1Tb NVME, 2x2TB WD Black (RAID1)
rchan
New User
Posts: 3
Joined: Tue Mar 24, 2009 5:59 pm

Re: InpOut32.h has syntax errrors

Post by rchan »

Yup thought as much.

Did a quick google and am pretty sure thats they are not from standard (ansi ?) C++ libraries. Any idea where and what the missing header file could be? Just guess a starting point would be nice! I'm really unused to this MS thing without /src/headers/ and such.
Post Reply