Home Account Search
pc, mod, and geek articles
"Every day you may make progress. Every step may be fruitful. Yet there will stretch out before you an ever-lengthening, ever-ascending, ever-improving path. You know you will never get to the end of the journey. But this, so far from discouraging, only adds to the joy and glory of the climb." — Sir Winston Churchill
New Lines in .NET Simplified
I'm posting this article to help those Googling for information regarding new lines and .NET. I couldn't find a solution to my problem, but I did find an all-encompassing resource for it online (en.wikipedia.org/wiki/Newline). My problem stems from the fact that I am using a RichTextBox in .NET to save text to a file, then open that file with Notepad, and the new lines appear as unrecognized characters (ie: boxes). At the root of this problem is the multiple, different uses of characters to represent new lines. In .NET, a TextBox and a RichTextBox use different characters to represent a new line.

So why is there so much confusion over the subject? The text editors and operating systems of the world can never agree on how they use and display new lines. It all started with Microsoft creating their own standard (what else is new?), and then Apple computers following their lead. If they followed the example forged by the original UNIX, we wouldn't have all of these problems.

*NIX and BSD systems (Linux, etc.) use LF (line feed), aka: ASCII code 10.

Mac systems use CR (carriage return), aka: ASCII code 13.

Windows systems use both CR and LF together (CR LF)

Even within just the Windows environment, the problem exists across multiple applications. Windows' Notepad and .NET text boxes will use the Windows standard of CR and LF, while Windows' Wordpad and rich text boxes in .NET will just use CR to represent a new line. This means a document created in a rich text box will not show correctly in a regular text box or Notepad. Grrr!

Fortunately there's an easy solution. I solved my issue by running a replace command on the text within my rich textbox, to replace a CR with Environment.Newline (in Windows, this represents CR LF). To make this even more confusing, there are various ways of representing a new line in .NET. It may be included in a string, a char, or Environment.Newline. Here's a quick reference for .NET:

Where? Name String
ASCII (typecast as char) Special
Windows: TextBox, Notepad, Email (non-HTML)   CR LF   "\r\n"       ((char)13) ((char)10)      Environment.NewLine, StreamWriter.WriteLine
Windows/Mac: Rich TextBox, Wordpad   LF   "\n"       ((char)10) n/a
Linux: *nix text files, OpenNET, etc.   CR   "\r"       ((char)13) (various)

