America Online APPLE II DEVELOPMENT FORUM CONFERENCE LOG Tuesday, January 19, 1993 10:00 p.m. Eastern Time Topic: Pascal/C & General Questions Forum Leader: Gary Jacobson (AFL GaryJ) AFL GaryJ Welcome to the Apple II Development Forum! AFL GaryJ Tonight, our scheduled topic is Pascal and C programming. AFL GaryJ We'd like to give questions on the scheduled topic top priority. AFL GaryJ But, if you have off-topic questions or comments, we can take those too. Sheppy Is anyone out there using ORCA/C 1.3 with the Prototyped headers posted by Sheppy Mike? I have problems since I installed them... Sheppy (that can't be solved by correcting obvious mistakes in the headers)... LL AndyW What kinds of problems? AFC DYAJim I've been using them for several months with little or no problems AFL GaryJ I'm not using them... Sheppy Well, no GS/OS calls work anymore. I get Invalid Number of Parameters errors Sheppy on every single one of them. AFL GaryJ Strange. Sheppy But they only take one parameter, which is the number of them I'm passing. LL AndyW Did you SET the pCount?? Sheppy That's the main problem. Sheppy Of course I did. That's required. But these are _compiler_ errors, not GS/OS Sheppy errors. AFC DYAJim Oh, I don't make GS/OS calls from C :) AFL GaryJ Mike Westerfield will be our guest here next week. (You can get a first hand AFL GaryJ response from him then :) DanP18 do they use the ellipses vararg mechanism? LL AndyW I do, and I haven't had any problems with the headers.. Sheppy Yeah, well... I've ordered 2.0 now. :) LL AndyW vararg isn't available.. AFC SteveB I don't really like using GSOS calls from C... seems awkward somehow. Sheppy Really? I mean, he didn't replace gsos.h, so it shouldn't be a problem, Sheppy but none of the calls actually work. Sheppy Very odd. Sheppy I don't like GS/OS calls from C either, but sometimes ya just gotta do it! :) LL AndyW What are you doing to set up the parm list?? AFL GaryJ He'll probably just tell you to wait 'till you get 2.0. DanP18 perhaps a code fragment would help. Sheppy Usually it's a hardcoded parmlist, using the defined structures in gsos.h. LL AndyW Short example of code would do.. Sheppy They worked under the old headers. LL AndyW Ok, say you're doing an open call.. Sheppy Hmmm... I could find some code here someplace and post it in the Byte Works Sheppy forum. Sheppy (In the C message board) AFA Jay I have a feeling it has nothing to do with your code. Sheppy So do I, Jay, but I've been wrong before. :) AFA Jay I wonder if he changes the PDosInt thingie somewhere... Sheppy I've looked at that Jay, it's fine. LL AndyW #include LL AndyW OpenRecGS oRec; LL AndyW /* this is inside the code somewhere */ LL AndyW oRec.pcount = 1; LL AndyW oRec.pathname = &ourname; LL AndyW OpenGS(&oRec); LL AndyW is it something like that?? Sheppy Yeah, basically, Andy. DanP18 did you #pragma expand 1 around the code? anything weird? Sheppy Um, once I did, and it didn't help. LL AndyW I'd like to see a code frag. that won't work for you, and see what it does here Sheppy Yeah... um... I'm going to grab one now. afk. DanP18 I wrote a program that accessed CD-ROMS, using GS/OS calls and the prototyped DanP18 headers, and it worked fine. Sheppy Okay, I don't suppose you've seen the GNO NDA? That won't build on my Sheppy system with these headers. LL AndyW I wrote the icon lister using GSOS calls, and I used the prototyped headers LL AndyW for it, and had no problems.. LL AndyW I don't have GNO.. Sheppy Sigh. That would make this easier. Okay... well... I'll type the relevant Sheppy lines for you. afk. LL AndyW Gno problem.. Sheppy I'm printing it out using Disk Witch. :) DanP18 ? AFL GaryJ Dan, is your question about Pascal or C? DanP18 c, slightly off topic. Sheppy Okay. The #include is there... Sheppy IORecGS r = {4,fd[0], ringBuf,1l}; Sheppy r.refNum=fd[0]; Sheppy r.requestCount=(unsigned long) value; Sheppy ReadGS(&r); Sheppy That's basically what it does. DanP18 what error do you get? Sheppy Um... I'm trying to figure out what fd[0] is, but the ReadGS call has the Sheppy correct number of parameters, doesn't it? Sheppy (that's the error: Invalid Number of Parameters) LL AndyW Why r.refNum is set twice I wouldn't know... LL AndyW That wouldn't cause the problem though.. Sheppy I dunno. That's not the problem, though. :) The compiler thinks that the Sheppy ReadGS call should take a number of parameters other than 1, which ain't so. DanP18 what does the prototype look like in gsos.h? Sheppy Prototype for ReadGS? DanP18 yes. Sheppy Let me look... afk. LL AndyW ReadGS takes only a single parameter. The address of the parm list.. Sheppy Okay: Sheppy #define ReadGS(pBlockPtr) PDosInt(0x2012,pBlockPtr) DanP18 the prototype for PDosInt is probably messed up. DanP18 That would explain why *all* gsos calls don't work. Sheppy Yes, it would, Dan. I can't figure out if/how PDosInt is screwed up, but it Sheppy probably is. LL AndyW Eric, DL the gsos.h file I just sent you.. It should clear up your problems.. Sheppy I'll try it. Thanks! LL AndyW Make sure you #include before other headers.. Sheppy Nope. It's a _compiler_ error. :) AFA Jay that makes it even stranger :) LL AndyW What was the compiler error you got? Sheppy Error: The number of parameters does not agree with the prototype. That's Sheppy the one. Sheppy Before other headers? I've never heard that one before... I'll move it. LL AndyW Sounds like the prototype was hosed.. Sheppy Yeah, it does. I don't know where all the stuff involved is anymore, so it's Sheppy tough to check it out. LL AndyW Anyway, try the one I just sent you and see if it fixes the problem.. Sheppy I'll do that. Sheppy That's it for me. Sheppy GA AFL GaryJ Ok, thanks.... AFC SteveB Has anyone else had trouble with key equivs. to extended controls in a window AFC SteveB being handled with DoModalWindow... buttons seem to get their keys fine... AFC SteveB ...but if I assign a checkbox some key equivs., they never get 'em. AFC DYAJim I think Steve already asked it once, and posted it too ;) AFC DYAJim (But good luck on finding an answer) AFC SteveB No, I never asked or posted this yet. Sheppy Hmmm. Sorry, my only DoModalWindows either have no checkboxes, or don't assign Sheppy 'em key equivs. LL AndyW That would be a good one for Matt.. (of course, he's not here tonight).. AFC DYAJim oh, sorry, that was something else but similar Sheppy I still can't figure out how to do Apple-? and Apple-/ for the same button, Sheppy though... :) AFL GaryJ Yes, maybe if Matt shows up later, you can repeat your question, Steve. DanP18 any C programmers out there interested in helping port the GNU unix DanP18 utilities to GSOS/ORCA C? GNO Jawaid Ahem. Looks like I came in at just the right time. :-) Sheppy If I had time, I'd be interested, but I got too much other stuff goin' down. LL AndyW Any particular ones (besides diff)?? GNO Jawaid Andy- I've got diff working 95% of the time. AFL GaryJ Yeah, can you be specific about which utilities? Sheppy Your timing, Jawaid, is perfect, as always. :) AFL GaryJ (you might find someone interested based on need) AFL GaryJ (specific need, that is) DanP18 well, I'm almost done with grep1.6 . LL AndyW has diff2.0 There are loads DanP18 of others like bison, flex, less, elvis, etc. maybe some brave soul DanP18 would like to tryt to port ghostscript. LL AndyW There's a couple of other things in there with the diff2.0 code too.. LL AndyW Which version are you working with Jawaid? AFL GaryJ There's a Bison port in our library already. LL AndyW Isn't there a less around too?? GNO Jawaid Andy, I think I'm porting the BSD 4.3 diff. GNO Jawaid Yep, there's a less (but only works with GNO) AFC DYAJim whatever happened to lcc, Jawaid? Sheppy Yeah. I use less, but it doesn't seem to work very well. AFL GaryJ There's a grep too, but not sure what version. AFL GaryJ (In our library) DanP18 I think the grep in the library is a limited implementation. LL AndyW What's the diff (pun intended)? GNO Jawaid Jim - I paused work on that on the chance that helping Mike Westerfield GNO Jawaid with C 2.0 was a better use of time. No decisions on that yet, but I think GNO Jawaid I chose correctly. Sheppy Yeah, the nerve, huh, Greg? :) AFC DYAJim How were you helping him? GNO Jawaid Beta testing.. LL AndyW Chewing on it, and spitting out bugs.. AFC DYAJim I thought you were helping him optimize it or something.. oh GNO Jawaid Dan - the grep in Procyon's Company Support area is a full implementation, GNO Jawaid and works under ORCA, too. Barnabas Slapping Mike around... Sheppy I like fgrep, myself. :) GNO Jawaid fgrep is very nice also :-) GNO Jawaid fgrep also works with ORCA. You should check 'em out Dan and come by GNO Jawaid Procyon's area more often. :) AFC DYAJim and Jawaid - you should upload the latest versions more often ;) LL AndyW Any luck on rz Jawaid? AFL GaryJ Dan, you should post your question in our message boards, too. You might AFL GaryJ pick up a few takers there. DanP18 Well, the point of my question is, I have a cd-rom packed with GNU/X11 source Sheppy I just visit pindarus, myself. Oooh, rz would be cool even if I haven't Sheppy any use for it! :) GNO Jawaid Andy - I encountered a working RZ that came from out of nowhere. DanP18 and I want *real* tools for my development environment. DanP18 motto: if you can't buy'em, port'em! LL AndyW Nowhere? Well, where is it? GNO Jawaid PLUG ALERT! PLUG ALERT! Sheppy Plug it in! :) LL AndyW What about sz that doesn't REQUIRE GNO? AFL GaryJ :) Sheppy Eeew. Why would you not be using GNO? ;) GNO Jawaid Ooh... there's one of those, too, but the guy hasn't released them yet. Barnabas Why ask why, Eric!?! AFC DYAJim because we're waiting for GNO 1.1 before using it more AFC DYAJim :) GNO Jawaid (And wants to charge for them; some people don't understand "copyrighted GNO Jawaid freeware". :-) LL AndyW Oh.. Well, I can't afford to get GNO, so I don't have it.. DanP18 well, regardless, I'll probably be posting grep.1.6 in the next week or so. Sheppy Good point. GNO 1.1 will be nice... sigh. I really don't have room on my Sheppy HD for GNO 1.0, though, let alone 1.1. :( LL AndyW If I understand it right, Chuck Foresberg owns rz/sz, and says people can't LL AndyW charge for ports of it.. Sheppy Yeah, that sounds likely. Sheppy Anybody have a working 120Mb hard drive they can give up for $100? :D GNO Jawaid There are freeware versions for UNIX (which we ported) but we also ported GNO Jawaid the non-freeware ones that you're supposed to pay license fees for :-) AFL GaryJ Get a sign, Sheppy :) AFL GaryJ ("I'll work for a hard drive") Sheppy Kermit would be useful, since that's what the machine at the UCSB MCL uses... Sheppy About right, Gary. I have $200 saved up so far, but I need about $550 total. LL AndyW I have the source for rz/sz, but even the developer's package doesn't have the LL AndyW restart stuff in it.. GNO Jawaid We've got restart I'm fairly sure... what we have (and are not supposed to) Spottysoft ("I steal for a hard drive..." :) GNO Jawaid is the RLE compression junk. LL AndyW At least that's what they told me when I called OMEN.. GNO Jawaid Shep- You can get 120MB drives for much less than $550. AFL GaryJ BTW: I'm a new(er) daddy this week. Last week, after the chat, my wife went into labor :) Sheppy Congrats, Gary. Barnabas Wow.... must have been some chat... :) AFL GaryJ (It was the chat that did it, I think :) GNO Jawaid Oh, don't call OMEN. They'll tell you that "This is a business here, GNO Jawaid we're trying to make some money". Sheppy Where, Jawaid? The best I could find was $509, not including the RAMFast. Sheppy (add $60 for that) LL AndyW Try TMS.. Sheppy Congrats, Gary. Sheppy As far as I could tell, TMS was more expensive than that (from their ads). Barnabas Well, boy or girl? AFL GaryJ It was a boy. 8 lbs, 14 ounces. AFC DYAJim I need to get another HD AFA Jay Gary, this IS the last one, right? :) AFC DYAJim I want to get something LARGE Barnabas Ah, a budding developer! Sheppy Well, either you're very dedicated to ADV or you're desperately looking for Sheppy some time off. :) AFL GaryJ Yep, Jay :) GNO Jawaid LRO's got 'em for $449. Sheppy Yes... I saw that... but... AFL GaryJ Well, it happened a couple of hours after the chat, actually. (like, 1:00 a.m. when it started) GNO Jawaid (Whether they'll screw ya for something else is left to the reader as GNO Jawaid an exercise.) Sheppy I don't really wanna buy from LRO. GNO Jawaid Call up Sequential. I got a real bargain (at cost, but then I'm special) Sheppy I trust them almost, but not quite, as much as I trust Apple. :) Sheppy Who? Sheppy Sequential? Spottysoft If you don't want the 15MB or so of software bundled with it... look into the Spottysoft prices from MAc vendors... GNO Jawaid but I imagine they'd give you about the same price and much better response AFL GaryJ Again, for those who missed my mentioning it earlier (and who haven't read the GNO Jawaid time. Sequential Systems. (303) 666-4549. Sheppy I'll have to look around for that, I guess. GNO Jawaid Congrats, Gary! AFL GaryJ "From the Forum Leader" file), next week, Mike Westerfield will be AFL GaryJ here to talk about his products, including ORCA/C 2.0. LL AndyW I have a bare drive, 210m for 479 from HDI.. Barnabas I thought the same, Jawaid... :) AFL GaryJ Thanks, Jawaid :) AFC DYAJim Sequential sells HDs? Sheppy Yeah... I'll look in some Macazines and see what I find. I didn't know Sheppy Sequential sold HDs. Barnabas Just wondering... "When's he gonna pull out the wallet pictures?" :) Sheppy 'bout how much? GNO Jawaid Yep. They bought out Chinook and now they have their own drives. Spottysoft Sequential = Chinooks GNO Jawaid No longer. GNO Jawaid They're out of Chinook stock. :-) AFC DYAJim are they fast and cheap? :) GNO Jawaid They now use Maxtors and have some VERY nice cases. 64K cache on the GNO Jawaid Maxtors I believe. Sheppy Cheap is the important bit here, Jim. :) Barnabas Say, Gary, why don't you upload a digitized pic of your latest "development" Barnabas effort... AFL GaryJ I should, Barnabas :) Spottysoft They make their own Jawiad? How about drives for the IIc? GNO Jawaid Those too, Spotty. They have a complete line. Spottysoft Okay... :) LL AndyW 127m bare drive for $339.. Spottysoft ::filing that tidbit of info...::: :) AFL GaryJ Not a bad deal. LL AndyW 170m for $389.. Sheppy hmmm, but then I have to get a case and power supply, Andy. GNO Jawaid But you still end up paying $80-$100 for a good case. If you've got a case GNO Jawaid already.. LL AndyW The 170 is a Quantum.. AFC DYAJim Where's this Andy? Sheppy Then I'm back where I started. No case, I'm using an InnerDrive 40 now. Barnabas Translation: GS case. LL AndyW But, a 170m drive, and a shadow case from TMS would be $489, which is cheaper Sheppy I suppose if I were feeling really spunky, I could put a SCSI 3.5 in the LL AndyW than the other, and more capacity.. Sheppy InnerDrive case and feed the SCSI cable out to a RAMfast outside. :) AFC DYAJim I know someone who did that Eric :) LL AndyW The 170m Quantum was from HDI, but I'm sure it can be had cheaper elsewhere.. Sheppy Yes, but then I need a controller card, which gets me more or less back to Sheppy the same place. Sheppy (since I lose the "you bought the drive from us" discount). Barnabas I dunno, Eric... sounds like a HARDWARE problem, don't you think? :) AFC DYAJim is it easy to mount the drive in the case yourself? AFL GaryJ I haven't seen HDI's latest ads. Sheppy Well... yeah. I don't even remember how this came up. :) AFL GaryJ (Although I buy stuff from them all the time... they're right down the AFL GaryJ street from where I work) AFC DYAJim Drive down and ask for a copy Gary :) AFL Marty You wanted a 120 meg HD for $100, Sheppy. :) Sheppy Oh yeah. Wishful thinking. :) Spottysoft (TMS is carrying Conners now as well as Quantums.. saw it in the newest GS+ ad) GNO Jawaid Say, on an actual development note, GNO/ME 1.1 will be released near the GNO Jawaid end of February. Barnabas BTW Eric: There is NOTHING wrong with my provided routines... GNO Jawaid Because of our desire to remain compatible with the latest Byteworks GNO Jawaid products, we're making an interim release that doesn't include everything GNO Jawaid we wanted, but does include lots of stuff (most importantly compat. with GNO Jawaid C 2.0). Sheppy Shadow 127C: $349 + $179.95 for the RAMFast 256K. Sheppy (from, of course, TMS) Sheppy Okay, Greg. Barnabas Biteworks products... Sheppy Coolness, Jawaid! Upgrade price (cringe)? Spottysoft (Sheppy... needing more room for TELOS?? :) Sheppy I may have to wait for the upgrade... :( GNO Jawaid $89.95, Eric. But just for you. Everyone else gets it free. :-) AFL GaryJ :D GNO Jawaid Or rather, I should say "at cost" cause that's more like it. Sheppy Well, yeah, actually, Spotty. :) Sheppy It's over 50K now. :) AFL Marty ::passing the hat for Sheppy:: Sheppy Actually GNO & utilities is chewing up about 6Mb on :West.of.House... AFL GaryJ That takes too much from his Hard Drive fund :) LL AndyW The Quantum ELS170S is $425 from TMS, and $389 from HDI. I'm sure they (TMS) LL AndyW will match HDI's price. This came from the HDI ad in the Feb. CS.. AFC DYAJim Can't wait for 1.1, Jawaid. GNO Jawaid Hey, I know a 7-11 where I can rip off the MDA money jar. :-) :-) Sheppy Everytime I delete stuff, I fill up the saved space in just a couple hours. Spottysoft <-- reading TELOS at the moment (@$!# slow boards!) Sheppy I'm one of the miraculously skillful at filling hard drives. :) AFL Marty Get rid of your buggy code, Sheppy. :D GNO Jawaid Hear Hear, Sheppy. I did that. I now have 160MB (my original 40MB + Sheppy Oh, parts 15-17, Spotty? I was trying to avoid Physics homework. :) AFL Marty (j/k :) Barnabas Gee... no narcissists here... GNO Jawaid my new 120MB) and I'll have to work really hard to fill that. But I'll GNO Jawaid manage, I'm sure. :) AFL GaryJ "Filling a hard drive" can be acomplished quite easily, from within a BASIC program :) AFC DYAJim And I have about 2mb total free on my 105mb drive :) AFL GaryJ accomplished, even. AFC DYAJim Same here Eric at skillfully filling HDs :) Sheppy This is _useful_ filling! :) AFL GaryJ (I wrote a program to do just that, once :) Sheppy I did, too, Gary, but it was for a useful purpose. I was testing something. :) AFL GaryJ Me too. Barnabas I dunno... got a 4MB digitized sound of the Fanfare for the Common Man for you. Sheppy It was an empty 160Mb hard drive. :) AFL GaryJ That's kind of fun to do :) Barnabas That's probably your problem, Eric! "Kids, don't try this at home!" GNO Jawaid What happened to your drive, Eric? Sheppy Um, it belonged to Apple, Jawaid. :) Barnabas It was Apple's drive. GNO Jawaid Oh! :-) Sheppy :D Barnabas Wouldn't let it out of the building... AFL GaryJ I can't imagine why. Sheppy I wanted to take it home with me, but the guy I was sharing my cubicle with Sheppy needed it. :) Sheppy And I signed a pesky "I won't take anything home" form. :) GNO Jawaid Surely Apple has enough 160MB drives to last a long time? :) Barnabas At the speed of Apple drives, they _do_ last a _loonnnnngg time_! Sheppy Prolly, Jawaid, but I figured that since I wasn't gonna rip off their source Sheppy code, why bother with a hard drive. :) Sheppy :D GNO Jawaid hehheh GNO Jawaid Andy, have you gotten your diff working? LL AndyW I haven't had much time to work on it yet.. LL AndyW More than 800k of source code..