Search This Blog

Showing posts with label computers. Show all posts
Showing posts with label computers. Show all posts

20150201

Dual Video, Dual Monitor Project (satire)

Disclaimer: Everything discussed in this article is presented as-is as a treat for fellow computer hobbyists. By publishing it, I make no endorsement of any code contained or Linux application working on your specific Linux computer system. Nor do I advocate adding a second monitor and video card or more without carefully thinking through everything before preceding.

Note to anyone wishing to take up computers as a hobby: this article is an exposé of the past two day the project as entitled in the header above. I would rate it as overly complex, considering that I did not include full files. However, there is a picture below to show the result of what I started almost ten days ago.

After posting this blog entry to GooglePlus, it may be subject to editing to remove any spelling mistakes or syntax errors. YMMV

Update: 20150202.0055H PST

Here are the promises pictures of my completed Dual Monitor Project:

Since January 23, 2015, I have put together a dual monitor computer system.

Here are the specifications on the PC: It's a HP dc5000 SFF(PB480A) with Intel(R) Pentium(R) 4 CPU 2.00GHz, 4 GB of RAM and 250 GB HDD.

For video it uses a 82865G as display controller integrated with the motherboard. What this means is that the 82465G provides a VGA output from the motherboard to hook up to a Samsung LCD monitor. I also added a second video card with VGA output, which is a 3D Rage IIC PCI [Mach64 GT IIC]. It also hooks up to an IBM LCD monitor.

After adding the IBM 1024x768 monitor and the Mach64 video card by putting the video card in the appropriate slot and screwing it in, I configured a new xorg.conf, following the instructions in the manual found by executing the following command:

$ man xorg

It led me to this command:

$ xorg -configure

When you run xorg with the -configure option, it creates the xorg configuration file, xorg.conf.

Next I edited the file until I got it to run both cards.

Here are some excerpts from xorg.conf:

Section "ServerLayout"
Identifier "X.org Configured"
Screen 0 "Screen0" 0 0
Screen 1 "Screen1" RightOf "Screen0"
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection

...

Section "Monitor"
Identifier "Monitor1"
VendorName "Monitor Vendor IBM"
ModelName "Monitor Model L150"
EndSection

Section "Monitor"
Identifier "Monitor0"
VendorName "Monitor Vendor Samsung"
ModelName "Monitor Model SyncMaster740N"
EndSection

Section "Device"
Identifier "Card1"
Driver "mach64"
BusID "PCI:5:4:0"
EndSection

Section "Device"
Identifier "Card0"
Driver "intel"
BusID "PCI:0:2:0"
EndSection

...

The file xorg.conf is moved to the folder /etc/ using the sudo command to give me temporary super-user powers:

$ sudo mv xorg.conf /etc/xorg.conf

Afterwards, any corrections to it need super-user powers.


Since the Samsung monitor has the dimensions of 1280x1024 and the IBM monitor, 1024x768, they got set up after a reboot as Screen0 (Monitor0) and Screen1 (Monitor1). Card0 (the onboard Intel video controller) is attached to Monitor0 and Card1 (the Mach64 VGA PCI card), to Monitor1.

Respectively the output to Monitor0 is called Screen0 and the output to Monitor1, Screen1.

Overall, here are the dimensions of the master Screen0 and its slave Screen1:
$ xrandr --screen 0
Screen 0: minimum 320 x 200, current 1280 x 1024, maximum 2048 x 2048
VGA1 connected 1280x1024+0+0 (normal left inverted right x axis y axis) 338mm x 270mm
1280x1024 60.02 + 75.02*
1280x960 60.00
1152x864 75.00
1024x768 75.08 70.07 60.00
832x624 74.55
800x600 72.19 75.00 60.32 56.25
640x480 75.00 72.81 66.67 60.00
720x400 70.08

$ xrandr --screen 1
Screen 1: minimum 1024 x 768, current 1024 x 768, maximum 1024 x 768

Originally, Screen1 would not work.

Specifically after boot up, the enable flag contains a 0. I figured that the enable flag need to be toggled from 0 to 1.

So I created a file called enable-video to fix the problem:

$ cat bin/enable-video
#!/bin/sh -e
#
# enable second video card
echo "1" > /sys/bus/pci/devices/0000\:05\:04.0/enable

The above command puts a 1 into the enable flag, turning on the device.

As you will note, the BusID "PCI:5:4:0" corresponds the device on the pci bus known as "0000:05:04.0".

This solution worked, but it eventually would get time consuming to boot up Linux, wait until Screen0 came up, run enable-video in a command-line window, and pkill X in super-user mode.

