NU020520@NDSUVM1.BITNET (04/23/87)
help, how do you open a modem buffer and get it to dial? I tried open 2,2,0:print#2,"ATDT" but that doesn't work. any help will be appreciated! Ryan Harlicker
earl@msudoc.UUCP (Robert Earl) (05/01/87)
In article <135NU020520@NDSUVM1> nu020520@ndsuvm1.bitnet.UUCP writes: >help, how do you open a modem buffer and get it to dial? >I tried open 2,2,0:print#2,"ATDT" but that doesn't work. >any help will be appreciated! > > > > Ryan Harlicker First of all, you need a modem which is of the 'autodial' class (the 1650 is one example). The rest of the info here assumes a PULSE dial system like the 1650/compatibles use. In the user's handbook (or is it the programmer's handbook?) is a memory map of the C64...up in the 50000+ addresses is a set that pertains to the RS232 port...to pick up the phone, poke the first address (sorry I don't remember which one it is...52636?...up there somewhere anyway) with a 32 (I think...either that or 0...one picks up the phone, the other hangs up the phone). To dial, just quickly hangup/pickup the correct # of times (on my modem you can hear the clicks, so it is easy to adjust the timing to what sounds just like a dial phone. Sorry none of this is precision advice, but if you can get a look at the manual, it isn't too hard to figure. (feel free to email me to complain or ask for more info...I will take the time to look it up if necessary) Bob Bob B
john13@garfield.UUCP (05/04/87)
There are 2 popular kinds of modems on the C-64, the "Mitey-Mo" kind and the "16XX" kind. Hayes compatible modems use the same kind of serial protocol as the 16XX modems. First of all, when you open the modem as a file, you must specify a filename that determines baud rate, word size, etc. Back when I was terminalizing on the 64, the usual format was open 2,2,2,chr$(6)+chr$(0) You will need to get hold of a copy of the C-64 Programmer's Reference Guide to determine what bits (in the first character) need to be set for your preferred baud rate. After that, the Hayes compatibles work by just printing "AT" commands - note that you should try both upper and lower case "AT"'s, since the modem may or may not know about Petscii. Other auto-dial modems, Mitey-mo's, 1650's, etc must be dialed by diddling the hardware bits on the serial port. Sorry, I no longer have my 64, but I wrote stuff to do this for both types of modems, lessee if I can remember... (as he cheats and digs out a memory map). poke 56579, (6 or 0, not sure) to set serial configuration poke 56577, 32 or 4 to pick up and hang up. Mitey-mo and 16XX use opposite signals, which accounts for the incompatibility of their software. Mitey-mo needs to be set explicitly to originate by setting one of the other bits in 56577. For 16XX, originate is the default. You will be able to tell the answer/originate bit by the carrier the modem will send when you set it to answer. I'm not 100% sure about the 32/4 bits being right...however you will quickly determine the right ones through trial and error and listening to see when the phone is being picked up. To write an autodial routine, you need to leave pauses 1) after picking up the phone to let dial tone kick in 2) short pauses between clicks within the same number 3) medium length pauses between distinct numbers Of course, the best solution is a 1670 or other Hayes-type modem which accepts AT commands. Watch out for the auto-answer of the 1670, though... I used to have to run a program to turn it off when I didn'y want to unplug it! ( open 2,2,2,chr$(6)+chr$(0) print#2,"ATS0=0" close2 ) John