1. solved DCBII
- Posted by Kondor Attila <konel at DPG.HU> Mar 15, 2000
- 459 views
Hi Bernie, Thank you very much. I am very happy !! It seems so the WIN32.HLP is not uptodate. But DCB is the same in the Structures.h . Did you find better? Attila Kondor ---------------------------------------------------- Bernie Ryan <LockCityData at CS.COM> 2000.03.14. 17:26:40 -5h wrote: > Attila: > > -- This is what the structure should look like > > global constant > DCBlength = allot(DWord), -- offset: 0 > BaudRate = allot(DWord), -- offset: 4 > COMBINEDBITS = allot(DWord), -- offset: 8 > ------------------------ > -- These are bits and are all combined into the above DWord > -- fBinary 1 BIT > -- fParity 1 BIT > -- fOutxCtsFlow 1 BIT > -- fOutxDsrFlow 1 BIT > -- fDtrControl 2 BITS > -- fDsrSensitivity 1 BIT > -- fTXContinueOnXoff 1 BIT > -- fOutX 1 BIT > -- fInX 1 BIT > -- fErrorChar 1 BIT > -- fNull 1 BIT > -- fRtsControl 2 BIT > -- fAbortOnError 1 BIT > -- fDummy 17 BITS > -- -- which totals up to 32 bits ( a DWord ) > ------------------------ > wReserved = allot(Word), -- offset: 12 > XonLim = allot(Word), -- offset: 14 > XoffLim = allot(Word), -- offset: 16 > ByteSize = allot(Byte), -- offset: 18 > Parity = allot(Byte), -- offset: 19 > StopBits = allot(Byte), -- offset: 20 > XonChar = allot(Byte), -- offset: 21 > XoffChar = allot(Byte), -- offset: 22 > ErrorChar = allot(Byte), -- offset: 23 > EofChar = allot(Byte), -- offset: 24 > EvtChar = allot(Byte), -- offset: 25 > wReserved1 = allot(Word) -- offset: 26 > SIZE_OF_DCB=allotted_size() > -- The size will be #1C or 28 bytes > integer lpDCB > lpDCB=allocate_struct(SIZE_OF_DCB) > > Bernie
2. Re: solved DCBII
- Posted by Bernie Ryan <LockCityData at CS.COM> Mar 15, 2000
- 436 views
On Wed, 15 Mar 2000 15:10:23 +0100, Kondor Attila <konel at DPG.HU> wrote: >Hi Bernie, > >Thank you very much. I am very happy !! >It seems so the WIN32.HLP is not uptodate. >But DCB is the same in the Structures.h . >Did you find better? >Attila Kondor >> >> Attila: If you look at WIN32.HLP you will see that the BIT entries start with the letter "f", This means that this variable is is what is called a bit-field. So when you see an entry like this: DWORD fBinary: 1; This means fBinary is 1 bit in a 32 bit bit-field. The number after the colon ":" tells you how many bits. Bernie >> -- This is what the structure should look like >> >> global constant >> DCBlength = allot(DWord), -- offset: 0 >> BaudRate = allot(DWord), -- offset: 4 >> COMBINEDBITS = allot(DWord), -- offset: 8 >> ------------------------ >> -- These are bits and are all combined into the above DWord >> -- fBinary 1 BIT >> -- fParity 1 BIT >> -- fOutxCtsFlow 1 BIT >> -- fOutxDsrFlow 1 BIT >> -- fDtrControl 2 BITS >> -- fDsrSensitivity 1 BIT >> -- fTXContinueOnXoff 1 BIT >> -- fOutX 1 BIT >> -- fInX 1 BIT >> -- fErrorChar 1 BIT >> -- fNull 1 BIT >> -- fRtsControl 2 BIT >> -- fAbortOnError 1 BIT >> -- fDummy 17 BITS >> -- -- which totals up to 32 bits ( a DWord ) >> ------------------------ >> wReserved = allot(Word), -- offset: 12 >> XonLim = allot(Word), -- offset: 14 >> XoffLim = allot(Word), -- offset: 16 >> ByteSize = allot(Byte), -- offset: 18 >> Parity = allot(Byte), -- offset: 19 >> StopBits = allot(Byte), -- offset: 20 >> XonChar = allot(Byte), -- offset: 21 >> XoffChar = allot(Byte), -- offset: 22 >> ErrorChar = allot(Byte), -- offset: 23 >> EofChar = allot(Byte), -- offset: 24 >> EvtChar = allot(Byte), -- offset: 25 >> wReserved1 = allot(Word) -- offset: 26 >> SIZE_OF_DCB=allotted_size() >> -- The size will be #1C or 28 bytes >> integer lpDCB >> lpDCB=allocate_struct(SIZE_OF_DCB) >> >> Bernie
3. Re: solved DCBII
- Posted by Kondor Attila <konel at DPG.HU> Mar 16, 2000
- 455 views
Hi Bernie, Thank you . I am now more than happy! I know a bit more. Attila Kondor > >> > Attila: > >> > DWORD fBinary: 1; > > This means fBinary is 1 bit in a 32 bit bit-field. The number > after the colon ":" tells you how many bits. > > Bernie >