Saturday, September 22, 2007

RS-232 ACHEW!~ STICK DCN386

BREAK

One questions you can answer in point form sentences, the one question you can answer is RS-232 , now RS-232 to us is an unknown factor,

When he was our age rs-232 was the most important thing in the universe, in the 60’s RS-232 is a modem interface, an interface is, when you have two different technologies working together you require an interface,

Now when he was small computer where new modems were new, they were two different technologies inter-phasing,
The EIA standards groups started the RS-232 interface, first we must know it was bad, it was based on technology in the 60’s which is terrible, but the thing RS-232 its still around, remember 70% people of the world are still using modems, when they go buy this it will say RS-232, even know the
EIA have developed dozens very very good interfaces and RS-232 is still around, RS-232 is a set of instructions that allows computer to talk to its own modem, …..drawing of a computer a
DTE, to a DCE ur computer is attached to a serial cable to your own modem, down the serial cable signals can be sent both ways, the second thing you must know about RS-232 is it was developed in the 60’s data communications was in its infancy and the world was using something,
half duplex transmission an ancient system computer sends data and a computer receive data but not at the same time, modems attached to ur phone data you can transmits and receive data but not at the same time…

…lets look at the interface as it once existed a computer wants to send data, we want to send 0100001 A to another computer the interface working with the os will do the following, find a modem a little thing with a thick cable and if u cut the cable u will see how many wires are inside….when RS-232 was developed, …look at ur serial port even today they still have a serial port in the beginning their was
25 functions…..in a serial cable RS-232 has 25 functions at 25 functions because even though RS-232 can handle Asynchronous trans or Sync transmission, RS-232 is older then PC’s

IBM is in manufacturing PCz, which recognized all PCz will be Asynchronous, if a PC is going to be Asynchronous we don’t need 25 functions we only need 9 functions, RS-232 can do Async and Sync if it’s a = 9 S =25, each wire in the serial cable represents one function, k we want to send the A
INT14 data sends to the UART but the UART cant simply send the data, the UART asks how does it know if its being used by the new computer, first the UART sends a signal down one of the wire in the serial cable
….request to send, RTS pin2 in your serial port if your modem receives your signal in pin2 it know your modem has made a request to send data, what does the modem do, it looks at the phone line if the phone line is idle then the modem sends a signal back to pin 3, pin 3 clear to send….then modem also down the wire a carrier wave, that means the opposing modem cannot send data cause the current modem is sending data, it issues a …….clear to send CTS, then the modem sends the data another little wire in the modem called transmit data, even though RS-232 can have 9 or 25 functions only functions are used for data the remaining functions are all about controlling the data, sends the data down the pins to receive, transmit, send data,

rts cts


Now a modem is a separate device from a computer, when ur grand mama hade a modem she probably had an internal modem, how does the modem know it is turned down, what happens how would the modem know, it knows but the RS-232, one of the functions is used as soon as you turn on a modem the modem sends digital pulses to the computer …..Data Set Ready, DSR, the computer knows its on cause it sends down Data Set Ready, Data set is what we cal it…not modem….the computer now knows its turned one conversely how does the computer know the modem is turned on it does
……Data Terminal Ready, and they can start to communicate,

How many functions we got? 6.

Friday, September 21, 2007

Rogers vs Simpatico ----MUXXXXXX STATTTT DCN386

He is going to use the same test as in the spring, we will continue on with the theme of multiplexing we talking about stat mux and t1 mux we are going deeper into the world of multiplexing, picture Rogers Cable head office it has four satellites on the top of its roof that put out ur cable signal, today we are going to be talking about Rogers modems how their good and bad, when you watch TV you are watching a mux signal, when people make tv programs CBC CTV and DIC, people make program say CBC, if CBC would like to transmit this signal through our cable lines they must send it to Rogers so he can put that tv programs on our tv through our coaxial cables, it just so happens for high speed video like your tv, you require to send a signal that’s six million hz, got it, that’s a lot of hz CTV wants to make a program and dic must send it all at six million hz they send it using satellites, now Rogers, has put coaxial cable throughout Toronto 100s of kilo coaxial cables come in many grades, thick copper wire, by insulatiord surrounded by wire mesh very expensive. Coax has incredible bandwidth…means high range of frequency, what coax cable can handle? Coax cable can easily carry 600mil hz, accounts for the fact you can get approximately 100 tv stations,
How does this work? 100 programs coming one wire all at the same time.
How do they not interfere with each other, how come….multiplexing….

