Wikipedia:Reference desk/Archives/Computing/2008 September 10
Computing desk | ||
---|---|---|
< September 9 | << Aug | September | Oct >> | September 11 > |
Welcome to the Wikipedia Computing Reference Desk Archives |
---|
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages. |
September 10
[edit]graphic design, etc.
[edit]Is there an umbrella term that includes subfields like graphic design, branding, non-linear video and audio editing, compositing and visual FX?--Sonjaaa (talk) 01:02, 10 September 2008 (UTC)
- Artistic design? --mboverload@ 02:04, 10 September 2008 (UTC)
- Desktop publishing? Sandman30s (talk) 12:45, 10 September 2008 (UTC)
- Computer graphics? SteveBaker (talk) 20:49, 10 September 2008 (UTC)
- motion graphics? --70.167.58.6 (talk) 20:26, 15 September 2008 (UTC)
- No! 90.235.12.16 (talk) 11:28, 16 September 2008 (UTC)
New computer?
[edit]Hey, it's me from Wikipedia:Reference_desk/Archives/Computing/2008_September_4#D:.2F_doesn.27t_read_discs. I had my brother install Spore on his computer and transferred the files over to my external HD, however the game is constantly freezing which is very annoying. Someone put an answer I didn't see:
That won't work. You could copy the entirety of the DVD to the external drive instead of installing it, and run the setup.exe from the external drive on your own PC however the game MIGHT have copy protection to stop that, but Spore runs without the CD so I think the only bit in place is the internet registration. TheGreatZorko (talk) 22:50, 7 September 2008 (UTC)
How would I go about doing this?
Anyway, I plan to get a new computer. What would you guys recommend? I'm reluctant to get Vista, but I don't think they make 'em with XP anymore. I also have one more question: how would I salvage my save files from Spore? It's on my external HD, but I'm not sure if the files are glitched up or what, so I was thinking of installing the program again onto C:/ on a new computer, replacing it with the files from my external HD, uninstalling it to get rid of everything but the save files and installing it again, but this would be time-consuming and kinda stupid. Avnas Ishtaroth drop me a line 01:59, 10 September 2008 (UTC)
- Quick note - just from a quick reading of your post you will not be able to install Spore without the physical CD in the drive. Spore has nasty copy protection. --mboverload@ 02:03, 10 September 2008 (UTC)
- "How would I go about doing this" - Hi. I'm the person that suggested this. It's rather simple really. Create a folder on the external drive (right click, hover over new, select folder), call it spore or whatever. Navigate to the CD in explorer, and select every file on the disc (Ctrl A should work for this), right click and select copy. Navigate to the exteranl drives Spore folder, right click and select paste. Wait a while because the game is about 4GB.
However if the game is actually running I'm going to go ahead and say the freezing is part of your PC issue. With Spore you are limited to 3 installs (unless you contact EA Support who are usually sort of speedy about getting that number reset for you) so I'd recommend not reinstalling unless you have to.
All your saves should be in your My Documents/My Spore Creations folder.
If you do get a new PC don't fret about Vista. It has come a long way since release, and any laptop with 2GB of memory or more should run it more than fine (You may want to turn off UAC once you get it. Google how if you want). Do you want a laptop or a desktop? If it is a laptop you want Dell does a good XPS machine with a GeForce 8600M in it, for pretty good money. If you want a desktop well your choices are huge. Just make sure it has a Core2Duo or Quad (any sort should do really), AT LEAST 2GB of RAM, and a non Intel graphics card if you want it to perform well. I made a list of graphics cards for another game that is still valid for any other game. The list is Here and you probably want a card from the mid high tier or above. Sorry for the forum link but its better than posting a massive list of graphics cards. TheGreatZorko (talk) 08:57, 10 September 2008 (UTC)
- Thankyou very much. I now have an external CD drive, but will not reinstall Spore via the CD until I get a new computer. There's a good NEC with all the system reqs. selling for $1400AUD, but I hear NEC is unreliable?
@The Great Zorko: Are you saying I should run the installer from the copied files from the CD? This doesn't contribute to the 3-install limit does it? I haven't seen any save files in the My Spore Creations, but I must not have paid attention. The game is actually running, but freezes completely, requiring a hard reset of the laptop, if I play any game in it for ~10 minutes consequtively (sp?), so I have to keep quitting to the main menu: irritating, but not unplayable. Regarding Vista, my younger brother has it and complains it's very slow unless he defrags once a week. Avnas Ishtaroth drop me a line 01:15, 11 September 2008 (UTC)
- It's not Vista, it's the way that manufacturers of computers preconfigure Vista. I bought Vista Ultimate (More like you're an ultimate idiot for paying this much money for an OS...) Although I am growing on Vista (as I grew on XP) the problems with it are interface related, not performance. Vista actually outperforms XP in video games. Whodathunkit? Many problems with computers stem from the way they are initially (mis)configured and loaded. Which is why I think computer manufacturers should burn in the deepest depths of Puritan Hell. --mboverload@ 01:35, 11 September 2008 (UTC)
- Also, UAC is WAAAYYYYYYYYYY better now. Although I would turn it off when you are initially configuring the computer and installing programs once everything is even close to being set turn it back on. Vista should have been shipped like it is in SP1 (it's better). --mboverload@ 01:37, 11 September 2008 (UTC)
E-mail verification
[edit]I have a huge address book full of old contacts. I want to make sure that the emails are up-to-date. Instead of bothering everyone with a mass e-mail, is there a safe way to verify that their e-mail addresses still exist? Zepheus <ゼィフィアス> (talk) 02:09, 10 September 2008 (UTC)
- No. If you could do that spammers would cream their pants. The only thing you can do is go to the hosting website (ie gmail.com) to make sure it works. I'm positive that a quick mass mail checking in on people and just saying you're making sure you still have their right address won't bother anyone. It's quite nice to have a reason to reconnect with someone you haven't spoken to in awhile. Just make sure you mass mail them in the Bcc field =P --mboverload@ 07:05, 10 September 2008 (UTC)
- And, if you're sending this out once, ask for a read receipt. Sandman30s (talk) 12:43, 10 September 2008 (UTC)
- That's a great way to discover which of your friends belong in a lunatic asylum in the "I want more spam please" wing. Nobody in their right minds leaves read receipts turned on because it enables email address seekers to know that not only does your email work - but you are also daft enough to actually read their postings! NO! *bad* user! SteveBaker (talk) 20:46, 10 September 2008 (UTC)
- This is why I said "once", or in other words, use that in exceptional circumstances. I also HATE getting repeated read receipts from insecure people. Sandman30s (talk) 14:11, 11 September 2008 (UTC)
- That's a great way to discover which of your friends belong in a lunatic asylum in the "I want more spam please" wing. Nobody in their right minds leaves read receipts turned on because it enables email address seekers to know that not only does your email work - but you are also daft enough to actually read their postings! NO! *bad* user! SteveBaker (talk) 20:46, 10 September 2008 (UTC)
- And, if you're sending this out once, ask for a read receipt. Sandman30s (talk) 12:43, 10 September 2008 (UTC)
Function return array in C?
[edit]How do you return an array with a function in C? Through pointers? I'm new to C and my grasp on pointers isn't very strong yet, so I don't quite understand examples on the net. I'm trying to return an array of time values (seconds, minutes, hours, etc.) from a function that reads the time from a real-time clock through I2C on an embedded system (Atmel AVR). --antilivedT | C | G 03:44, 10 September 2008 (UTC)
- It is not possible to return an array directly. You must either use a pointer, or return a struct that contains an array (which will probably be translated by your compiler into an equivalent construct involving a pointer). Maybe you should return a struct tm as found in <time.h> --tcsetattr (talk / contribs) 03:52, 10 September 2008 (UTC)
- This is what time.h is used for - but you can learn by looking at time.h to see how tm is defined. Because of memory management, you'll most likely want to make a pointer to tm in your main program. Pass the pointer as a parameter to your function. Have your function set the values in the pointer and return something like 0 if it works or some other number (ie: 10 = "Couldn't connect to I2C"). Then, your main program will call the function and get the return int. If it is 0, it knows that the pointer to tm has a valid date/time in it. Otherwise, it knows there was an error. This is a very basic C way of doing things that you will see over and over. -- kainaw™ 12:36, 10 September 2008 (UTC)
- You have to know pointers to do this...but this is C and you have to know pointers to do almost anything!
- In most cases, what we do is to have the calling function pass in an array for the called function to fill in - so, for example:
// The FIRST way...
void setDate ( char *dateBuffer ) // This is a pointer to the first character in the array { strcpy ( dateBuffer, "10/9/2008" ) ; // Or whatever... }
int main () { char date [ 200 ] ; setDate ( date ) ; printf ( "The date is %s\n", date ) ; }
- But if you really do want to return a result, you can do it with pointers:
// The Second Way....
char dateBuffer [ 200 ] ;
char *getDate () { strcpy ( dateBuffer, "10/9/2008" ) ; return dateBuffer ; }
int main () { char *date ; date = getDate () ; printf ( "The date is %s\n", date ) ; }
- HOWEVER, this second approach is awfully dangerous and makes experienced programmers twitch slightly in the outer corner of their right eyelid.
- The reason is that it's awfully easy to write this:
// The way you don't do it unless you want Steve to come to your house with an Uzi and ritually murde...
char *getDate () { char dateBuffer [ 200 ] ; strcpy ( dateBuffer, "10/9/2008" ) ; return dateBuffer ; // <===== EEEEKKKKK!!!!! NEVER DO THIS -- EVER!!!!! }
int main () { char *date ; date = getDate () ; printf ( "The date is %s\n", date ) ; }
- The problem being that now "dateBuffer" is a local variable of the 'getDate' function and as soon as the function exits, that data is *GONE*. However you returned a pointer to the data to the 'main' function which then passes it on to printf. But printf then follows the pointer and tries to print out data that's been deleted! This can produce an exciting and diverse range of impossible to find bugs!
- Since this code only differs by the position of one line ("char dateBuffer[200]" was moved inside the function) this error is incredibly easy to make - and horribly difficult to find in a million lines of software. So we try to do this kind of thing the first way rather than the second way - because we don't want the third way!
- Sadly, there is also a problem with the first way - which is that 'setDate' has no way to check that the array is big enough for the data that's going into it.
- So the short answer is "use C++ classes" - but that's an entirely different story.
- SteveBaker (talk) 20:42, 10 September 2008 (UTC)
- Although I do agree with Steve on the last bit of advice, it is a bit controversial. Not everyone loves the complexities of C++. So I'll stick with C, and modify Steve's last example:
// This way, hopefully Steve won't come to your house with an Uzi and ritually murde... // char *getDate () { static char dateBuffer [ 200 ] ; strcpy ( dateBuffer, "10/9/2008" ) ; return dateBuffer ; // Safe (sort of) }
- This is essentially doing the same as Steve's "second way" example, except that the buffer there was in the global namespace, while here it is hidden as a static variable within the function. The problem with both approaches, is that using global (or static) buffers for function return values is a practice that easily leads to errors. An example, assuming the function returns the date and time:
char *t1, *t2; double d; // creating a record, need to get the date the task begins t1 = getDate(); // do the work.. d = do_that_time_consuming_calculation(); t2 = getDate(); // get the time the task finished // ok, done. Fill in the record strcpy(myrecord.start_time, t1); myrecord.result = d; strcpy(myrecord.end_time, t2);
- The error, of course, is that both myrecord.start_time and myrecord.end_time will contain the time the task finished, since t1 and t2 store pointers to the same buffer. To avoid that, you can allocate the memory for the array in your function, using malloc. The problem is, you'll have to deallocate the memory when you're done, something you're likely to forget (especially if there is an error return before the program line where you deallocate the memory), thereby getting a memory leak.
Of course, with C++, you have smart pointers,....Sorry, I said I was going to stick with C, didn't I. --NorwegianBlue talk 22:22, 10 September 2008 (UTC)
- The error, of course, is that both myrecord.start_time and myrecord.end_time will contain the time the task finished, since t1 and t2 store pointers to the same buffer. To avoid that, you can allocate the memory for the array in your function, using malloc. The problem is, you'll have to deallocate the memory when you're done, something you're likely to forget (especially if there is an error return before the program line where you deallocate the memory), thereby getting a memory leak.
- Did either of the C++ pushers bother to read the question? It wasn't about returning variable-length strings. It was about returning a fixed-sized group of integers.
- When faced with a problem, some people say "let's use C++". Now they have 2 problems. --tcsetattr (talk / contribs) 22:37, 10 September 2008 (UTC)
- Humble apologies.
I wont't write it out, butPlease replace char* with int* in my post, char dateBuffer[200] with int dateBuffer[6], and strcpy with whatever mechanism is used to fill the array. My point about returning pointers to global (or static) data remains valid.I would also like to point out that I consider kainaw's suggestion the best C solution to the problem.Sorry, I may have misread kainaw's suggestion. The best suggestion IMO, is
- Humble apologies.
// Steve's FIRST way, possibly also what kainaw intended // NOTE: *** Function name corrected after first being posted. --NorwegianBlue // int getDate ( int *dateBuffer ) // This is a pointer to the first integer in the array { // Fill dateBuffer with date and time return errorcode; // 0 is ok, other return values for the errors that might occur }
int main () { int date [ 6 ] ; int errorcode; errorcode = getDate ( date ) ; // *** Function name corrected after first being posted --NorwegianBlue if (errorcode = 0) { doSomething( date ); } else { // Error handling } }
- since this eliminates the possibility of using a pointer to a buffer that has been overwritten with new data. --NorwegianBlue talk 23:30, 10 September 2008 (UTC)
- Uhh I'm not sure why it has gone the other way but I'm trying to read time instead of set time... I've already done the set time part by just passing over the whole array. Should I really do it with pointers instead of just passing the array? I will look into that tm struct in time.h once I have the time. --antilivedT | C | G 01:04, 11 September 2008 (UTC)
- Sorry, late-night copy-and-paste error on my part, of what (to me) appears to be a typo in Steve's post. I have corrected the code directly in my post above. Hopefully, brain working better in the morning. Re your question "Should I really do it with pointers instead of just passing the array?", the answer is yes. When you use an array as a parameter in C, what actually is being put on the stack is a pointer to the array, and if the array is big, doing it this way is WAY more efficient. Probably, this is what is going on in the function you have already written as well, when you are "just passing the array". Hope this helps. --NorwegianBlue talk 05:08, 11 September 2008 (UTC)
- Uhh I'm not sure why it has gone the other way but I'm trying to read time instead of set time... I've already done the set time part by just passing over the whole array. Should I really do it with pointers instead of just passing the array? I will look into that tm struct in time.h once I have the time. --antilivedT | C | G 01:04, 11 September 2008 (UTC)
Linpus Linux, Aspire One, etc.
[edit]How does one go about modify/editing the desktop/main menu background of the Acer Version of the Linpus Lite installed on the Aspire One? nat.utoronto 03:53, 10 September 2008 (UTC)
WEBSENSE
[edit]How will be able to bypass websense to access usefull sites like wikipedia and read online news in my work place. It's solely for beneficial reasons and i'm having a hard time bypassing it .Please assist5. —Preceding unsigned comment added by 196.1.26.35 (talk) 04:44, 10 September 2008 (UTC)
- Ask your network administrator. If its against their policies to allow certain sites then you should try to convince them. Also, aren't you already able to access Wikipedia? -59.95.99.160 (talk) 06:40, 10 September 2008 (UTC)
- If its a legit site they will let it through. We do it all the time (different but the same idea). Depending on the company bypassing filters is automatically assumed as industrial espionage. (not kidding, some will fire you by leaving your computer unlocked) Plus it's an easy excuse to fire someone they don't like. If it's legit just ask the local IT guy. Be nice about it and give a quick reason why you think it would be helpful to your. We're not robots - if we think we can help you out we will. --mboverload@ 07:02, 10 September 2008 (UTC)
- Sometimes they'll block the ".org" version of the site - but they may forget that www.wikipedia.net and www.wikipedia.com also take you to the same place...it's worth a try. Also, there are a HUGE number of completely legal mirrors and 'forks' of Wikipedia that give you the same content - but without the ability to put your changes back into the site - there is a list of them here: Wikipedia:Mirrors_and_forks - perhaps one of those will get you the content you need. But I agree - you should go to your management and explain that having the whole of human knowledge inside that little box on their desks just might, maybe, be kinda handy for their employees! SteveBaker (talk) 19:43, 10 September 2008 (UTC)
LAN
[edit]I am busy doing a project for school and I have to do various things about a LAN. The most info I already have but there is one part that I am battling with. How does a LAN use computer programs? I dont seem to get any info on that. I dont know if I am just looking in the wrong place.
Thanks for a great site. I have used it a couple of times already for projects and I am sure I will use it even more in future. —Preceding unsigned comment added by 196.207.33.197 (talk) 06:08, 10 September 2008 (UTC)
- LANs don't use computer programs, computer programs use LANs. LAN. Could you be more specific in your question? --mboverload@ 07:03, 10 September 2008 (UTC)
- Hi, you can start with Communications protocol (especially Internet Protocol Suite). If you're using windows, check out Network Connections under Control Panel to see the protocols your LAN use. At a very basic level, programs designed to work on a LAN are network aware and the developers would use one of the protocols above. A typical problem in designing a simple network application is how file-sharing/locking would work. Sandman30s (talk) 12:40, 10 September 2008 (UTC)
- Essentially, the LAN (Local Area Network) is the teeny-tiny part of the Internet that lives within a single building - or perhaps within a company. It's composed of the wires, the switches and routers and such like - and it's job is to pass messages back and forth between computers. So when you are using a computer at work (say) and you want to read a page on Wikipedia, the sequence of events (softwarily) is (very roughly) as follows:
- You bring up Internet Explorer or Firefox or something. That's a computer program that runs on your computer.
- When you enter the Wikipedia web address into the address bar, FireFox asks the operating system (Windows, Linux or MacOS perhaps) to please make a connection to this "wikipedia" place. The operating system sends a message to the "device driver" that drives the "Ethernet interface" hardware on your computer to send a message to another computer that says "Could you please tell me what number is given to the computer called 'Wikipedia.org'."?
- The Ethernet interface hardware is connected either to a cable or to a radio link that sends out the message over the LAN.
- At this point, it's just a message - a string of bytes with a wrapper called a "packet" which (like a postal packet) contains the address that the packet is being sent to and the address it came from.
- The LAN electronics route that packet through the maze of cables, routers and other computers out to the cable that runs off to the "big wide world" Internet proper. The "switches" and "routers" (kinda the same thing) look at the address on the message and make sure it gets sent down the right wire.
- The Internet is sometimes called a "WAN" (Wide Area Network) because it covers longer distances - but the technology is no different in principle to the LAN...so the message continues off across the net until it gets to the place where it's being sent.
- In this case - because we're asking the question "What is the number of the computer called 'Wikipedia.org'" - the message was sent to a computer called a "DNS" (Dynamic Name Server) - which has a long list of computer names ("Google.com", "Wikipedia.org", "ebay.com"...etc)...and the numbers that go with them (eg Wikipedia is 208.80.152.2)...well, that computer looks up wikipedia, finds the number and then looks where the packet came from and sends the answer back in another packet.
- Now the process reverses - the packet goes back through switches and routers and cables in the Internet - and eventually arrives at the LAN - still addressed to your computer.
- The message arrives in the Ethernet interface - and the operating system picks it up and remembers that 208.80.152.2 is Wikipedia.
- Now Firefox sends a message to wikipedia that says "Please send me the page called 'wiki/Main_Page'" - using the 208.80.152.2 address.
- Same thing...the message goes across the LAN, out into the internet, into the LAN at Wikipedia headquarters - and into the computer there.
- The Wikipedia computer finds that page (it's a file on disk) - loads contents of the file into a packet (perhaps several packets if it's a long page) and ships it back to the computer in the "From" part of the address...which is you.
- ANOTHER trip across the wiki-LAN, into the Internet, into your LAN, into your Ethernet interface, into your operating system and then into FireFox...which displays the page on the screen.
- In truth, this is an AMAZINGLY simplified version of what's really going on...in reality there are messages sent back from every packet as it arrives at it's destination that say "Thanks! I got your message OK!"...if the sending computer doesn't get that acknowledgement back, it sends the packet again...and again...and again...until it either gets an acknowledgement back or some large amount of time passes and it gives up.
- And the "DNS" computer may not have the address you want in it's list - so it goes to another nearby DNS and says "Do you happen to know this address?"...and the request that says "Where the heck is wikipedia?" ripples out across many, many DNS's until one of them really does know the answer and sends it back so that everyone will know next time around.
- And Wikipedia isn't really just one computer - there are many and whichever one has time to spare will send you back your page.
- And your LAN probably has a "Firewall" computer between it and the big-wide-world Internet who's job it is to make sure that only "approved" messages are passed back and forth - to keep out hackers, industrial spies and such like.
- In some cases, for very commonly needed pages, there may be a computer on your LAN that stores copies of the most frequently needed pages - and intercepts requests for them so that you get the saved copy without having to travel halfway around the world to get it.
- But that's enough for a simplified view.
- SteveBaker (talk) 20:21, 10 September 2008 (UTC)
Outlook Express
[edit]Bear with me, I'm not good with computers, so answers in words of one syllable please!
I've always used Outlook Express for sending and receiving emails. However, I've recently bought a new computer running Vista, and Outlook Express does not seem to be part of the package. I bought the machine from Dell and it came with all its software pre-loaded.
Is Outlook Express being phased out? Is it possible for me to access it somehow on the new computer, or is it just not included on new machines?
Any help gratefully appreciated. Maid Marion (talk) 14:32, 10 September 2008 (UTC)
- Yes, Outlook Express has been replaced by Windows Mail. --LarryMac | Talk 14:35, 10 September 2008 (UTC)
- You could also consider downloading "Thunderbird" - which is the email client provided by the same guys who wrote FireFox. It's free and has pretty good features and an excellent spam filter that learns from you what you consider spam and what you want to read. The website is here: http://www.mozilla.com/en-US/thunderbird/ SteveBaker (talk) 19:35, 10 September 2008 (UTC)
- I can't seem to log in today (told you I was no good with computers), but this is Maid Marion, just to say thanks to you guys, very helpful. —Preceding unsigned comment added by 86.139.174.145 (talk) 09:07, 11 September 2008 (UTC)
Loading images
[edit]Does firefox provide an option to not load images until requested by the user, like old versions of netscape used to? I couldn't find it in preferences but thought it might be a hidden option like about:config --Random832 (contribs) 15:34, 10 September 2008 (UTC)
- tools/options/content/load images automatically (in 3.0.1) Algebraist 15:43, 10 September 2008 (UTC)
- The "Image like Opera" extension does this (although it also has much more powerful features). It will show placeholder frames instead of images, you can right-click the placeholder and click "Load image" to load the image in place, unlike the "View image" FF option which loads the image alone in the same window. Basically it behaves like Internet Explorer's "Show image download placeholders" option. It works like a charm. Works well for blocking ads and Flash too as it handles regular expressions and can supplement Ad-block Plus. Zunaid 15:56, 10 September 2008 (UTC)
FF3 actually has a right-click "show image" item that I noticed when an image failed to load. It doesn't seem to work when image loading is turned off though. --Random832 (contribs) 17:39, 10 September 2008 (UTC)
Virtual CD burner - free
[edit]I'm looking for a simple, free alternative almost identical to programs such as TuneClone - or one with an unrestricted ~10-day trial :-) Anyone know of one? Thanks! ╟─Treasury§Tag►contribs─╢ 16:56, 10 September 2008 (UTC)
- To clarify your question, I guess you're looking for a Virtual drive#Virtual Burner, right? -- Finlay McWalter | Talk 17:16, 10 September 2008 (UTC)
- Pretty much, yeah, but free and simple if poss! ╟─Treasury§Tag►contribs─╢ 18:25, 10 September 2008 (UTC)
Ladder logic diagram software
[edit]Does anyone here know where I can obtain free (gratis) software to draw ladder logic diagrams. I do not need to perform any type of simulation or PLC programming. I simply want to be able to draw the diagrams. I have searched Google to no avail. 137.148.141.183 (talk) 23:31, 10 September 2008 (UTC)