sequential bytes to a com port
How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs. I want to dump program files to a serial paper tape punch. I am actually using QB64 (which I love) that parses BASIC source to C++ and compiles it. Very fast and reputed to be compatible. -- Duane Craps sdɐɹɔ ǝuɐnp -- DuaneCraps sdɐɹɔ ǝuɐnp
Some code here you can look at? The thread is about reading serial data, but you could open for output instead of input. However I couldn't find any specific doc that verifies QB64->C++ serial api is supported. https://forum.vcfed.org/index.php?threads/qbasic-sending-characters-by-seria... On Tue, Nov 8, 2022 at 5:19 PM Duane Craps via vcf-midatlantic < vcf-midatlantic@lists.vcfed.org> wrote:
How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs.
I want to dump program files to a serial paper tape punch.
I am actually using QB64 (which I love) that parses BASIC source to C++ and compiles it. Very fast and reputed to be compatible.
-- Duane Craps sdɐɹɔ ǝuɐnp
-- DuaneCraps sdɐɹɔ ǝuɐnp
On 11/8/22 18:40, Bart Hirst via vcf-midatlantic wrote:
Some code here you can look at? The thread is about reading serial data, but you could open for output instead of input. However I couldn't find any specific doc that verifies QB64->C++ serial api is supported.
https://forum.vcfed.org/index.php?threads/qbasic-sending-characters-by-seria...
On Tue, Nov 8, 2022 at 5:19 PM Duane Craps via vcf-midatlantic < vcf-midatlantic@lists.vcfed.org> wrote:
How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs.
I don't know which BASIC you are using but wasn't something like out #n, b I recall there being GW BASIC and QBASIC -- Linux Home Automation Neil Cherry kd2zrq@linuxha.com http://www.linuxha.com/ Main site http://linuxha.blogspot.com/ My HA Blog Author of: Linux Smart Homes For Dummies KD2ZRQ
I don't know which BASIC you are using but wasn't something like out #n, b I recall there being GW BASIC and QBASIC
I used that extensively for controlling things via the parallel port growing up. For serial, I guess you use the DOS mode utility first to set serial speed then maybe you can do out &h278, byte? Another hack would be scripting languages from Telix, QModem and Telemate term programs. - Ethan
I remember writing a BASIC program to form a S format papertape record and then used Excel to calculate the checksum. Peek the memory location block one address at a time. I would do it that way. Once you make a proper papertape file you can export it using whatever program you use to write out a papertape Bill On Tue, Nov 8, 2022 at 7:31 PM Ethan O'Toole via vcf-midatlantic <vcf-midatlantic@lists.vcfed.org> wrote:
I don't know which BASIC you are using but wasn't something like out #n, b I recall there being GW BASIC and QBASIC
I used that extensively for controlling things via the parallel port growing up. For serial, I guess you use the DOS mode utility first to set serial speed then maybe you can do out &h278, byte?
Another hack would be scripting languages from Telix, QModem and Telemate term programs.
- Ethan
Did you try this, binary mode. OPEN COM · QB64Official/qb64 Wiki · GitHub https://github.com/QB64Official/qb64/wiki/OPEN-COM Get Outlook for Android<https://aka.ms/AAb9ysg> ________________________________ From: vcf-midatlantic <vcf-midatlantic-bounces@lists.vcfed.org> on behalf of Duane Craps via vcf-midatlantic <vcf-midatlantic@lists.vcfed.org> Sent: Tuesday, November 8, 2022 5:19:13 PM To: VCF <vcf-midatlantic@lists.vcfed.org> Cc: Duane Craps <DBC1964@cox.net> Subject: [vcf-midatlantic] sequential bytes to a com port How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs. I want to dump program files to a serial paper tape punch. I am actually using QB64 (which I love) that parses BASIC source to C++ and compiles it. Very fast and reputed to be compatible. -- Duane Craps sdɐɹɔ ǝuɐnp -- DuaneCraps sdɐɹɔ ǝuɐnp
Thank you, I try that tomorrow. Watching election tonight. Duane On 11/8/2022 7:08 PM, Kelly Leavitt wrote:
Did you try this, binary mode. OPEN COM · QB64Official/qb64 Wiki · GitHub https://github.com/QB64Official/qb64/wiki/OPEN-COM
Get Outlook for Android <https://aka.ms/AAb9ysg> ------------------------------------------------------------------------ *From:* vcf-midatlantic <vcf-midatlantic-bounces@lists.vcfed.org> on behalf of Duane Craps via vcf-midatlantic <vcf-midatlantic@lists.vcfed.org> *Sent:* Tuesday, November 8, 2022 5:19:13 PM *To:* VCF <vcf-midatlantic@lists.vcfed.org> *Cc:* Duane Craps <DBC1964@cox.net> *Subject:* [vcf-midatlantic] sequential bytes to a com port How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs.
I want to dump program files to a serial paper tape punch.
I am actually using QB64 (which I love) that parses BASIC source to C++ and compiles it. Very fast and reputed to be compatible.
-- Duane Craps sdɐɹɔ ǝuɐnp
-- DuaneCraps sdɐɹɔ ǝuɐnp
-- DuaneCraps sdɐɹɔ ǝuɐnp
Kelly, Thanks for the tip: This worked: Open "COM3:2400,N,8,1,BIN" For Output As #2 Print #2, Chr$(W); On 11/8/2022 7:08 PM, Kelly Leavitt wrote:
Did you try this, binary mode. OPEN COM · QB64Official/qb64 Wiki · GitHub https://github.com/QB64Official/qb64/wiki/OPEN-COM
Get Outlook for Android <https://aka.ms/AAb9ysg> ------------------------------------------------------------------------ *From:* vcf-midatlantic <vcf-midatlantic-bounces@lists.vcfed.org> on behalf of Duane Craps via vcf-midatlantic <vcf-midatlantic@lists.vcfed.org> *Sent:* Tuesday, November 8, 2022 5:19:13 PM *To:* VCF <vcf-midatlantic@lists.vcfed.org> *Cc:* Duane Craps <DBC1964@cox.net> *Subject:* [vcf-midatlantic] sequential bytes to a com port How do you send sequential bytes to a com port in microsoft BASIC without spaces or CR-LFs.
I want to dump program files to a serial paper tape punch.
I am actually using QB64 (which I love) that parses BASIC source to C++ and compiles it. Very fast and reputed to be compatible.
-- Duane Craps sdɐɹɔ ǝuɐnp
-- DuaneCraps sdɐɹɔ ǝuɐnp
-- DuaneCraps sdɐɹɔ ǝuɐnp
participants (6)
-
Bart Hirst -
Bill Degnan -
Duane Craps -
Ethan O'Toole -
Kelly Leavitt -
Neil Cherry