CBC 600mil hz Rogers feeds it into the multiplexor, each send it so

CBC 0-6 CTV 6-12 DIC 12-18

All simultaneously down you cable, because of the frequency range they will not interfere with each other, ur remote will change to the channel and filter out every thing

What is this to do with data com…nothing except Rogers cable have offered high speed internet connection what they have done is reserved 1 600million hz channel for you to use for data, they give you ur little modem attach it to your computer and ur computer has access to 6mil hz, think about it 70% people in the world are using ordinary modems and those modems can handle 4000hz and they can achieve speeds up to 50000bps think about this 500000bps out of 4000hz think about wat you can achieve with 6mill hz, cause ur using coax this is available to you, using QAM, rogers can provide ULTRA high bandwidth at ur disposable, but the shit thing you share the coaxial cable, Rogers ultimately will be a victim of their own success, the more customers the slower the service will become.

Simpatico 4000hz, from your phone line how is it possible to get high speed down this?

They attached tthis a local loop, twisted pair cable, when you talk on the phone its an analog signal, which travels down the local loop to the phone company, you use 4000hz, how is this possible, what happens? U will see very thin copper wire, but even thin phone line, very thin copper wire, is theoretically cable , not only 4000hz but up to 1 mill hz, think copper wire is capable of this so why do phones not use that…cause it’s not necessary, what happens when you get simpatico, a bell technicians disconnects you phone line from the existing phone line network, she reconnects you not to an ordinary voice switch but to a new switch a DSL switch the DSL switch sends an receives up to a million hz, what do you do? You replace your modem with another device which bell engineers call a DSL modem but its not a modem it’s a digital device, now attached to a dsl switch….the dsl switch takes the million hz and breaks that million hz into three different transmission bandwidths, dsl is a mux service just like Rogers, when they send tv and data signals, broken up to three discrete bandwidths,

0-4000hz ---- first band width is (dsl modem) the phone attaches to the dsl modem so for voice the old traditional bandwidth is maintained signals going down ur dsl modem it is reserved for additional phone services, why didn’t they increase this cause its pointless…..when the DSL switch notices the signals, it simply transmits those signals to the ordinary voice switch. You need filters to filter out everything over 4000hz,

4K-1mhz – the dsl modem reserves 4k and approximately, this is for out bound data
100,000hz – 1m hz – in coming data

Why did the DSL designers do this?
Download faster, they know the internet user submits a little, but you get a ton of data in return, this is called

Asynchronous
ADSL

Sychronous
SDSL – bandwidth split between incoming and outgoing….

DSL is still an emerging technology going to get faster faster, in the states they have this already sounds amazing but their a problems, Rogers has a problem and simpatico has a problem…..Distance….the higher a frequency the more power you can send it, it’s a factory of life, the higher the frequency the more power it needs, attenuation happens, if you are a happy simpatico user and you live right next store to you bell office you are getting incredible internet connection, if you have a sensitive, you can literally see every step you take from your phone company the frequency becomes less recognizable that there is a maximum limit your phone line can be, theirs a part of silicon valley, they cant get high speed DSL cause its far from the phone wire, 18,000 feet is the maximum distance, you can see why doesn’t bell install amplifiers, expense, Nobody is sharing ur phone line like Rogers, ur phone line is urs, because phone system was designed for lower power operation the frequency is high and attenuation level is high, distance is the enemy of the happy cable user, the DSL switch is so intelligent it can determine the level of operation and it will deliberately slow down if the DSL modem recognizes the signal is weak, which means slow speed.

Rogers is a three mark questions
DSL is a three mark questions,

Wednesday, September 19, 2007

Economics - ECN550 GEN

DOWNLOAD BLEACH!

Quiz Review

Get the most for the least
Supply = production
Demand = ppl want it
Price vs Quantity

Rule #1 Cost goes up, conssumers want less and producers make more
Rule #2 things work themseleves out in the end...equilibrium

