Introduction to MSW Logo



 

In this chapter you will learn about the following:

  • MSWLogo
  • Downloading MSWLogo and its windows components
  • basic MSWLogo commands and their uses
  • Exiting MSWLogo
To install MSWLogo 

MSWLogo will be downloaded then just install it

its that easy.

After installation we can simply search for MSWLogo

and open that awesome application

Introduction

A computer is a programmable machine. It does not understand any language you speak. You have to instruct a computer in a language it understands.

LOGO stands for Language of Graphic Oriented. MSW Logo is a programming language that a computer understands.


An Instruction or an order given to the computer is called program. Logo gets instruction through specific words. Each of the words tells logo to do one special kind of task. It can be used for drawing figures and designs , type text and perform arithmetic calculation.

Why should we learn the Logo language?

  • Because it is fun, lots of fun.
  • Enhances the logical sense of the children.
  • Develops programming skills.
  • It is real Computer Science.

Logo is a very easy and interesting programming language to learn. It has enough depth to virtually do anything, which can be done in any other computer programming language.


After Installation it puts a logo icon on the desktop of you computer

The MSW Logo screen has two parts



A drawing window above with a triangle shaped turtle in the center it is aka MSW Logo screen or graphic window


center triangle is turtle





window which is blow of graphic window or MSW Logo screen  is called commander window

We will write commands in the command line, i.e., the text box at the bottom of the Commander Window. To execute or run these commands, press Enter or click the Execute Button. We can also write and run more than one command online at a time.

The command history will appear in the gray box. Click a line in the history to make it jump to the respective command line, then we can make changes (if required). Once this is done, press Enter or click the Execute Button.

It’s like many Windows screens. The Title Bar is at the top. This tells you what window you’re looking at. The Menu Bar is right below the Title Bar. It holds the names of menus we’ll describe a bit later. 


we do every thing in commander window

The big space in the Commander window is the Command Box. This box keeps a list of what’s going on. If something goes wrong, you’ll see a message here. Below the Command window is the Input Box. This is where you type your commands. Over on the right side, there’s a bunch of buttons that can make things a little easier.



The Commander window is a separate window from the MSW Logo window. That means you can move it around, make it smaller or larger, or you can change it into a little icon. We work with this window a lot. So if you want to practice a bit, go ahead. 1. Click in the Title Bar where you see the word, Commander. The title bar of the Commander window changes color. 2. Press and hold the left mouse key down. Then drag the Commander window around the screen. The Commander window moves as you move the mouse. 3. Move the Commander window back where it is supposed to be and release the mouse button. 


There are five menus in theMenu Bar. You know what a Menu is, don’t you? You click on the word and up pops a list of choices.


File: This gives you a list of things you can do with your procedures; things like Load them into your workspace, Save them, Save them using another name, Edit them, and Erase them. 

Bitmap: Bitmap is a technical term for picture. This menu includes commands for working with pictures that you design. 

Set: You can change the type of letters and numbers that Logo uses by setting the “font” in this menu. You can also set colors. 

Zoom: You can Zoom in on your pictures to make them bigger. Or you can Zoom out to make them smaller. 


The Help Menu gives you some choices: 

Index: Click on Index to see a list of the chapters in the MSW Logo On-line Help. 

MCI: This is for Multimedia programmers, something we won’t be covering in this book. 

Using Help: This is a neat section. It will help you if you need help using Help. Does that make sense? 

Tutorial: That didn’t make it in this version. This book will have to do. You’ll find the tutorial on CompuServe and on the MSW Logo home page on the Internet. http://www.ultranet.com/~mills 

Demo: Select Demo to see a neat demonstration of some of the things that MSW Logo can do. 

Examples: Examples are just that, examples of MSW Logo procedures. Study these procedures after you finish this book to discover lots of other things you can do with MSW Logo. 

Release Notes: This tells you all about the things that MSW Logo has to offer. It’s the same as the MSWLOGO.TXT file in your MSW Logo directory. 

About Logo: This tells you who developed MSW Logo. It also provides e-mail addresses where you can contact the developers.


Here’s a list of the Commander buttons. We’ll talk more about them later as we go along. Halt: This stops all the Logo action right away. It does the same thing that the HALT command does. Trace: This turns the Trace command on. Click on it to turn the Untrace command on. Pause: Logo stops the action temporarily and waits for the Continue command. Status: The Status button brings up a Status window that tells you what’s going on. Yield: This tells Logo not to allow other programs to run while Logo is running. Reset: This button is like the Clear screen command. It resets or clears the screen. Execute: This is like pressing the Enter key. It tells the turtle to execute your procedure. 

The simple Logo Drawing Commands move the Turtle forward and backward and also turn it right or left. The commands and their abbreviations are given below −

  • fd – forward
  • bk – backward
  • rt – right
  • lt – left
  • cs – clearscreen
except for cs command each of these commands must be followed by one value called its argument. The arguments for fd and bk are units and those for rt and lt are angles that be an interger. A ration by 360 is complete rotation therefore a rotation by 365 is same as 5 degree






ogo has a number of other drawing commands, some of which are given below.

  • pu − penup

  • pd − pendown

  • ht − hideturtle

  • dt − showturtle

  • setpensize

The pendown and penup commands tell the turtle to leave ink on the screen as it moves or not to leave ink, respectively. The hideturtle and showturtle commands hide or show the turtle, but do not affect its ability to leave ink as it moves. The home command causes the turtle to return to the center of the screen. It may leave ink behind, when the turtle returns to the center of the screen. The setpensize command decides the drawing pen size.

  • penup or pu means pick pen up, so you can move turtle without leaving tracks.

  • pendown or pd means pick pen down, so you can move the turtle and leave tracks.
  • hideturtle or ht means hide the turtle, so you can admire your drawing.

  • showturtle or st means show the turtle, so you can continue your drawing.

  • setpensize means it can make the pen larger, easier to see. Default pen size is –[1 1].



Command Repeat 120 [ FD Repcount*2 RT 204] Repeat 750 [ rt 90 repeat 4[FD repcount*3 rt 72]rt repcount] Repeat 200 [FD repcount RT 50] Repeat 50 [FD 20 RT repcount BK 10 lt 10] Repeat 2000 [FD 10 rt repcount +0.1] Repeat 60 [FD repcount*5 LT 80] Repeat 100 [FD repcount*2 RT 91] To Star Repeat 45{FD repcount*5 RT 144] End Repeat 1800[RT repcount FD 10 LT repcount FD 5 RT repcount RT .1] Repeat 1800 [ RT 1 FD 10 LT repcount RT .1]


Repeat 120 [ FD Repcount*2 RT 204 ] To Star End

Comments