So after a couple days of searching, I decided on placing it in /etc/rc.local. In order to implement this decision, I copied the enable-video file to the folder /usr/local/sbin which is where all user-created system files go.

Then the following two lines went into /etc/rc.local, a line above the 'exit 0'.

# enable screen1
enable-video


This worked for a little while, but I now ran into the blank screen problem. The system would boot up but halfway through, the system would get confused and only enabled Screen1, all 1024x768 of it as Screen 0.

So, before the enable-video command, I placed the following command to remove the framebuffer:

# remove framebuffer
setpci -s 00:02.0 F4.B=00

No change occurred. Screen1 lights up. No Screen0.

So I researched this problem with the help of Google Search, and came across the suggestion to update the file grub.cfg
in the folder /boot/grub.

All this meant was changing the file's contents for the first image of Linux to boot until thing worked. Then the next thing to do was to implement the change using /etc/default/grub.

/etc/default$ cat grub
# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'

GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`echo CrunchBang`
*GRUB_CMDLINE_LINUX_DEFAULT="quiet i915.modeset=1"*
GRUB_CMDLINE_LINUX=""

# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"


That is it: set the mode to 1 for i915.

Then I ran update-grub in super-user mode.

At this point all the hard stuff is finish, and it took about two days to get to this point.

Since partially upgrading to Debian Jessie, a favorite highly configurable system monitor called conky broke. This means the usual startup sequence got changed because conky is not an essential part of Linux.

So as a workaround, it's placed at the end of the file .profile in my user account home directory at "~".

# Since upgrading to Debian Jessie, conky is broken and does not
# run after logging into the system. So run the appropriate tool.

# Detect Screen 1 and redirect to display to it
scrn=$(xrandr --screen 1|cut -d " " -f 1)
if [ "$scrn"=="Screen" ]; then
DISPLAY=":0.1"
fi
conkywonky

Just to work in a dual monitor system like mine, I put in the four lines of BASH code to check if Screen1 is enabled, and temporarily create DISPLAY so conkywonky runs for Screen1. The command DISPLAY=":0.1" helps redirect video data to Screen1. "0.1" is Xwindows speak for Screen1.

Unfortunately, it may be harder to run HTOP, an application used to monitor all processes on my computer in real time on Screen1 due to the fact that it is an Xserver savvy app.




20140918

My First Technology Gig (satire)