We act to max our utility(happiness)

Homoeconomics - we all go for our utility(we are all jerks)

DMU- Dminishing Marginal utility the more the worse off we become....beer ruel

OC- Opportunity cost - what you must give up to get something

Marginal Cost - Devisions that are made at the margin

Economic Efficiency - get the right amount

Backbending Curve - Working more reach efficient sum, take days off to spend it.

Bartering - come to an agreement

Incentives matters --tax cheating

4% GDP - Gross Domestic Product - all goosta and services produced in a given year
GDP = CIGS
CIGS - Consumption, INvestment, Guv, Import - Xport

Make Money - wages interest profits rent

Everything in must go out

The circular flow -- people guv firms

Recession - two consecative quarters of negative growth....its a contraction

GNP - Production of Canadians
GDP - Production of Canada

<2% Inflation - the value of money decrease

Human Capital
Physical Capital
Technology
Natural Capital

Production POssibility Curve.....

This will be updated when done done

Tuesday, September 18, 2007

DCN386 Questions From W1&W2

1. Can you send data through a vaccuume?
2. What is Token Ring?
3. What do protocols do?
4. How do protocols work?
5. Identify four standard making groups, what did they do or are doing?
6. What is analog transmission and how does it work?
7. Why is digital good and analoag is not?
8. What is amplitude, frequency and phase change?
9. What is digital teachnology and how does it work?
10. Why do signals diminish?
11. Why did the world go digital?
12. What is Ethernet and how does it work?
13. What is T1 Mux?
14. What is Stat Mux?

OPS435 W3

OPS435W3
& - when you want to run any command or program in the background,

Foreground which u are running, running a program in the background you can have control while the foreground no

&& - com && com2 checks to see if the first command is successful then execute the second command.

Who | grep username

Com1 || com2 - || - not successful then execute this command

|| && is similar to if and else

Ls, who, pwd > f1

Use ( ) around commands that means you are grouping them together.

$(com1;com2) command substitution

(( )) – arithmetic expression – this is how the shell does arithmetic, this is used, for a couple of diff things, one arithmetic, also use the command to assign the results of a arithimitic function to a variable.

First put this a = 3 b=5
((c=b*a)) shows output

$((c=a*b)) shows standard output

echo $((a + $b*2))
u can use
+
-
*
%(remainder)
**(power of)
/
The shell does not care if it’s a variable name in this case when you don’t put the dollar sign infront it treats it as a variable name, this is a arithmetic command, everything inside it has to be numbers, since the shell knows, the moment it encounters text it says this must be a variable and replaces the variable name with the context, the shell automatically knows this, u may use it or not.

Echo $(( a**3 +b*6/3-1))

Display the remainder, this command is an integer number.


This week,

>> append
> replace

Pattern matching file name expansion,

Understanding Expansion

Echo Jim$d
JimBrown
Echo $dJim
Blank(nothing) no variable dJim

Echo {$d}Jim --use braces
{Brown}Jim

Appends the variable name within braces, leads us to the next item the braces can be used in many different forms to achieve many things
${var:offset:length}

This lets you cut poriotions of data from a file, we used cat for a variable and a file, this is a better way of doing it

Bd=19871223

Echo ${bd:0:4}

Echo my birth year is ${bd:0:4}

echo "The month of my birth is" ${bd:4:2}

Assignment will require you to do the following write s script anyone can use, the script will ask the user to enter the birthdate in the yyyymmdd and u take their birthday and tell them how many years month zodiac sign, Chinese anymore sign is, you are going to be using these formants and be doing all kinds of calculations to come up with the results.

Another thing you need to do , listen to this applies to every system, the following will apply, any time you ask the user for data, you never start using that data unless you verify it.

Before you start cutting out stuff u must verify the data is correct, so number one how many char do you except this data to be…8.... they have to be all numbers…check the date is valid.

This will tell u how many chars the data of a var contains,

