newTIboyRob Posted August 17 Share Posted August 17 (edited) Was rummaging through my gear and decided to revisit 2 very nice printers, the Epson Homewriter 10 and the Star Micronics SG-10C. Hooked up the Epson and ran this simple program in basic: 10 OPEN 3,4 20 PRINT#3,"HELLO WORLD" 30 CLOSE3 Communicated and printed perfectly. However, when I tried the same exact thing with the SG-10C printer, I just get the "Ready" on screen with no output to or at the printer. I tried the other serial port at its back, thinking it wouldn't make a difference. And it didn't. I even tried OPEN 4,4 PRINT#4 etc... still no dice. The self test worked, but it just does NOT want to communicate with the C64. Any ideas? I hate to trash this printer. It is otherwise very nice and takes standard typewriter ribbons, thus can print in different colors like navy and brown. Edited August 17 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 17 Share Posted August 17 The first parameter in the OPEN command is just the logical channel within BASIC, so it can be anything from 1 to 255. The second parameter is the device number, which for a printer usually is 4 or 5. However if nothing is connected, you probably would end up with ?DEVICE NOT PRESENT at one point. I suppose there may be a fault inside the printer in its 6522 or whichever chip handles the IEC communication, but try a few different device numbers. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 17 Author Share Posted August 17 (edited) Right, OPEN fi, dn, sa being: logical file number, device number, secondary address. I found the online manual. Interesting... from reading, it tells me: .... in case of the printer, the [device] number must be 4 since that is the number assigned to it at the factory. So that being said, before I do some more playing, are you thinking maybe it's possible to override or bypass this? That is says the words "must be 4" made me go "hmm" In multiple experiments I got syntax errors, file not open, and certainly the DEVICE NOT PRESENT. Maybe I should try this anyway: 10 OPEN 4,5 20 PRINT#4,"HELLO WORLD" 30 CLOSE 4 or even 10 OPEN 4,5 20 CMD 4 30 ?"HELLO WORLD" 40 PRINT# 50 CLOSE 4 What do you think? Edited August 17 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 18 Share Posted August 18 Definitely try device 5. In worst case, the computer will hang and you press RUN/STOP + RESTORE to bring it back. Actually you can do those in direct mode, not requiring a program but that makes little difference. I'm more concerned that something in the communication side of the Star printer might be faulty, while the printing mechanism works which is how you get the self-test to work. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 18 Author Share Posted August 18 (edited) I almost didn't try it, and I couldn't actually believe it, but: 10 OPEN 4,5 20 PRINT#4,"HELLO WORLD" 30 CLOSE 4 actually did work! So much for that manual's "warning" that the device number must be 4 due to its being factory set. Ha! Now if I could only figure out why the print is inconsistent with a newish typewriter ribbon. Perhaps it needs like 10 or more printouts until it really gets broken in? Sometimes it was "trying" to look nice and solid, but the characters look shady 😮 But thanks carlsson for the nod to try device #5. I guess the expression "don't believe everything you read" sometimes actually does hold true Edited August 18 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 18 Share Posted August 18 Are there DIP switches at the back of the Star printer that lets you change device number, or perhaps it is done with solder pads inside? I don't know why one would have changed the factory default once, perhaps if they had daisy chained the motherload of devices including dual printers, dual floppy drives and so on. Quote Link to comment Share on other sites More sharing options...
+OLD CS1 Posted August 18 Share Posted August 18 4 hours ago, carlsson said: Are there DIP switches at the back of the Star printer that lets you change device number, or perhaps it is done with solder pads inside? I don't know why one would have changed the factory default once, perhaps if they had daisy chained the motherload of devices including dual printers, dual floppy drives and so on. In my days as a BBS SysOp, I had two printers, one which printed user logs and the other for my tasks. 1 Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 18 Share Posted August 18 Good suggestion of a use case! On page 74 of the user manual, the DIP switches are described in full. Those let you set page length and paper feed, character pitch, print mode and the last one 1-8 switches between device #4 (on) and device #5 (off). Rob probably wants to change that last one to factory default 4 in order to work with more software. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 19 Author Share Posted August 19 (edited) Ah after relooking at the manual, I found the DIP switches on the left side, (I was looking on the back, and turns out the printer was next to a bookcase where I couldn't see them on the left) and sure enough, that switch #8 in the first switch set of 8 had been set by the previous owner to down, meaning set to device 5, hence it working with the alternate program. True, I think the factory set 4 has a better chance of working with more software, as sometimes it doesn't allow a device # change. Thus I switched it back up with a pen cap to become device #4, and bingo the OPEN 4,4 and PRINT#4 concept enabled communication this time and the program printed to paper. Yay! The printout on paper got better when I played with the ribbon a bit too. Thinking maybe a dozen or so more prints and it will be even bolder. But can you guys tell me this one.... When you first turn on the C64, you are in all upper case Graphics mode, so to get to mixed letter/cases mode, it's Shift Commodore Key so you have all lower case. Thus as you are typing in lowercase mode: 10 open 4,4 20 print#4,"This is a mixture of ALL CAPS and not all caps" 30 close #4 But how to get a mix of character cases like that printed on paper, so as to match the mixed look and concept of what appears on screen in line 20? I was playing around with print chr$(14)chr$(8) then later print chr$(142)chr$(9)... but couldn't quite get it. Edited August 19 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
Casey Posted August 19 Share Posted August 19 (edited) Usually, secondary address of 7 will print in in upper/lower case: In mixed cased for this example: 10 open 4,4,7 20 print#4,"This should be in UPPER CASE and lower case." 30 close 4 You usually can mix both in a printout by using 2 files: 10 open 1,4,0:rem secondary address 0 is upper case/graphics. 20 open 2,4,7:rem secondary address 7 is upper/lowercase text. 30 print#1,"SSS":rem should print hearts. 40 print#2,"This is Mixed Case" 50 close 1:close 2 Edited August 19 by Casey 3 Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 20 Author Share Posted August 20 (edited) Thank you @Casey Tweaking your example, I tried this program starting in lower case mode: 10 open 4,4,7 20 print#4,"This is a mix of ALL UPPER CASE and all lower case" 24 print#4,"THIS IS EXCLUSIVELY UPPER CASE." 28 print#4,"while this is exclusively lower case." 30 close 4 and the above worked verbatim on the paper printout. Thanks for that! Curious about 2 things: 1) How did you know about the secondary address of 7 as being the thing that allowed the mix of the cases in the paper printout? (I eventually found the description on p.106 of the manual, but I wouldn't have thought to zone in on the secondary address concept and/or ir being 7 as the magic number without your answer.) 2) If my above program works with adding the 7 at the end to achieve all those text differences, then what would be the use for your second example? Would that be for instance if you wanted to print the hearts or other characters in Graphics mode or what use? Edited August 20 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
+OLD CS1 Posted August 20 Share Posted August 20 7 hours ago, newTIboyRob said: 1) How did you know about the secondary address of 7 as being the thing that allowed the mix of the cases in the paper printout? (I eventually found the description on p.106 of the manual, but I wouldn't have thought to zone in on the secondary address concept and/or ir being 7 as the magic number without your answer.) As you found, this is in the manual. As well, it is pretty much the standard for Commodore printers. There are other secondary addresses which do other things, depending upon the printer. For example, on my MPS 1200, these secondary addresses do these things (from the manual): n Function 0 Selects uppercase/graphics character set 3 Sets number of lines per page (see Chapter 4) 6 Sets line feed pitch (see Chapter 4) 7 Selects uppercase/lowercase character set 10 Resets printer 7 hours ago, newTIboyRob said: 2) If my above program works with adding the 7 at the end to achieve all those text differences, then what would be the use for your second example? Would that be for instance if you wanted to print the hearts or other characters in Graphics mode or what use? PETSCII graphics are good for boxes, lines, &c, among its other various graphics and symbols. Another example, I wrote a call logging generator used with Novaterm for hand-written notes on calling BBSes. It used the PETSCII line graphics to make a table for your notes (like graph paper.) Oh, for that matter, I had a program which used them to generate graph paper. 1 Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 20 Share Posted August 20 5 hours ago, OLD CS1 said: Oh, for that matter, I had a program which used them to generate graph paper. Weren't those very expensive graph papers? Quote Link to comment Share on other sites More sharing options...
+OLD CS1 Posted August 20 Share Posted August 20 38 minutes ago, carlsson said: Weren't those very expensive graph papers? Maybe. But what did it cost me? A sheet of paper from a box of like 1,500 pages for $20, plus whatever the ink ribbon printing in draft mode cost (which I was subsidizing by printing booklets of adult MacPaint files.) So, maybe. But it was also convenient. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 21 Author Share Posted August 21 (edited) Interesting. That led me to this thought, (which is why this forum is super.) Also kinda interesting... do you think it's possible for the printer to print actual music staff paper? I am a musician and it would be kind of cool to print either that or paper with specialized, customized lines for when I write music. Edited August 21 by newTIboyRob Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 21 Share Posted August 21 Depending on the distance of the line feed, you probably can print five lines next to each other to form a stave. On the C64 there were a bunch of programs to let you compose music in sheet music form and print it. As long as the printer accepts graphics printing, it should be fine. I used The Music Shop by Broderbund a lot and even printed some of the music. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 21 Author Share Posted August 21 @carlsson ... very cool. Found that .d64 and its associated files on the IA. Now if only the SD2IEC will "accept" it (fingers crossed, but with great trepidation!) Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 21 Share Posted August 21 Yeah. No idea to which extent it uses custom floppy drive routines. The music files are stored as SEQ though, but that should be supported by SD2IEC. Quote Link to comment Share on other sites More sharing options...
newTIboyRob Posted August 21 Author Share Posted August 21 Good to know, thanks. Even if it only just prints the staff paper, it is still useful to my way of thinking. Quote Link to comment Share on other sites More sharing options...
carlsson Posted August 21 Share Posted August 21 If you only want blank sheet music paper, I think you might as well draw an image in a drawing program and have it printed. The original idea to use PETSCII graphics is nice though. I understand you can define your own characters even with a BASIC program so you could make symbols that perhaps have two horizontal lines through them and draw three rows of that (the last row would only need one line though) in order to get a bit tighter music staves. For that matter, I don't recall when was the last time I wrote (drew?) sheet music by hand. For the last 25 years, I've done nearly all of that on my PC using modern music software and crisp laser printers, but that is another story. 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.