It is amazing to see how wealthy retirees live in their big houses with two cars, two computers, a laptop, a tablet and a cheap HTC smartphone. (I won't mention the LG 230 flip phone much).

The new SUV is cool with an entertainment centre using bluetooth to hookup to the phone to play music on.

People this old will not have a clue of how to move their pictures off their phone onto their computer, and to put new pictures on their phone again. Nor will they know that they need a data USB cable to copy to and from their smartphone, or even how to get their phone to send music to their entertainment centre in the SUV.

Furthermore, they need to be reassured that knowing their computer password won't let me break into their computer on the Internet - I have to be in the den on their computer to do that. Also Facebook never automatically shares their intimate photos with the world - they have to do that themselves.

That is where I come in, to help them learn how to do it. Though, at their age, without daily practice, a week later they will have forgotten how to do it because they do not practice what I preach to them.

I think I have found my niche market for my technology skills: people over 60. Since it isn't right to charge them $80/hour, I'll take $20 a lesson, which can last from an hour to two hours.

There is no way I'd stay any longer. My reasoning is, it is impolite to stay at anyone's place for more than two hours unless they expressly have invited you for dinner too.

I sure like this new part-time job that I lucked into by helping my client Paul with his smartphone while at an LDS baptism last week.

20140214

Linux on a Modest Budget (satire)

Originally, this article began as a post I might have posted on the Linux Community on GooglePlus but decided against posting because of my nonchalant attitude after writing it.

However, rather than face the prospect of apologizing to the many Linux users who invest a lot of money in their machines, I decided to write this article on my blog instead.

This article is not for them. It is for the people of modest means who want Linux on a used PC that may or may not run an old copy of Windows.

To make a long story short, I decided to use a screensaver on my Linux PC and picked Slidescreen.

After using the screensaver for a couple weeks, I noticed what appeared to be screen burn-in on my monitor. Actually, it is image persistence. Given that this is an LCD monitor made in 2006, I can accept image persistence, since it will go away in about two weeks.

To help my monitor recover, I changed the screensaver preferences to Blank Screen Only and left it at the default settings.

I am not overly concerned since it cost me under $100, and as a rule I buy according to my modest income from work.

My PC is worth under $300 used and I'm proud of the fact that Linux runs on it.

First starters, the 250GB Seagate hard drive came from an old Buffalo external hard drive I bought for $50 used. The motherboard is an old HP dc5000 SFF(PB480A) made after HP was merged with Compaq.

Originally made in desktop slim form factor (approximately 4" x 13" x 15"), the original maximum specifications state 3 GHz Pentium 4, Intel 865 graphics, 4GB, and 40 GB hard drive. The Intel 865 graphics chip supports 2048 x 1536 pixels.

Thus, the motherboard is capable of supporting a 1280 x 1024 monitor, 2 GB and 250 GB hard drive. To give it plenty of flow space due to the 2 GHz CPU, it fits into a spacious mid-tower case that's 7" wide x 15" high x 17" depth. On eBay, I've seen the motherboard being sold for $35 and the tower case, being so old it doesn't have any front mounted USB ports, probably could be picked up used less than $20. A matched pair of 2 GB RAM is available on ebay for $20.

In total that comes to under $221. After labour costs, the total cost is $400.

Most systems today give a bigger bang for the buck but usually cost $600 to 700 before taxes from a local dealer. Some places even will not supply an operating system on request. Best Buy only offers name-brand PCs from Dell and other PC manufacturers but their suppliers are locked in the Microsoft deal.

The only time Dell sells a Linux system is when they sell one of their high-end laptops with it. However, there are businesses around the world that sell Linux systems if you wish to go that route. If you're local to the continental US, then there are the five top Linux desktop vendors, according to ZDnet as of 2011.
LA Computers appears to have the best prices but Eight Virtues lets you choose from eight different flavors of Linux. Although they seem more expensive than comparable Windows systems, their expert support service is built into the price. Overall, these dealers are more knowledgeable about Linux than the average PC reseller.

However, I didn't need a dual core CPU or even a single core hyperthreading P4. Nor was I interested in a larger hard drive. If I wanted to upgrade my memory, then the maximum I'd pay would be $50 for 2 GB to fill it to its 4 GB capacity.

In the past, I've ran Linux on everything from full towers to tiny HP slim PC's made circa 2003-2005. All of these computers were used, being either computers that computer technicians threw away after giving up on them or a computer I bought because the price was right.

That's because my first rule for Linux on a modest budget is buy according to your budget, not what everyone else considers top of the line, preferably used and locally.

My best moment regarding Linux was getting a computer that could not run XP to run Linux. This is why I like Linux. My second-best moment was when I noticed my Linux computer was always faster than than my friend's computer, even though he had a Windows PC running at 3.0 GHz but I only had a 2.0 GHz PC running Linux.

Of course, his computer had collected malware which I usually had to delete on visits to his place. Once I even found that his Internet Explorer had not one but three toolbars due to installing new games and other unnecessary gadgets.

In exchange for getting rid of his malware, I got his significant other to cook me a meal that would cost upwards of $20 at a good restaurant.

That is my second rule: when living on a modest budget, helping other people I know on a modest budget means compromising.

Finally, my third rule is do not rely on Linux and your knowledge of computers to be your only source of income. My reason here is because most clients tend to abuse the fact that without certification, your expertise isn't worth $50 an hour or more. So if you can afford the cost, get Linux certification. Otherwise, find a career that you grow into.

In this way, I follow my Less is More philosophy. In the case of Linux, this translates into buying a used computer for less than new and add more value to it by upgrading to the only alternative to Windows 8 and XP, Linux.

Reference:

Image persistence: https://en.wikipedia.org/wiki/Image_persistence

HP: The 2000s: https://en.wikipedia.org/wiki/Hewlett-Packard#The_2000s

HP/Compaq Desktop System Board 368427 Motherboard DC5000 Series Rev 0G: http://www.ebay.com/itm/HP-Compaq-Desktop-System-Board-368427-Motherboard-DC5000-Series-Rev-0G-/261381597830?pt=Motherboards&hash=item3cdb8eaa86

Businesses that sell Linux pre-installed: http://linuxpreloaded.com/

ZDnet's Top Five Linux Desktop Vendors: http://www.zdnet.com/blog/open-source/the-top-five-linux-desktop-vendors/9313

Unix and Linux Certification: http://www.itcertificationmaster.com/it-certifications/unix-and-linux-certifications/

20131231

An Immoral Proposal Regarding Crackerjack Kids (satire)

Does anyone know of a good way to get medicinal nutrition into the food supply to help children who misuse their computer access to bully, harass and terrorize the world? You know, the crackers mistaken for hackers?

Perhaps it is possible to super-size those fries with yam genes? And through selective breeding, the farm factory industry are able to create cows that produce a higher yield of choline (source of acetylcholine), tyrosine (source of the neurotransmitters dopamine and noradrenalin) and tryptophan (source of serotonin) in addition to pyridoxal (helps create neurotransmitters and retinol (improves eyesight) derivatives along with thiamine (improves mental acuity)? Or the vegan equivalent of grains and nuts to boost brain power? Yes, I am suggesting we move beyond hacking computers.

Where's the gene splicing kits for tomorrow's gene hackers? We may need to make a smart-drug neuro-peptide with nutritional co-factors piggybacking within the polypeptide chain.

Additionally, I feel that crackerjacks need to be inoculated with a special virus to enlighten their current methods of social control. Perhaps that's what they mean by "a dose of humility."

Originally posted: February 10, 2007 1:31 PM

20130315

Sane Computing

If computers are controlling your life, here's a tip:

If a person spent most of his time away from computers during the day, then that leaves just enough time to play games, and answer email.

If you work using your computer, then apply the seventy-five minutes of work with fifteen minutes of break guideline to computer use, not three hours or more a day!

This time management guideline is useful in post-secondary education. A few instructors even allow for a five minute smoke break at the forty-five minute mark, and use the final thirty minutes of class time for reviews, tests or Q & A.

It is unhealthy to be on the computer for more than ninety minutes without any break. One might develop irrational agoraphobia and other anxieties the longer one sits in front of a computer. Additionally, there have been Emergency Ward anecdotes where children have suffered a rare seizure from playing video games for over three hours.

So, treasure your time away from your computer at home.

If you use computers at work, then your work place should have a time management plan in place. Your Human Resources department should also be asking the IT guy in your company to filter out Internet Messaging and porn sites, in an effort to reduce computer misuse at work, which are a waste of business time and productivity.

The above statements have not been written to profit any time management company, nor was it motivated with anything other than to advocate for sane computing both at home and at the workplace.

YMMV

Original post: May 24, 2010 1357H
Update posted: March 15, 2013 2339H

20121019

Thanks for Helping Me Better Access the Internet, Google!

Although I am a fan of 1930s & 1940s movies, I wouldn't want to live in those times. It really wasn't a great time because of the harshness of those times. The Depression had caused worldwide inflation. Innocent groups of people were being blamed for Germany's economic problems.

Even so, it may have been a simpler time for the people living then.

Today, my computer makes up for living in this post-modern world. Life is much more complex today than it was 70 years ago. We had our security shattered by 9-11. Subsequent wars in Afghanistan and in Iraq are now in the process of being discontinued. Small conflicts have been ongoing in many different parts of the world as well.

Locally, it's become harder to find a job. It's even harder for people to know others, as well as they know themselves.

When I walk away from the keyboard, I don't worry about what is happening in the world. What's the point of needlessly stressing myself out? Things not immediately affecting me are ignored.

When I am dead, life will carry on. Nobody but my closest friends will remember me. Though they will carry on with their lives, some of them will have benefited from knowing me. For my cares will be over forever in that future time.

As of this moment, I am happy and upbeat, because many people are counting on me to remain positive and a few of them actually need me.

This is why I appreciate having a computer. With it, I am able to share my deepest feelings with other people.

For I alone have decided so very long ago to use the Internet to motivate me, not crush my spirit.

So thanks to the internet, I've made a lot of friends and am thankful to each and every one of them.

20080110

The Challenges of Japanese on Computers

After studying the Japanese character challenge in Terminal and Konsole, I've noticed that Kterm displays Japanese well, despite the annoying fact that desktop entries for applications may have descriptions that are displayed perfected in UTF-8 format without problems.

As a consequence of my research, here are several things I've discovered about Japanese and computers:

Most Japanese using computers use several programs together that help them write in Japanese. This consists of typing in Romaji, which one program recognizes and translates into both Kanji and Hiragana, but very litttle Katakana, which is reserved for transliteration of foreign words. To conserve typing, most words rendered as Katakana in Japanese retain their foreign spelling (as best as the particular Japanese writer can muster, based on whether they graduated from an ESL cram school). So, technically Japanese compuer enthusiasts actually write in ASCII character sets (charsets) but it gets translated into one of four charsets - Shift-JIS, EUC-JP, JIS-7 or ISO 2022-JP. As well there is Unicode.

When W3M or Links2 displays text, it isn't in UTF-8. It's ISO 8859-1.

Most applications that run in the BASH shell will display correctly if they have an option to use alternate character sets such as 8859-1, which may be programmed into the particular application, though with l10n, by installing more than just English, the font manager will translate fonts to be displayed in UTF-8.

Links2 does not correctly use UTF-8 and is based on 8859-1. It needs a UTF-8 upgrade, or at least, the current version I got for Dapper is not working.

I have also discovered that several apps (pyDict) isn't set to display as UTF-8.