21 198511 Computer Journal

Total Page:16

File Type:pdf, Size:1020Kb

21 198511 Computer Journal 188N'07a.Wl THE COMPUTER JOURNAL~ For Those Who Interface, Build, and Apply Micros Issue Number 21 November-December, 1985 $2.50U5 Extending Turbo Pascal Customize With Procedures and Functions pilge2 Unsoldering: The Arcane Art Second in a Series pilge8 Analog Data Acquisition and Control Connecting Your Computer to the Real World page19 Build the Circuit Designer 1 MPB Part 2: Programming the SHC pagelS • The Computer Corner page 52 The Computer Journal! Issue #21 1 THE COMPUTER JOURNAL 190 Sullivan Crossroad Editor's Page Columbia Falls, Montana 59912 406-257-9119 Mid-Level Languages Being Developed about languages have been voiced by When the first hobbyists built their others several times during the past Editor/Publisher microcomputers they had to code their two months. Art Car/son programs directly in machine language. Assembly is a great programming but they soon wrote assemblers which language and the small ROMabie Production Assistant enabled them to use easier to remem­ programs run fast - but coding can be Judie Overbeek ber mnemonics for their source code. tedious for large programs, and I/O. Circulation Language development continued and screen-handling, menus and floating point math routines can be a real bitch Donna Carlson BASIC became the familiar language for the new micro owner. Today there to code. Developing a non-trivial Technical Editor is an almost overwhelming assortment assembly language program is awk­ Lance Rose of languages to choose from with ward because you haveto write the something for every purpose, and it souce code with an editor (I use Wor­ Contributing Editor seems that there should be no reason to dStar), assemble to a HEX file, and load Ernie Brooner work on language development- but that to a .COM file for a trial run. Then Contributing Editor there are those who are not satisfied back to the editor for any revisions and Neil Bungard with what exists, and who feel the need through the whole routine again. An to build on the foundation which has assembly language program is also Contributing Editor been established. Telling a sofware VERY difficult to understand and up­ Bill Kibler hacker not to waste his time on date in the future, even if you wrote it language development because yourself, and can be almost impossible everything has already been done is to decipher if written by someone else. like telling an author not to write another novel because everthing has The Computer Journal«J is a bimon­ already been written about. or telling thly magaZine for those who interface, an artist not to bother painting another "There isn't, and never buifd, and apply microcomputers. picture because every kind of picture will be, a perfect language The subscription rate is $14 for one has already been paintedl whieh is optimum for While it IS true that there is a year (6 issues), or$24 for two years (12 every use." issues) in the U.S. Foreign rates on suitable language for almost every request. purpose. it is also true that there are some applications for which there is not Entire contents copyright © 1985 by an optimum language. As I have stated A program properly written in a The Computer Journal. before, I contend that we should all be structured high level language such as Advertising rates avaifable upon comfortable working in at least two or C or Turbo Pascal takes less time to request. three languages and familiar with two write and is much easier to maintain or To indicate a change of address, or three more so that we can choose the modify ifyour requirements change. please send your old label and new ad· best language for each application. but some sections may be too slow for dress. There isn't (and never will be) a perfect time-eritical real world control ap­ language which is optimum for every plications or computer bound portions. Postmaster: Send address changes user When we learn our first language Some language implementations also to: The Computer Journal, 190 Sullivan we think that we can do everything have a large run-time code which Crossroad, Columbis Falls, Montana, with it. and although it is cumbersome results in large files for even small 59912. for some uses we plod along because we programs. I really like assembly Address all editorial, advertising and don't want to give up our hard won language for the high speed routines subscription inquiries to: The Com· skills and start over again with a new and for initiating system port drivers. puter Journal, 190 Sullivan Crossroad, language. But, learning the second but I don't like the time and effort in­ Columbia Falls, MT 59912. language is a lot easier than the first volved in non-eritical areas such as one. and it enables us to see how clunky screen messages and menus. the first one was in some areas (and also The experts say that you should fully how we miss some of its features in the define the objectives and design your new one). program before writing any code in­ Ifyou haven't already read Kibler's stead of hacking away at it and making I Computer Corner turn to the back page rC01Itinued 011 page 4-41 ....-------------~and read it now, because Bill's thoughts 2 The Computer Journall Issue #21 Extending Turbo Pascal \ Use Procedures and Functions to Develop Your Own Version by Jerry Houston Because Turbo Pascal'sill once the function has been written and variable names to be "invented" at any procedures and functions allow the use tested. Significantly. it never has to be time. Misspell a variable somewhere in of local variables that don't conflict written or tested again. and can be used that maze of instructions. and BASIC with other parts of the program. and whel1ever needed. will go along with it without question, because parameters can be passed to Because of the block-read and block­ even though it means disaster for the them. it is really easy to define new write features of the Turbo editor (it program. BASIC has singlehandedly keywords. in effect. That means that a works just like WordStar'sill CTRL-K brought a whole new meaning to the version of Turbo Pascal can be Rand CTRL-K W), it's easy to save term "debugging". developed that meets the individual procedures and functions separately on Pascal. on the other hand. requires and personal needs of a particular a disk for future use in other programs. that variables be defined before they're programmer, whether he or she is a The {SI} (include) compiler directive used. and that they be declared accor­ writer of business report programs or will even merge a procedure with a ding to their intended use. There are of economies simulations or source as it is being compiled, making it many reasons for this requirement- all engineering number-erunchers. unnecessary even to read it in with the ofthem excellent. For example, if a For example. when printing business editor. A whole personal library of of­ string variable is used in BASIC, it's forms like an invoice, I wanted a simple ten-needed procedures and functions stored in memory the first time it is command that would establish a print can be read into the source code with given a value. The next time a value is position on the printer, such as the just a few keystrokes, and seldom-used assigned to the same string variable, it standard Turbo Pascal procedure ones can be added individually at com­ can't be stored at the same place. as its GOTOXY(h,v) which places the cursor pile-time. length as well as its contents might at a specified horizontal/vertical The proper construction of change. So a different chunk of memory position on the CRT screen. A simple procedures and functions, and the is used. and a table is updated to point procedure can be written to do this. ef­ proper use of loal variables with them, to the NEW contents of that string fectively adding another command to is an important topic for anyone who's variable. the language. Anyone can extend the starting out with Turbo Pascal, because In a program that sorts a large list of language with keywords that are it helps them to exploit the full power string variables, it's likely that a par­ familiar from another language, ifthey and versatility of this beautiful ticular variable like COMPARES might want. Thus. a Turbo Pascal instruction language. Procedures and functions in get thousands of different values stored could be written such as: Pascal share many qualities-for con­ in it before the sort is finished. Each venience. I'll refer to both of them as time this happens. more memory is HTAB(20); VTABIlO); WRITE('Hi, "procedures" from now on, until the used. until BASIC finally runs out of therel"); time comes to make a distinction. variable storage space and has to stop to GARBAGE COLLECT, the usual which would do exactly what an old Pueal VI. B••ie term for reclaiming the space used by Applesoftill programmer would expect For those who are just now being in­ all the PREVIOUS CONTENTS of a it to. except in this ease, with the prin­ troduced to Pascal (due to the amazing string. This process can actually stop ter! popularity of Turbo), I should pause to the execution of a program for minutes So that the runtime library isn't explain two of the major differences at a time, depending on the computer. overly large, little-used commands are between Pascal and BASIC, a language Pascal.
Recommended publications
  • Extracting and Mapping Industry 4.0 Technologies Using Wikipedia
    Computers in Industry 100 (2018) 244–257 Contents lists available at ScienceDirect Computers in Industry journal homepage: www.elsevier.com/locate/compind Extracting and mapping industry 4.0 technologies using wikipedia T ⁎ Filippo Chiarelloa, , Leonello Trivellib, Andrea Bonaccorsia, Gualtiero Fantonic a Department of Energy, Systems, Territory and Construction Engineering, University of Pisa, Largo Lucio Lazzarino, 2, 56126 Pisa, Italy b Department of Economics and Management, University of Pisa, Via Cosimo Ridolfi, 10, 56124 Pisa, Italy c Department of Mechanical, Nuclear and Production Engineering, University of Pisa, Largo Lucio Lazzarino, 2, 56126 Pisa, Italy ARTICLE INFO ABSTRACT Keywords: The explosion of the interest in the industry 4.0 generated a hype on both academia and business: the former is Industry 4.0 attracted for the opportunities given by the emergence of such a new field, the latter is pulled by incentives and Digital industry national investment plans. The Industry 4.0 technological field is not new but it is highly heterogeneous (actually Industrial IoT it is the aggregation point of more than 30 different fields of the technology). For this reason, many stakeholders Big data feel uncomfortable since they do not master the whole set of technologies, they manifested a lack of knowledge Digital currency and problems of communication with other domains. Programming languages Computing Actually such problem is twofold, on one side a common vocabulary that helps domain experts to have a Embedded systems mutual understanding is missing Riel et al. [1], on the other side, an overall standardization effort would be IoT beneficial to integrate existing terminologies in a reference architecture for the Industry 4.0 paradigm Smit et al.
    [Show full text]
  • Japanese Semiconductor Industry Service
    Japanese Semiconductor Industry Service Volume II Technology & Government Dataquest nn a company of The Dun & Bradstreet Corporation 1290 Ridder Park Drive San Jose, California 95131-2398 (408) 437-8000 Telex: 171973 Fax: (408) 437-0292 Sales/Service offices: UNITED KINGDOM GERMANY Dataquest UK Limited Dataquest GmbH 13th Floor, Centrepoint Rosenkavalierplatz 17 103 New Oxford Street D-8000 Munich 81 London WCIA IDD West Germany England (089)91 10 64 01-379-6257 Telex: 5218070 Telex: 266195 Fax: (089)91 21 89 Fax: 01-240-3653 FRANCE JAPAN Dataquest SARL Dataquest Japan, Ltd. 100, avenue Charles de Gaulle Taiyo Ginza Building/2nd Floor 92200 Neuilly-sur-Seine 7-14-16 Ginza, Chuo-ku France Tokyo 104 Japan (01)4738.13.12 (03)546-3191 Telex: 611982 Telex: 32768 Fax: (01)4738.11.23 Fax: (03)546-3198 The content of this report represents our interpretation and analysis of information generally available to the public or released by responsible individuals in the subject com­ panies, but is not guaranteed as to accuracy or completeness. It does not contain material provided to us in confidence by our clients. This information is not furnished in connection with a sale or offer to sell securities, or in connection with the solicitation of an offer to buy securities. This firm and its par­ ent and/or their officers, stockholders, or members of their families may, from time to time, have a long or short position in the securities mentioned and may sell or buy such securities. Printed in the United States of America. All rights reserved.
    [Show full text]
  • Software Break- Size of the Quantization Noise (I.E., L/2 an LSB of the Point, Single Step Trace, Disassembler, and RS-232 Quantizer)
    INK CIRCUITCELLAR~~~-r;;lm THE COMPUTER Process This APPLICATIONS JOURNAL hile the term “signal processing” can cover a full range of topics, we’ve decided to concentrate on FOUNDER/EDlTORlAL DlRECTOR PUBLISHER Steve Ciarcia Daniel Rcdrigues digitalsignal processing in this issue’s theme articles. DSP continues to he a hot topic, with more and more MANAGING EDtTOR PUBLISHER’S ASStSTANT consumer and industrial devices showing up on the market sporting features Ken Davidson Susan McGill aand capabilities previously found only on very expensive equipment or not ASSOCIATE EDlTOR ClRCULATlON COORDINATOR found anywhere at all. Lisa Nadile Rose Mansella Does digital signal processing necessarily mean the use of a dedicated ENGINEERING STAFF CIRCULATKIN ASStSTANT digital signal processor chip, though? In our first article, we take a look at Jeff Bachicchi 8 Ed Nisley Barbara M&ski instances where some of today’s fast RISC processors actually look pretty CONTRIBUTING EDITORS CIRCULATION CONSULTANT good next to dedicated DSPs in traditional DSP applications. Tom Cantrell &John Dybcwski Gregory Spitzfaden Our next two articles move away from benchmarks and theory and into NEW PRODUCTS EDITOR BUSINESS MANAGER the practical uses of DSP chips. Audio spectrum analyzers have traditionally Harv Weiner Jeannette Walters been built using rows of analog filters tuned for specific frequencies. Using ART DIRECTOR ADVERTISING COORDINATOR DSP, though, our first project fits in the palm of your hand while analyzing Lisa Ferry Dan Gorsky the frequency content of a voice input and displaying the results on an CIRCUIT CELLAR INK (!SSN CWM9S5) is STAFF RESEARCHERS: oscilloscope screen. Our second project demonstrates the dynamic nature of plblishedtimmhlybyCirarilCelaIncuporalsd, Northeast 4 Park YJeel we 20.
    [Show full text]
  • Circuit-Cellar-018.Pdf
    1 EDITOR’S I’ve Seen the Future INK Curtis Franklin, Jr. 1 I recently led a panel discussion at the Embedded Systems 32-BIT PROCESSORS Programming Conference. I met interesting people, arranged for a few articles, and ran into lots of folks who were carrying crystal There weren’t many people talking about 8-bit processors at balls in their fanny packs. I thought you might like to know what the show. Intel mentioned the 8051, saying that they have now they say you’re going to be doing in the next few years... shipped over 100,000,000 of them, but that came as a passing statement at their press conference announcing the latest mem- OPERATING SYSTEMS bers of the 80960 family. Motorola was ready and willing to talk about 68030 and 88000 applications, National was discussing the You’re going to be using an operating system. I’m not talking 32000, and everyone was announcing the arrival of the 32-bit about the operating system on your desktop computer, but the future. Once in a while I heard talk about 16-bit chips like the complete multitasking operating system that you’ll be building 80186 and 8096, but there was a noticeable absence of discussion into each and every control project. Depending on who you talk on anything having to do with 8-bit applications. to, you’ll be using an MS-DOS variant, a UNIX variant, or a All of the predictions I’ve talked about are fine and probably specialized embedded 0s for your development.
    [Show full text]
  • View of J1 Should Be Used to Properly Connect the Computer to Your Power Supply
    TEC~N~CA~MANUAL REV 1.0 Micrhmint;lnc I15 Timberlachen Cirde, Sub 2001, Lake Mary, FL 32746 Phone 407-262- Fax 407-2620069 www.micromint.com .. ............................. COPYRIGHT f********x************n********* * * * RTC180, RTC52, BCC180, BASIC-180, and BCC bus rt * are trademarks of Micromint, Inc. .& * * * This manual is copyright (c) 1990 * * by Micromint, Inc. * * * * All Rights Reserved * * * * * f*Q**t*****f******X****k****** DISCUIMER ***********+**********ff******** * * * While we have attempted to provide accurate and up-to- * * date information in this manual, Micromint Inc. makes no * * representations or warranties respecting its contents. We reserve * * the right to make periodic changes to the text and to issue new * * editions of this manual without notification. t * * A occasionally in this manual we refer to other manufacturers' * * products. Such references do not constitute an endorsement of * * these products, but are included for the purpose of illustration * * or clarification. We do not intend such technical information and * * interface data to supersede information provided by individual * * manufacturers. * * * * * ...................................................................... Conditions of sale and Product Warranty Micromint Inc. and the Buyer agree to the following terms and conditions of Sale and Purchase: 1. Micromint Inc. extends the following warranty: a factory- manufactured circuit board or assembly carries with it a one-year warranty covering both parts and labor. Any unit which is found to have a defect in materials or workmanship will, at the discre- tion of ~icromintInc., be repaired or replaced. 2. A minimum inspection fee must be prepaid for the repair of units that are no longer under warranty. Call Micromint Inc. for a current list of fees.
    [Show full text]
  • Software a Lications Swimming in the Relational Lake
    r $3.95 April-May 1987 Software A lications Swimming In The Relational Lake . .................... 14 Designing relational databases. Expert System. ................... ............ ... .... 22 Gary designs an expert system with Prolog. Nasty Software ................................. .. .. .. 82 A plague of new programs in the public domain. Hardware Applications - Controlling The Real World ............................. 6 Build an 8-channel temperature scanner. The Bleeping PC ......................... .... ... ... 30 Stra nge noises fro m clonal counters. Who's Making Great Hard Drives ...................... 44 Read before you purchase your next hard drive. Changing the Picture ............................~ ...... 86 Super graphics from a new graphics processo r. o $3.95 April-May 1987 No. 35 p~~ :~::.J ~::.:~ UJ III <..: ):1 >:~. :::1 ill t:) i:'/ r:J :::: Software A~lications I:J ..... j'TJ ::1:) :".~~ ~ t 0.1 • : L> t~:J ~.;~: t "':1 :!:~: t:'l Swimming In The Relational Lake ...................... 14 :1.'., Designing relational databases. I . Expert System ......................................... 22 :.~ I it. l.n Gary designs an expert system with Prolog. :u Nasty Software ........................................ 82 A plague of new programs in the public domain. Hardware Applications Controlling The Real World ............................. 6 Build an 8-channel temperature scanner. The Bleeping PC ...................................... 30 Strange noises from clonal counters. -.j" Who's Making Great Hard Orives .....................
    [Show full text]
  • Circuit Cellar: Then & Now
    cover1.qxp 2/2/2007 3:43 PM Page 2 #200 March 2007 w w w . c i r c u i t c e CIRCUIT® l l a r . c o m CELLARTHE MAGAZINE FOR COMPUTER APPLICATIONS ROBOTICS Robotic Arm Servo Control Rolling Robot Circuit Cellar: ThenWWW.GiURUMELE.Hi2.RO & Now 03> 7925274 75349 $4.95 U.S. ($5.95 Canada) cover1.qxp 2/2/2007 3:44 PM Page 3 007 CIRCUIT CELLAR (1988 to Present) —Steve Ciarcia describes how he used his HCS to save a life (“A Home Control Event Worth Remembering,” Circuit Cellar 199) “Inside the Box Still Counts” — This was the title of my very first Circuit Cellar INK —George Martin is back with a C language tutorial editorial 19 years ago. Two hundred issues later I still believe it. Like solder being my favorite programming language, I still believe that however appliance-like 2007 (“Hello World … Want Cookie,” Circuit Cellar 198) embedded control and personal computing implementations become, we can’t for- get that the process of achieving that goal isn’t instant. In order to create the —Ed Nisley provides tips for choosing voltage references sophisticated devices and technologies regarded as off-the-shelf, many people (“Voltage References,” Circuit Cellar 193) still have to maintain real expertise in rudimentary design skills. Basically, some- —Tom Cantrell covers using the ’Net as a long RS-232 cable body always has to know what’s inside the box. —Steve Ciarcia, “Inside the Box Still Counts,” Circuit Cellar 200, 2007 (“Device Surfer,” Circuit Cellar 192) —Atmel AVR Design Contest 2006, Sponsored by Atmel, 2006 2006 —DesignStellaris2006
    [Show full text]
  • COMPUTER JOURNAL 190 Sullivan Crossroad JOURNAL Columbia Falls, Montana 59912 406-257-9119 Features Issue Number 29
    ~ II " " III I Programming User Support Appl ications Issue Number 29 ".00 Better Software Filter Design Writing Pipeable User Friendly Programs MDISK Add a One Megabyte RAM Disk to Ampro L.B. Using the Hitachi HD64180 Embedded Processor Designs The ZCPR3 Corner Announcing ACPR33 plus Z-COM Customization 68000 Why Use a New OS & the 680001 Detecting the 8087 Math Chip Temperature Sensitive Software Floppy Disk Track Structure A Look at Disk Control Information & Data Capacity ISSN • 07~9331 The COMPUTER THE COMPUTER JOURNAL 190 Sullivan Crossroad JOURNAL Columbia Falls, Montana 59912 406-257-9119 Features Issue Number 29 Better Software Filter Design Editor/Publisher A compromise that allows programs written under Art Carlson DOS to be pipeable. yet still user friendly by Kevin Lacobie 5 Art Director Donna Carlson MDISK Production Assistant Add a one megabyte RAM Disk to your Ampro Judie Overbeek Little Board by Terry Hazen & Jim Cole Circulation 13 Donna Carlson Using The Hitachi HD64180 Contributing Editors Coping with object code incompatibility, Joe Bartel wandering I/O addresses, and using the ASCII ports. C. Thomas Hilton by Kenneth A. Taschner & Frederick B. Maxwell 18 Donald Howes Bill Kibler 68000 Rick Lehrbaum An alternative to the PC for high performance systems Frederick B. Maxwell by Joe Bartel 31 Jay Sage Kenneth A. Taschner Detecting the 8087 Math Chip Routines which work on the XT don't always work on the AT. Entire contents copyright© by E. Clay Buchanan III 36 1987 by The Computer Journal. Floppy Disk Track Structure SUbscription rates-$16 one year (6 Issues), or $28 two years (12 How track structure and sector size affect the formatted capacity .
    [Show full text]
  • Circuit Cellar
    EDITOR’S English: INK The Forgotten Language? Ken Davidson I s the English language really so obscure that people have should have been caught early on. However, since he didn’t seem given up trying to use it correctly altogether? Granted, English is to be able to find anything else wrong, I think two bad words out one of the more difficult languages to learn due to its endless of the thousands in the issue isn’t half bad. He could have a field exceptions to rules. It’s usually more important to get your idea day with some other publications I see on the newsstand each across than to get all the parts of the language correct. My month. frustration stems from my recent observations of some so-called I don’t expect our authors to be able to write prize-winning “editors” that can’t even catch a spelling mistake let alone bad articles; I certainly can’t. I also don’t want to discourage anyone punctuation or grammar. from submitting an article because they don’t think it’s good Werecently started the search for additional staff editors. All enough; it can be massaged into something we can all be proud that we’re asking of these people is that they be able to read a raw of. What I would like to encourage, though, is that when writing manuscript; fix spelling, punctuation, and grammar; and convert a piece, have someone else look at it to see if it even makes sense. any “engineerese” into readable English.
    [Show full text]
  • Excerpts from the Circuit Cellar BBS CONNEC
    WWW.GiURUMELE.Hi2.RO Words are wonderful in their ability to form vi- module puts an 80286,512K memory, and all of the “glue” sions and emotions in our minds. Such a simple word as chips for a working AT-type computer into a package only “home” can, with itsassociations, bring a tear to a weary slightly larger than an 80486. The engineers at Mi tsumi see traveler’s eye. Other words, take COMDEXasanexample, the 80286 playing an increasing role in embedded applica- can produce fevered visions of technology oozing from the tions, and they are pushing the idea of the entire computer very pores of casinos while armies of disembodied feet as a plug-in module. According to the engineers, fax plod through aisles stretching to infinity.. machines have already been designed around their 80286, Can you tell that I just finished “doing” COMDEX? A and more products are on the way. I think they may be on week of strolling past the latest in microcomputers has left to something with this approach, and we’re working on an me tired and footsore, but encouraged about the future of article showing how to use the module in applications. the small computer industry. A side-effect of the 80286’s move into embedded applications may be the demise of the 80186. The ‘186 has MS-DOS MARCHES ON... been a favorite of designers who wanted to develop soft- ware under MS-DOS but needed more oomph than an . ..or more accurately, the Intel 80x86 family keeps 8088 could muster. Products like the Mitsumi module rolling.
    [Show full text]