<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.2.3" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: Serial Communications: A C++ Developer&#8217;s Guide, 2nd Edition</title>
	<link>http://marknelson.us</link>
	<description>Programming, mostly.</description>
	<pubDate>Thu, 11 Mar 2010 18:55:14 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.2.3</generator>

	<item>
		<title>By: Mark Nelson</title>
		<link>http://marknelson.us/about/serial2/#comment-321342</link>
		<dc:creator>Mark Nelson</dc:creator>
		<pubDate>Wed, 13 Jan 2010 19:04:08 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-321342</guid>
		<description>@FJOHN:

I think you should still be able to get the interrupt driven code in the book to work on Visual C++ 2008, although it might take some tweaking.

The problem of course is the platform. This code will only run in an MS-DOS compatibility box, and who knows how well. 

The Win32 driver gives you the ability to change the state of RTS, but not at the interrupt level.

- Mark</description>
		<content:encoded><![CDATA[<p>@FJOHN:</p>
<p>I think you should still be able to get the interrupt driven code in the book to work on Visual C++ 2008, although it might take some tweaking.</p>
<p>The problem of course is the platform. This code will only run in an MS-DOS compatibility box, and who knows how well. </p>
<p>The Win32 driver gives you the ability to change the state of RTS, but not at the interrupt level.</p>
<p>- Mark</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: FJOHN</title>
		<link>http://marknelson.us/about/serial2/#comment-321341</link>
		<dc:creator>FJOHN</dc:creator>
		<pubDate>Wed, 13 Jan 2010 18:47:27 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-321341</guid>
		<description>I am looking for an interrupt driven program for serial communication using RS232 port in visual C++ 2008 version 9 platform.

I would like to send/ receive data and change the status of RTS ,.... I want to be able to change the receive interrupt rutine as ai wish.

Can I find such a program in your book? do you know where I can find/buy this program code?

Thanks,
John</description>
		<content:encoded><![CDATA[<p>I am looking for an interrupt driven program for serial communication using RS232 port in visual C++ 2008 version 9 platform.</p>
<p>I would like to send/ receive data and change the status of RTS ,&#8230;. I want to be able to change the receive interrupt rutine as ai wish.</p>
<p>Can I find such a program in your book? do you know where I can find/buy this program code?</p>
<p>Thanks,<br />
John</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Serial Communications A C++ Developers Guide 2nd Edition</title>
		<link>http://marknelson.us/about/serial2/#comment-320691</link>
		<dc:creator>Serial Communications A C++ Developers Guide 2nd Edition</dc:creator>
		<pubDate>Thu, 31 Dec 2009 08:28:49 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-320691</guid>
		<description>[...] Win32Port.h  If you are developing for a Windows 2000 target, or for NT 4 with SP3 or later, you will need to modify a single line in Win32Port.h. Around line 76 of this file, you will find a line of code that looks like this:  PLAIN TEXT [...]</description>
		<content:encoded><![CDATA[<p>[&#8230;] Win32Port.h  If you are developing for a Windows 2000 target, or for NT 4 with SP3 or later, you will need to modify a single line in Win32Port.h. Around line 76 of this file, you will find a line of code that looks like this:  PLAIN TEXT [&#8230;]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Feng Bin</title>
		<link>http://marknelson.us/about/serial2/#comment-265225</link>
		<dc:creator>Feng Bin</dc:creator>
		<pubDate>Wed, 21 Jan 2009 08:59:21 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-265225</guid>
		<description>Dear NelSon,
 Currently I'm doing serial communication project by using Windows API in Visual Studio 2008 standard version platform. Because in my project, com port worked in a very high speed (921600 bps), receiver loss data in most of testing time. There is few document related to such high speed. Can you give me some advice on this issue?
 Thanks you very much!</description>
		<content:encoded><![CDATA[<p>Dear NelSon,<br />
 Currently I&#8217;m doing serial communication project by using Windows API in Visual Studio 2008 standard version platform. Because in my project, com port worked in a very high speed (921600 bps), receiver loss data in most of testing time. There is few document related to such high speed. Can you give me some advice on this issue?<br />
 Thanks you very much!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Nelson</title>
		<link>http://marknelson.us/about/serial2/#comment-253858</link>
		<dc:creator>Mark Nelson</dc:creator>
		<pubDate>Thu, 18 Dec 2008 14:35:29 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-253858</guid>
		<description>@ssinfod:

No, I can't explain the problem. Remember, this code was written back in the Windows 3.1 days, so timing issues on faster processors under Windows 95 and XP are bound to appear.</description>
		<content:encoded><![CDATA[<p>@ssinfod:</p>
<p>No, I can&#8217;t explain the problem. Remember, this code was written back in the Windows 3.1 days, so timing issues on faster processors under Windows 95 and XP are bound to appear.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ssinfod</title>
		<link>http://marknelson.us/about/serial2/#comment-253331</link>
		<dc:creator>ssinfod</dc:creator>
		<pubDate>Wed, 17 Dec 2008 04:31:06 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-253331</guid>
		<description>Hi Mr Nelson, 

I was looking for a way to do ZModem in a Win32 environnement. So I used the information in chapter 12 and chapter 16. Now, my application is working fine. 

During the process of testing the application, I had some problem with the ZModem sender.

I finally resolved the problem by adding the line :

[c]
while (port-&#62;TXSpaceUsed()){;}
[/c]

in the "SendFileContents" function.

Without that line, then sender/receiver was always stuck after 2 packets. (2048 bytes).

It seems that the driver was not sending the data quick enough...

Do you know why I need to add this line ? Is it a problem with the Win32 driver ? It's because the program was working fine in DOS without this line.

Let me know if you want the project source code so you could post it on your website.

Thanks for your answer and for your very good book.
ssinfod

Here is the function :

[c]
int Zmodem::SendFileContents( void )
{
    int c;
    int e;
    int n;
    int junkcount;
    int newcnt;

    junkcount = 0;

start_read:
    newcnt = receiver_buffer_length;
    PackLongIntoHeader( transmitted_file_position );
    SendBinaryHeader( 4, ZDATA, transmitted_header );
    do {
        n = fread( buffer, 1, 1024, file );

        while (port-&#62;TXSpaceUsed()){;}                                          // Addon: Win32 wait for buffer to be empty.

        if ( n  3 )
            e = ZCRCW;
        else if ( byte_count == last_sync_position )
            e = ZCRCW;
        else if ( receiver_buffer_length &#38;&#38; ( newcnt -= n ) RXSpaceUsed() ) {
            switch ( ReadChar( 100 ) ) {
                case CAN:
                case ZPAD:
                    c = SyncWithReceiver( 1 );
                    if ( c == ZACK )
                        break;
                    SendDataFrame( buffer, 0, ZCRCE );
                    goto gotack;
                case XOFF:
                case XOFF &#124; 0x80 :
                    ReadChar( 10000L );
                default:
                    junkcount++;
            }
        }
    } while ( !file_at_eof );
    for ( ; ; ) {
        PackLongIntoHeader( transmitted_file_position );
        SendBinaryHeader( 4, ZEOF, transmitted_header );
        switch ( SyncWithReceiver( 0 ) ) {
            case ZACK:
                continue;
            case ZRPOS:
                goto start_read;
            case ZRINIT:
                return OK;
            case ZSKIP:
                fclose( file );
                return c;
            default:
                fclose( file );
                return ERROR;
        }
    }

//Backchannel processing

waitack:
    junkcount = 0;
    c = SyncWithReceiver( 0 );
gotack:
    switch ( c ) {
        default:
        case ZCAN:
            fclose( file );
            return ERROR;
        case ZSKIP:
            fclose( file );
            return c;
        case ZACK:
        case ZRPOS:
            break;
        case ZRINIT:
            return OK;
    }
    while ( port-&#62;RXSpaceUsed() ) {
        switch ( ReadChar( 100 ) ) {
            case CAN:
            case ZPAD:
                c = SyncWithReceiver( 1 );
                goto gotack;
            case XOFF :
            case XOFF &#124; 0x80 :
                ReadChar( 10000L );
        }
    }
    goto start_read;
}
[/c]</description>
		<content:encoded><![CDATA[<p>Hi Mr Nelson, </p>
<p>I was looking for a way to do ZModem in a Win32 environnement. So I used the information in chapter 12 and chapter 16. Now, my application is working fine. </p>
<p>During the process of testing the application, I had some problem with the ZModem sender.</p>
<p>I finally resolved the problem by adding the line :</p>
<div class="igBar"><span id="lc-1"><a href="#" onclick="javascript:showPlainTxt('c-1'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">C:</span>
<div id="c-1">
<div class="c">
<ol>
<li class="li1">
<div class="de1"><span class="kw1">while</span> <span class="br0">&#40;</span>port-&amp;gt;TXSpaceUsed<span class="br0">&#40;</span><span class="br0">&#41;</span><span class="br0">&#41;</span><span class="br0">&#123;</span>;<span class="br0">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>in the "SendFileContents" function.</p>
<p>Without that line, then sender/receiver was always stuck after 2 packets. (2048 bytes).</p>
<p>It seems that the driver was not sending the data quick enough...</p>
<p>Do you know why I need to add this line ? Is it a problem with the Win32 driver ? It's because the program was working fine in DOS without this line.</p>
<p>Let me know if you want the project source code so you could post it on your website.</p>
<p>Thanks for your answer and for your very good book.<br />
ssinfod</p>
<p>Here is the function :</p>
<div class="igBar"><span id="lc-2"><a href="#" onclick="javascript:showPlainTxt('c-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">C:</span>
<div id="c-2">
<div class="c">
<ol>
<li class="li1">
<div class="de1"><span class="kw4">int</span> Zmodem::<span class="me2">SendFileContents</span><span class="br0">&#40;</span> <span class="kw4">void</span> <span class="br0">&#41;</span></div>
</li>
<li class="li2">
<div class="de2"><span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw4">int</span> c;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="kw4">int</span> e;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw4">int</span> n;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="kw4">int</span> junkcount;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw4">int</span> newcnt;</div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; junkcount = <span class="nu0">0</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">start_read:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; newcnt = receiver_buffer_length;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; PackLongIntoHeader<span class="br0">&#40;</span> transmitted_file_position <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; SendBinaryHeader<span class="br0">&#40;</span> <span class="nu0">4</span>, ZDATA, transmitted_header <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">do</span> <span class="br0">&#123;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; n = fread<span class="br0">&#40;</span> buffer, <span class="nu0">1</span>, <span class="nu0">1024</span>, file <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">while</span> <span class="br0">&#40;</span>port-&amp;gt;TXSpaceUsed<span class="br0">&#40;</span><span class="br0">&#41;</span><span class="br0">&#41;</span><span class="br0">&#123;</span>;<span class="br0">&#125;</span>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="co1">// Addon: Win32 wait for buffer to be empty.</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> n&nbsp; <span class="nu0">3</span> <span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e = ZCRCW;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">else</span> <span class="kw1">if</span> <span class="br0">&#40;</span> byte_count == last_sync_position <span class="br0">&#41;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e = ZCRCW;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">else</span> <span class="kw1">if</span> <span class="br0">&#40;</span> receiver_buffer_length &amp;amp;&amp;amp; <span class="br0">&#40;</span> newcnt -= n <span class="br0">&#41;</span> RXSpaceUsed<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">switch</span> <span class="br0">&#40;</span> ReadChar<span class="br0">&#40;</span> <span class="nu0">100</span> <span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> CAN:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZPAD:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; c = SyncWithReceiver<span class="br0">&#40;</span> <span class="nu0">1</span> <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">if</span> <span class="br0">&#40;</span> c == ZACK <span class="br0">&#41;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw2">break</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; SendDataFrame<span class="br0">&#40;</span> buffer, <span class="nu0">0</span>, ZCRCE <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">goto</span> gotack;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> XOFF:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> XOFF | 0x80 :</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ReadChar<span class="br0">&#40;</span> 10000L <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">default</span>:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; junkcount++;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="br0">&#125;</span> <span class="kw1">while</span> <span class="br0">&#40;</span> !file_at_eof <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">for</span> <span class="br0">&#40;</span> ; ; <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; PackLongIntoHeader<span class="br0">&#40;</span> transmitted_file_position <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; SendBinaryHeader<span class="br0">&#40;</span> <span class="nu0">4</span>, ZEOF, transmitted_header <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">switch</span> <span class="br0">&#40;</span> SyncWithReceiver<span class="br0">&#40;</span> <span class="nu0">0</span> <span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZACK:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">continue</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZRPOS:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">goto</span> start_read;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZRINIT:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> OK;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZSKIP:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fclose<span class="br0">&#40;</span> file <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> c;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">default</span>:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fclose<span class="br0">&#40;</span> file <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> ERROR;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2"><span class="co1">//Backchannel processing</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
<li class="li2">
<div class="de2">waitack:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; junkcount = <span class="nu0">0</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; c = SyncWithReceiver<span class="br0">&#40;</span> <span class="nu0">0</span> <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">gotack:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="kw1">switch</span> <span class="br0">&#40;</span> c <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">default</span>:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZCAN:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fclose<span class="br0">&#40;</span> file <span class="br0">&#41;</span>;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> ERROR;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZSKIP:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; fclose<span class="br0">&#40;</span> file <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> c;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZACK:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZRPOS:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw2">break</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZRINIT:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">return</span> OK;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="kw1">while</span> <span class="br0">&#40;</span> port-&amp;gt;RXSpaceUsed<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">switch</span> <span class="br0">&#40;</span> ReadChar<span class="br0">&#40;</span> <span class="nu0">100</span> <span class="br0">&#41;</span> <span class="br0">&#41;</span> <span class="br0">&#123;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> CAN:</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> ZPAD:</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; c = SyncWithReceiver<span class="br0">&#40;</span> <span class="nu0">1</span> <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">goto</span> gotack;</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> XOFF :</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw1">case</span> XOFF | 0x80 :</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ReadChar<span class="br0">&#40;</span> 10000L <span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; <span class="br0">&#125;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; <span class="kw1">goto</span> start_read;</div>
</li>
<li class="li2">
<div class="de2"><span class="br0">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Nelson</title>
		<link>http://marknelson.us/about/serial2/#comment-134874</link>
		<dc:creator>Mark Nelson</dc:creator>
		<pubDate>Fri, 16 May 2008 02:24:26 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-134874</guid>
		<description>@amp:

The good people at Amazon.com will let you look inside the book here:

http://www.amazon.com/Serial-Communications-Developers-Guide-Nelson/dp/0764545701

Just go to the table of contents and you can see what you need. I f you have specific questions about content I'll try to answer them here or in email.

- Mark</description>
		<content:encoded><![CDATA[<p>@amp:</p>
<p>The good people at Amazon.com will let you look inside the book here:</p>
<p><a href="http://www.amazon.com/Serial-Communications-Developers-Guide-Nelson/dp/0764545701" rel="nofollow">http://www.amazon.com/Serial-Communications-Developers-Guide-Nelson/dp/0764545701</a></p>
<p>Just go to the table of contents and you can see what you need. I f you have specific questions about content I'll try to answer them here or in email.</p>
<p>- Mark</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: amp</title>
		<link>http://marknelson.us/about/serial2/#comment-130073</link>
		<dc:creator>amp</dc:creator>
		<pubDate>Wed, 07 May 2008 10:29:03 +0000</pubDate>
		<guid>http://marknelson.us/about/serial2/#comment-130073</guid>
		<description>I would be grateful if you could send me detail table of contents or some links where I can find it. I need it to make decision to buy this book or not.</description>
		<content:encoded><![CDATA[<p>I would be grateful if you could send me detail table of contents or some links where I can find it. I need it to make decision to buy this book or not.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
