[Coco] Bit-Banger Serial as external console?

Gene Heskett gheskett at shentel.net
Tue Mar 26 17:21:35 EDT 2019


On Tuesday 26 March 2019 15:18:32 Stephen Pereira wrote:

> Hello again, folks,
>
> I took Arthur’s advice and started looking for BBS code.  I ended up
> looking at an article in the November 1983 Rainbow titled “Remote
> Operation of the Color Computer”.  It has exactly what I think I need.
>  The tiny assembly language program installs input & output from a
> remote terminal along with the normal keyboard and screen.  When
> running, a person at the remote terminal can operate the CoCo as if
> they were directly on the system.
>
> Of course, the trouble is that the program does not work for me on my
> CoCo 3.  The communication gets established, but the actual characters
> get scrambled in both directions.  I’ve tried 150, 300 and 600 Baud,
> as well as 1 or 2 stop bits, and 7 or 8 data bits.
>
> I’m concerned that maybe this code cannot work properly on the CoCo 3
> because it had not yet arrived?
>
> Here’s a copy of the code if anyone else would like to try it out. 
> Please let me know if you are successful!
>
> ********************************
> *           REMOTE             *
> *   A REMOTE TERMINAL DRIVER   *
> *        FOR THE COCO          *
> * DAN DOWNARD   RAINBOW  11/83 *
> ********************************
>         ORG     $3F00
> * EQUATES FOR ROM & RAM ADDRESSES
> IHOOK   EQU     $016A
> OHOOK   EQU     $0167
> PIA     EQU     $FF22
> POLCAT  EQU     $A000
That was never correct for any coco. I think what you want is $A002, but 
check your book for sure, my memory is now 30+ years old. There  may be 
other changes to the rest of these EQU's too due to the coco3's basic 
patches.
> RSOUT   EQU     $BE0C
> BAUD    EQU     $E6
> BAUDR   EQU     $C9
> DEV     EQU     $6F
> FLAG    EQU     $70
> * INITIALIZE RAM HOOKS
> START   LDA     #BAUDR
>         STA     <BAUD
>         LDX     1+OHOOK
>         STX     1+ORET2,PCR
>         LDX     1+IHOOK
>         STX     1+IRET2,PCR
>         LDA     #$7E
>         STA     IHOOK
>         STA     OHOOK
>         LEAX    OUT,PCR
>         STX     1+OHOOK
>         LEAX    IN,PCR
>         STX     1+IHOOK
> RET     RTS
> * OUTPUT CHARACTER IF DEV=0
> * INSERT LINE FEED TO REMOTE DEVICE
> * USE ROM SUBROUTINE
> OUT     PSHS    A
>         TST     <DEV
>         BNE     ORET1
>         CMPA    #$0D
>         BNE     REMOUT
>         LDA     #$0A
>         JSR     RSOUT
>         LDA     #$0D
> REMOUT  JSR     RSOUT
> ORET1   PULS    A
> ORET2   JMP     RET
> * INPUT FROM KEYBOARD OR RS-232
> * IF DEV=0
> * USE RSIN FOR REMOTE INPUT
> IN      CLR     <FLAG
>         TST     <DEV
>         BNE     IRET2
>         LEAS    2,S
>         PSHS    B,CC,X
> IN1     JSR     [POLCAT]
>         BEQ     REMIN
>         BRA     IRET1
> * CHECK FOR REMOTE INPUT
> REMIN   LDB     $FF22
>         RORB
>         BCS     IN1
> * RS-232 INPUT ROUTINE
> * BYTE INTO A REGISTER
> RSIN    BSR     HALF
>         LDB     #1
>         PSHS    B
>         CLRA
> RSIN1   BSR     FULL
>         LDB     PIA
>         RORB
>         BCC     RSIN2
>         ORA     0,S
> RSIN2   ASL     0,S
>         BCC     RSIN1
>         LEAS    1,S
>         ANDA    #$7F
> IRET1   PULS    B,CC,X,PC
> IRET2   JMP     RET
> * BAUD RATE DELAYS
> FULL    BSR     HALF
> HALF    PSHS    A
>         LDA     <BAUD
> HALF1   BRN     HALF1
>         DECA
>         BNE     HALF1
>         PULS    PC,A
>         END     START
>
>
> smp
> - - -
> Stephen Pereira
> Bedford, NH  03110
> KB1SXE
>
> > On Mar 26, 2019, at 2:03 PM, Chester A Patterson
> > <vchester at setec-cr.com> wrote:
> >
> > Years ago I used Cocos via their bit-bangers to communicate with
> > remote screens connected to scales in production lines. The scale
> > keyboard had three function keys to communicate back to the Coco. So
> > the scale operator interacted with the Coco all day. I enjoyed those
> > projects immensely.  I got the idea because of reading in Rainbow (I
> > think) of some oil drilling site that used a Coco to control the
> > drilling. Ages ago that.
> >
> > -----Original Message-----
> > From: Stephen Fischer <SFischer1 at Mindspring.com>
> > Sent: Monday, March 25, 2019 9:47 PM
> > To: coco at maltedmedia.com
> > Subject: Re: [Coco] Bit-Banger Serial as external console?
> >
> >
> > It is out of scope for your project,
> >
> > But I remember vaguely using OS-9 to log in on another computer
> > using the bit banger on the CoCo.
> >
> > If someone can confirm that, the NitrOS-9 source code might be
> > useful to look at.
> >
> > It has been 25 +- 10 or more years so my memory is very fuzzy.
> >
> > SHF
> >
> >
> >
> > --
> > Coco mailing list
> > Coco at maltedmedia.com
> > https://pairlist5.pair.net/mailman/listinfo/coco


Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>



More information about the Coco mailing list