Echo ${#bd}
# - tells you the

Echo puts a new line char at the end so you will get the wrong character, if you use the construct we have previously use it will be more correct,

Cover unique

Uniq unique

Sort unique | uniq -Cuts out the lines in ascending order

Uniq –d gives you the duplicate lines
Uniq –c – count how many lines exist in that data file

Cheat Sheet
Half a page of what you want, hand written.

Tr – translate, what this does it translates chars to this to this,

Tr abc 123 < galileo.txt

< input redirection

Every a = 1 b = 2 c=3

Tr ‘a-m0-4’ ‘n-z5-9’ Galileo.txt

All the capital letters will not be touched, the small letters will, pretend u have a file, u can change the data, so even if they get hold of the file its meaningless,

Tr ‘a-mA-M0-4n-zH-Z5-9’ ‘n-zN-Z5-9a-mH-M0-4’ < Galileo.txt > junk

Tr –d ‘%./.,fda?’ Galileo.txt
Deletes all the characters

That’s ur tr translate



The Find command,
Find [directory to search in] goes through every sub through that directory
Find .

Specify a search with specific items that have to be matched, for a file name,

Find . –name nameoffile

Find command does expansion not the shell, the find command can use regular expansion char, many capabilities, prevent the shell from interpreting f1* how do you prevent the shell, a backslash, single quotes, double quotes

Find . –name “name*” -type f –perm 600 –mtime 10 –exec rm –I {} \;

Type file, permissions 600, or greater 600 u put a +600, a minus for less in front of the 600

Also these files have to be more then ten days old in other words last time their were changed, they have to be ten days ago or more


-mtime 10 tend days +10 greater then 10 days, the find command has to match eatch and every one of them before it matches that file. Another one, -exec another command, rm –I interactively, {} represetnts standard output of the find command, ill show the full path will be redirecting into the braces, its going to delete all those files but first ask you, because its exec the find command it has to know where it ends, looking for ; to see where it ends but is that a special char to the shell ;, you don’t it to interpret as its own so you have a back slash.

Linux administrator on the weekend last Sunday you did a backup what you did u used a utility called backup, /bin/backup, tonight 3am you wanna do another back up a partial backup, you want to back up any files that have changed since the last backup.
Touch ts
Find

Chron utility to specify time sequence, this command will reside in a special file that the chron deamon looks at

Find / –newer ts –exec /bin/backup {} \;

Backup all new files

Monday, September 17, 2007

Multiplexing MUX T1 & Stat --DCN386--

Why did the Ethernet guys pick a block size of 1500?
Token Ring and Ethernet
Token ring 64000bytes, why was this rule their, Why did IBM HAVE A BIG BLOCK SIZE?, have this in the back of your mind, why is it this?
Ethernet knew that every machine on a bus network will transfer data, and they will send it at the same time when they do it will be lost, if your designing a protocol so after theirs not a lot of collisions, there for if there is no data collisions you transfer bigger blocks…which would be Token Ring...

Why did it disappear?

Datacome situation you have not heard about this before, multiplexing, simple concept, means how does a device take multiple inputs, and transmit in one physical light, lots of ways of doing this, televisions signals are multiplex signals, or sympatico, you use multiplexing, Rogers is using the existing multiplexing signals the tv use……telephone gets mingled with other peoples voices …multiplexing.

This is data signals, if you got digital info that was once multiplexed, talk about time division multiplexing, TDM, we do this for money, this allows datacom people to transfer through one visible line multiple signals.

Leased Digital Lines come as low as
24000
48000
96000
640000

T1 1.54MBPS

96000  most common line speed, because in the bank branch is all text.

Pretend we are sending 24000, then we had a device a MUX and MUX at head office, you save money,

Time Division Multiplexer, next week, statistical multiplexer, the MUX reads one char from the input port and build a FRAME of data, every signal is 4000$ so if you MUX 9600kps you save only $500, you save a little bit,
He wants to hear about these on the test

Statistical MUX (Stat MUX) and how you can save a fortune, you can make a fortune

, know more about them the second one is the T1 MUX, a huge investment.

T1 MUX standard digital line speed 1.54bps, T1 Laid down by phone companies LONG time ago, now their laying fibre-optics replacing old digital copper wire NICs, T1 leased to co-operations. Why do companies invest money in these, long distance without the T1 MUX,

PBS – Private Bank Exchange how little offices hook up their phones

U hook up the phones and the computer to the T1 MUX works like a time division MUX, except you can have dozens of input lines, 24 phone calls to one T1 MUX 1.53, take 8 bits from each input port and build a frame, each frame 192bits, 8 bits x 24, at the end of 192 bits it puts a extra bit , separating bits, that was fine for voice, T1 are integrating these things with computer work so now its just data,

OPS335 Week 3 Third Lecture

OPS335
Week 3 Lecture 3

Last week review, we talked about harddrive, know what a sector, cylinder, head, calculate capacities, fdisk to partition the drive,

This week more detail about the booting,
• We began discussions on Linux boot up.
1. PC is turned on.
2. POST
3. ROM boot loader loads MBR code.
4. Code in MBR loads Linux kernel and initial ramdisk ( DRIVERS NEEDED BEFORE MOUNTING THE ROOT FILE SYSTEM)
If its ext3 you need a ext3 driver, once the root fs is mounted, before this you don’t have any drivers, you need some kind of a driver to mount the root fs, its small file and is brought in like the kernel the rbm code, the kernel has the basic drivers it needs to load the whole file system, one its done.
5. Kernel runs and does hardware detection(1st thing it does)
All devices accessible to I/O ports, when the kernel boots it will tell u all the things you have on your system, the kernel starts the init program, which starts all the services in your system.
6. Kernel mounts root file system. Driver in the camera be in here
Thousands of drivers on the FC7 DvD, now it has access.
7. init program runs (process ID=1). <-- First thing it runs PID
Init has no parent PID id, every other program has it plus a PPID,
8. init reads /etc/inittab and determines runlevel(state of the computer) (0-6).
7 run levels, 0 – halt, networking continues to work at level 0, RL 3 Multi-user Networking, RL 5 same as 3, but with graphics, . INIT TAB the init table tells us what init we want to go to. 5 Full Multi-user with networking and graphics. 1 is single user no network.
9. init calls the rc script. \
rc is a bash script, run command, this script is the one that calls all the scripts for all the subscripts, init calls rc, and rc calls all the scripts for all the subsystem.

/etc/rc.d, all start up scripts for you computer, /etc/rc.d/rc3.d> is for run level 3. Start and Kill.
10. rc executes startup scripts (/etc/rc.d).
11. System reaches desired runlevel.

Ps –ax all processes running
Ps –al long listing
More then one program occupying ram at the same time. All processes are in a tree,

tree ps -a /

Manage your process
Signal PID
Kill -9 4010
-9 is a hard kill
more /proc/cpuinfo
every program is run for mili second.
280,600,000,000,000
3.14159265^2

Lab#2 Focous on booting up the system
GRUB, Grand Unified Boot MANAGER (Loader)
LILO, Linux Loader
We are going to try both, lilo is old grub is new.
Linux kernel is on the fs /boot/vmlinux-2.6-22 the kernel itself is sitting on the fs, it could be ext2/ext3 , reiserfs , in order for the MBR to load the kernel, so the code in the MBR, we have to tell LILO where this file is ahead of time, which sector, when the LILO code tries to load in the kernel it will know the kernel starts at 1321, the lilo code will go out to sector and bring in the linux kernel, LILO does not know about fs,

What is a file system?
A file system is a filing system, there are different ones ext2, ext3, reiserfs all file-ing systems prepare the hard drive, to hold files differently, LILO itself does not care how its organizes he told LILO to start counting the files on the left and when you get to the physical sector it has to know where to go, somehow before we boot the system we have to install LILO we install lilo we put the LILO code in the MBR, along with the code you put the sector where the kernel is and the initial ram disk file.
Ls /boot, Z means its compress vmlinuz…read while its small and uncompress it in RAM more efficient way. For every kernel it has a corresponding initial RAM disk, this must be read by the drive by the LILO program. Four and half mb has to be loaded in by the boot loader..

In order to write the code to mbr we use the command lilo, /etc/lilo.conf the conf tells lilo where the kernel in ram disk is, once it knows this it figures out the sector, and writes the sector in the MBR, so when you boot you system you know where it is. What we do is we modify the file to suite our own needs.

Original MBR contains the GRUB code, the program when we save it is GRUB.


/mnt/sysimage
/etc/lilo.conf