Code for I/O via printport

C and PASCAL (or any other high-level languages) in here please

Moderators: exxos, simonsunnyboy, Mug UK, Zorro 2, Moderator Team

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 2:15 am

Does anyone know of any code for driving the printer port for I/O ?
I know that PARCP is able to do, so it is possible.
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
Mug UK
Administrator
Administrator
Posts: 11210
Joined: Thu Apr 29, 2004 7:16 pm
Location: Stockport (UK)
Contact:

Re: Code for I/O via printport

Postby Mug UK » Sun Aug 21, 2011 8:56 am

Your best bet, if you have a copy of them, is to look through the programming section of the Floppyshop & ST Club CD-ROMs.
My main site: http://www.mug-uk.co.uk - slowly digging up the bits from my past (and re-working a few): Atari ST, Sega 8-bit (game hacks) and NDS (Music ripping guide).

I develop a free Word (for Windows) add-in that's available for Word 2007 upwards. It's a fix-it toolbox that will allow power Word users to fix document errors. You can find it at: http://www.mikestoolbox.co.uk

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 10:50 am

Thanks for the lead. I don't have them cdroms, will try to located them.
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
Mug UK
Administrator
Administrator
Posts: 11210
Joined: Thu Apr 29, 2004 7:16 pm
Location: Stockport (UK)
Contact:

Re: Code for I/O via printport

Postby Mug UK » Sun Aug 21, 2011 1:04 pm

Last catalogue of the ST Club

pd16.zip



Full Floppyshop catalogue

Floppyshop.zip
You do not have the required permissions to view the files attached to this post.
My main site: http://www.mug-uk.co.uk - slowly digging up the bits from my past (and re-working a few): Atari ST, Sega 8-bit (game hacks) and NDS (Music ripping guide).

I develop a free Word (for Windows) add-in that's available for Word 2007 upwards. It's a fix-it toolbox that will allow power Word users to fix document errors. You can find it at: http://www.mikestoolbox.co.uk

joska
Hardware Guru
Hardware Guru
Posts: 3696
Joined: Tue Oct 30, 2007 2:55 pm
Location: Florø, Norway
Contact:

Re: Code for I/O via printport

Postby joska » Sun Aug 21, 2011 2:54 pm

wongck wrote:Does anyone know of any code for driving the printer port for I/O ?
I know that PARCP is able to do, so it is possible.


Take a look at the sources for lp.xdd in the FreeMiNT sources.
Jo Even

Firebee - Falcon060 - Milan060 - Falcon040 - MIST - Mega ST - STM - STE - Amiga 600 - Sharp MZ700 - MSX - Amstrad CPC - C64

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 2:55 pm

:thumbs: Great stuff... Thanks
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 2:56 pm

Mug UK wrote:Last catalogue of the ST Club
pd16.zip

Full Floppyshop catalogue
Floppyshop.zip


Excellent will look at them. Thanks mate. :D
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 2:57 pm

joska wrote:
wongck wrote:Does anyone know of any code for driving the printer port for I/O ?
I know that PARCP is able to do, so it is possible.


Take a look at the sources for lp.xdd in the FreeMiNT sources.


Thanks for another lead. :D
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
rocket-dog
Atari Super Hero
Atari Super Hero
Posts: 779
Joined: Wed Mar 05, 2008 3:13 pm
Location: Great Britain - The Kingdom of Mercia

Re: Code for I/O via printport

Postby rocket-dog » Sun Aug 21, 2011 9:06 pm

Why do you want to know? What dastardly plot are you hatching young Wong? :mrgreen:

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Sun Aug 21, 2011 11:48 pm

rocket-dog wrote:Why do you want to know? What dastardly plot are you hatching young Wong? :mrgreen:

Not sure if anyone is interested, as it put the bulk of the ST/TT folks out.
Thinking of using the parallel port to talk to some embedded devices... like an ethernet device. But it needs 12 I/O lines... I think we can get away with 11 lines. Unfortunately, the ST & TT only has 10 I/O on the parallel and 1 of them is in only. I think we can get away with it on the Falcon.
Anyway, this is the embedded thingy I am looking at .... MOD-ENC624J600 at EUR20.

So I am researching ATM.

.... sorry MODS, this post ought to be in the h/w section :oops:
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

joska
Hardware Guru
Hardware Guru
Posts: 3696
Joined: Tue Oct 30, 2007 2:55 pm
Location: Florø, Norway
Contact:

Re: Code for I/O via printport

Postby joska » Mon Aug 22, 2011 7:26 am

wongck wrote:Not sure if anyone is interested, as it put the bulk of the ST/TT folks out.
Thinking of using the parallel port to talk to some embedded devices... like an ethernet device. But it needs 12 I/O lines... I think we can get away with 11 lines. Unfortunately, the ST & TT only has 10 I/O on the parallel and 1 of them is in only. I think we can get away with it on the Falcon.


You can use e.g. the handshake lines on the serial port for the extra lines on the ST/TT. Or you can bitbang SPI, but that would be more CPU intensive.
Jo Even

Firebee - Falcon060 - Milan060 - Falcon040 - MIST - Mega ST - STM - STE - Amiga 600 - Sharp MZ700 - MSX - Amstrad CPC - C64

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Mon Aug 22, 2011 11:45 am

OK, it ain't going to work because there is only 10 I/O lines from the Falcon plus 2 IN only lines. I need at least 11 lines for that Ethernet board.
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Mon Aug 22, 2011 11:48 am

joska wrote:You can use e.g. the handshake lines on the serial port for the extra lines on the ST/TT. Or you can bitbang SPI, but that would be more CPU intensive.


Getting an extra line from the serial... that's an idea.
I have seen those bitbang to SPI thingy.
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list

User avatar
charles
10 GOTO 10
10 GOTO 10
Posts: 2068
Joined: Tue Aug 17, 2004 12:11 am
Location: ont. Canada
Contact:

Re: Code for I/O via printport

Postby charles » Tue Aug 23, 2011 1:29 am

are these ports big endian little endian sensitive? midi port is ..a byte $80 or higher activates
and predicts its reception of data

you might be better off writing your own driver


do you use pure pascal wonck?


we knew this allready right?

charles
atari is my lifestyle,not a hobby.
HOLD ON ! ! !,
Im printing unreadable characters ...!

User avatar
wongck
Ultimate Atarian
Ultimate Atarian
Posts: 12011
Joined: Sat May 03, 2008 2:09 pm
Location: Far East
Contact:

Re: Code for I/O via printport

Postby wongck » Tue Aug 23, 2011 5:46 am

charles wrote:are these ports big endian little endian sensitive? midi port is ..a byte $80 or higher activates
and predicts its reception of data

you might be better off writing your own driver


do you use pure pascal wonck?


we knew this allready right?

charles


The beauty of that Ethernet device was it support both Intel and Motorola endians, according to the data sheets.
I only used Turbo-C on the IBM PC, years ago. No I do not use Pascal on the Atari.
My Stuff: FB/Falcon CT63+CTPCI_ATI_RTL8139 14+512MB 30GB HDD CF HxC_SD/ TT030 68882 4+32MB 520MB Nova/ 520STFM 4MB Tos206 SCSI
Shared SCSI Bus:ScsiLink ethernet, 9GB HDD,SD-reader @ http://phsw.atari.org
My Atari stuff for sale - click here for list


Social Media

     

Return to “C / PASCAL etc.”

Who is online

Users browsing this forum: No registered users and 1 guest