Examples of replacing text for transfering between a TextBox and RichTextBox and vice versa (the second example is just for show, as the first parameter of Convert could just be represented as "\r\n":

txtbox1.Text = richtxtbox1.Text.Replace("\n", Environment.NewLine);
richtxtbox1.Text = txtbox1.Text.Replace(Convert.ToString(((char)13) + ((char)10)),"\n");





MO Modbase for GX LCDs
MO Modbase is an application designed specifically to control Matrix Orbital's new GX Series (Typhoon) LCD devices. Unlike LCD Studio, MO Modbase will allow you to create your own LCD applets through a simplified scripting language. It does not currently have the additional overhead of LCD Studio since it is designed just for your GX device. Pre-release screen cap to right is functional, but scripting interface is still in development.

In addition, MO Modbase is free of the confusing process for obtaining a license. Even though LCD Studio is "free", it requires users to obtain an XML license file through e-mail. No software is truly free if it's not distributed under an open source license, such as GNU or one of the BSD licenses. This is why MO Modbase uses  the GFDL version 3. Freedom is all about source code.

Requirements:
  • Windows 2000/XP (untested with Vista, 9x, or Me)
  • Microsoft .NET 2.0 Framework (through Windows Update, or via direct download)
  • 24MB of RAM available (app and .net libraries)
  • Optional: Matrix Orbital GX Typhoon LCD device (virtual device available)
Expected release date: late October 2007. Be one of the first to enjoy scripting control over your GX: send me an e-mail to be added to my MO Modbase mailing list for latest news and updates. My e-mail is found in the navigation menu to the right. Thanks for visiting!


PC Mod Project: Nightfire (Part 8)
Near Completion. I spent quite a bit of time this last weekend pulling together the final details of the mod. I'm happy to say that I actually have it powering up all the way to an FF code. EVGA puts a two-character hexadecimal readout on the 680i board that reads FF when the BIOS has completed its boot routine. However, it didn't power at all the first time, since it did the brief power on and power off indicating a short. Fortunately it was just an internal USB header connection that I connected incorrectly by missing the alignment by one pin.

I still have to add the final CCFL that runs horizontally above the CPU cooler, wet sand and polish the left side panel, and install an O/S and software. Otherwise, it's now a working PC. Whoot!

The final task that took some time was threading the support rod for the video cards. I literally had to 'thread' it through since there's no other way to add all of the washers, nuts, rubber grommets, and sleeving at the same time. I even spent time thinking of alternatives to save myself the trouble, but that brainstorming process came up dry. So, to help speed things along, I threaded all of the rod both by hand and by electric drill. The threaded rods are easily gripped inside a drill's chuck.

Some photos of the inside area so far:



Various photos of the outside of the case:



PC Mod Project: Nightfire (Part 7)
Side Window Complete. I had to scrap my original plans of putting the side window on the inside of the side panel. The fans alone are just too close to the edge of the case. So I decided to mount the window outside of the panel, but paint the edges so it won't show through to the molding tape. I took advantage of this change in plans to make a small flame design on one corner.

Acrylic panel I am using that was cut and purchased at my local Lowe's. I later sanded the edges, then ran a propane torch over them a few times to gloss them up a bit.



I then covered the panel in painter's tape. I left about 1/2" (13mm) of the edges uncovered to paint. Next, I had to fuel my creative side and draw some flames. I took me a few times until I was comfortable with a style (merged tribal-like flames with automotive-style flames), and until I felt it conveyed the look I wanted. I'm certainly not an artist, so feel free to "flame" me about the design. *smile*



The paint turned out fairly well (nice and even), but polishing it resulted in mediocre results. It's probably because I didn't allow enough time for each coat of paint to fully dry before applying the next. Still, it looks pretty good, even if it isn't as shiny as the rest of the case. I'm content with it, given that I wanted to finish it this last weekend.



I used 3M automotive molding tape, at 3/4" wide (19mm), to line the edge of the acrylic panel. I applied it to the acrylic first because I wanted to ensure the edge of the tape wouldn't show, and it absolutely straight. I flattened the molding tape as much as possible with a roller to ensure that it will not be visible from the outside.



I trimmed the leftover molding tape from inside the panel, using the metal edge of the side panel as a guide. Here's the panel to which I'm mounting the window (notice how little metal there is), and then the entire finished side panel:



Dual Fans for CPU Cooler. I am quite happy with my plans to mount the CPU cooler fans along the four threaded rods I cut earlier. This is really a clean way to mount them compared to my other thoughts of creating a separate fan holder out of acrylic (which would take up too much space in the case). The only minor obstacle I need to overcome is finding a way to keep the fans isolated from the rods with silicon rubber mounts to dampen any vibration which can add noise.

The rods are the same diameter as the mounting holes, which forces the fans to make direct contact with the case. I could dampen it by mounting the rods to the case with rubber grommets, but this will cause the entire structure to sag a bit. That would be an unhealthy look. Instead, I decided to drill out the mounting holes a bit to give the fans some room between the rods and their mounting holes. Then, I'll mount the fans between rubber grommets. Some of the grommets I have are of the regular, hardware-store variety, and some are HDD mounting grommets. I used the softer HDD mounting grommets for the fan against the back of the case (since it has less room to move), and the rubber grommets for the fan in front of the CPU cooler.

Here's the photos of the hole enlargement. The plastic used for box fans is very easy to cut or drill.



I then had to mount the rods and the fan, often in cramped, tight areas. This involved a series of washers, nuts, rubber grommets, and eventually sleeving and heat-shrink tubing for visual appeal (shown later).



Sleeving. I sleeved everything within this case except the serial connector that mounts on an expansion slot bracket. That cable has its own black insulation, and I didn't want it to stand out because it would clash with the overall cable flow.

Here are the Enermax power cables with their own sleeving (which I think is ugly). Not only is the sleeving poorly done, but it also doesn't cover all of the cable in-between connectors. I removed everything and starting my own sleeving. The last pic makes the purple sleeving look pink, but it's just a bad photo. Sorry about that.



Here's a CCFL and a fan I sleeved:



PC Mod Project: Nightfire (Part 6)
Top window. I completed the top window by painting the inside edges black, adding the automotive molding tape, and placing the acrylic window. This should give a nice view of the inside.



Drive bay devices. Since this case is flipped, each 5.25" bay device need to have a custom rail mount. For devices that mount just like a CD-ROM does, I am able to cut off the top two of the four plastic pegs on each rail, and align the rail to the top-most screw holes. It sets the device only a millimeter or sow lower than it would normally be mounted, but this doesn't cause any issues since tolerances on the front panel can accommodate such variances.

The HDD cooler/silencers install nicely with the stock rails, but with a little modification. After cutting down the plastic pegs of each rail about half-way, they fit snugly into the heatsink grooves on the side of the HDD coolers. I couldn't be luckier with the positioning. If you ever do a flip on a mod, and the case has drive bay rails, you'll either get lucky or end up doing a lot of extra work to mount drive bay devices. It all depends on the rail design for the case.



For the 3.5" devices, I had to drill holes into the sides of both to have them line up with the default screw mount locations. Here's a couple of holes I drilled, then threaded, for the fan controller:



Inside of the case at this point, with the drive bay devices, PSU, and mobo mounted:



Support Rods. My next task involved fabricating some sort of support for the two video cards and the CPU fan. The video cards are much heavier now with the addition of the Vantec Iceberq coolers, so I do not feel comfortable just letting them hang in place. Also, I didn't want to put additional stress on the CPU cooler to hold the weight of a 120mm fan, so I'm going to support the CPU fan separately. To handle both of these tasks, I'm going to use steel, threaded rods, available at almost any hardware store. I've used this successfully in my first mod to support a single video card with a Zalman cooler.



I'm running a threaded rod up through the case and the corners of the video cards to give them support. I had to widen the holes slightly, and then drill a new hole in the sound card. Fortunately the Sound Blaster Audigy 2 ZS doesn't have any components in the top corner of its board. When I'm ready to install this support, I'll sleeve the rod, add washers and nuts to fasten to the bottom of the case and adjust support height for each card.



For the CPU fan, I've cut the thicker rod into four segments just 1/16 shy of 9" each (227 mm). Then I use them to mount the rear 120mm case fan and the CPU fan along the same axis. To test, I've bolted down just two of the threaded rods, and they alone hold the fan in place without any sagging at all. Perfect.



Inverter Cluster. As with most CCFL kits, the inverter boxes are quite ugly. I can name a single instances where Logisys inverters' fugly baby-blue color matches any color scheme. I do have a place to hide these under the bottom 3.5" bay, but they'll still show for anyone bending down to look at the bottom of the case. So, I grouped them together, and mounted them inside an aluminum cover I had left over from the Nexus fan controller. Three of them are a perfect fit inside a 3.5" area. I use automotive molding tape to mount them to each other and the aluminum cover.

I then masked off the connectors and the vent holes, and painted the whole thing flat black. I used a paint pen to finish off the details. I also wired it so that the front panel switch will work to power the units on and off. This means the grounds are always connected, but the 12V leads are switched. I mounted a male Molex connector on top to provide power and CCFL connection all on one side of the cluster. Also, I sleeved the cables in purple to match the rest of my system.



Sweet, the CCFLs work on the first try. To increase the brightness of one that was a little dimmer than the rest, I had to undo a sharp bend in its wires that was creating too much capacitance in the line. Because of the nature of CCFLs, running too long of a connection between the lights and the inverters, or running the wires too close together (ie: tight turns or bunching up the wires) will increase capacitance along the wires, and thus reduce the brightness of the light. Fortunately, I was able to keep my CCFLs at the stock length, and situation them so sharp bends in the wires isn't necessary.



Wiring. I'm getting closer to finishing this mod, but even after wiring up the inside, I will need to do some work on the side panel's window. This is almost a mini-project that deviates from my original plans, but I am certain the results will be pleasing. Here's my progression so far with sleeving and wiring up everything. Once the wiring is complete, I'll add the threaded rod mounts I worked on earlier.





PC Mod Project: Nightfire (Part 5)
Any mod that attempts to squeeze the most out of cooling and performance numbers will often include some 'lapping'. It is the process of leveling and smoothing a cooler's surface, specifically where the heat-sink meets the processor it has been designated to cool. Since I'm using third-party coolers, and since I will be overclocking quite a bit, I will lap each of these cooler's heatsinks.

Video Coolers. I purchased two Vantec Iceberq 6 coolers that fit a variety of PCI-E cards with NVIDIA and ATI GPUs. The only other third-party cooler I've ever used before is the Zalman fanless one that was an absolute pain to install. Compared to that cooler, these Vantec coolers are a breeze to install. I simply couldn't be happier in my choice of these Vantec coolers. Ease of install, quality of components, and design are all top-notch.

Even though I'd highly recommend these coolers, I feel the need to point out some of their drawbacks. First, they do lack a completely level surface across the heatsink, as shown in one of the pics below. This isn't a problem since I'm lapping, but I wouldn't recommend these if you don't plan to lap because of the degraded cooling performance. Also, the mounts stick out quite a distance on the back of the card, which is fine for single video card PCs, but could be problematic for those installing two of these on cards in an SLI configuration. Fortunately the mounts clear my sound card's capacitors by a millimeter or two. This sound card will be mounted in the PCI slot below the top-most video card.

Iceberq cooler as it came in the package, and then after I disassembled everything on it...



I needed to swap over the fan connector so that the card's fan controller will operate the new cooler's fan. The Iceberq has a larger 3-pin fan connector, identical to case fans for hook-up to motherboard fan headers. Therefore, the pins and connector are different compared with the smaller, 2-pin fan connector on the BFG video cards. Also shown is a BFG 7600GT OC stock, and one with the stock cooler removed, and the Iceberq GDDR memory heatsinks installed.



On to the lapping. Here's the heatsink removed from an Iceberq cooler, and the unevenness of its surface after a few passes on sandpaper...



I started with a plate of glass to ensure an absolutely level surface, added sandpaper, used duct tape to hold it in place, and then liberally applied a water and soap solution to keep the sandpaper from grabbing too much into the heatsink. First, I used 600 grit wet/dry sandpaper to get a level surface, then I swapped that out for 1500 grit sandpaper to remove the rougher scratches created by lapping with the 600. Here's the GPU heatsinks at various stages in the process. Note the two rings are still there at one point, then disappear later (the middle point would be nearly impossible to remove without grinding down the heatsink past its intended mounting height.



These used up a whole sheet of both the 600 and 1500 grit sandpaper. Here's a sheet about half-way through...



After the surfaces are completely level, and the larger scratches removed, I polished each with a copper and brash polish. This is an unnecessary step, but it certainly makes them shiny again for some nice photos:



Completed installation of the coolers:




CPU Cooler. The Scythe Ninja cooler, because of its size, is a little bit tricky to keep stable while lapping. I had to grip the heat pipes instead of the cooler's layers of fins in order to keep it flat against the sandpaper. Fortunately, this cooler is fairly level, and only the edges on two sides are a little uneven. It didn't take too much lapping to make it completely flat, but I was annoyed to find one mini pit (the size of a large spec of dust) show up in the copper after lapping a little. That means Scythe manufactured this cooler with who knows how many mini air-pockets inside the supposedly 100% solid cooler base. It took even more lapping to get past that area to level out the surface completely.

CPU cooler before lapping:



At various stages of lapping by wetsanding with 600 and 1500 grit sandpaper:



The copper used on the Scythe cooler is not of the same quality of that in the Vantec Iceberq coolers, so applying copper and brass polish afterwards was not as effective. It still helped a little:



The EVGA nForce 680i motherboard, A1 revision, with the memory installed and the tops of the non-solid state capacitors painted black for fun:



Using my custom mounting bracket, I had to cut out two small half-circles at the edge to avoid pushing up a stock-mounted motherboard heatsink. Also shown is a different angle of the top-side of my custom mounting bracket.