While your arugments are true, nothing like this has ever been built before. I think the next biggest solar tower was a little 20 kW thing. This is a prototype. However much it costs, it's safe to assume they will get cheaper in the future.
I often use "ret" to instead of "tmp" as a place to explicitly put return values so I can get a closer look at them.
ret = open(path, O_RDONLY, MODE_DONTCARE); if (ret < 0) {
return FILE_ERROR; } fd = ret;
Because robust verification of return values can take more than one "if", and I don't want to stomp old values until I'm sure the new one will work. Even if it's not needed in this case, it's a good habbit to get into.
Also, there are often libraries with all the fancy optimizations all wrapped up in a neat little package. Better to use those than litter your code with anything hard to read.
When passing pointers, the "const" thing is a big deal.
It has to make sure it uses the copy in memory everywhere if anyone else gets a copy of the pointer. That function might keep a copy, pass it around there's no way to know.
If you use "const" in the function decleration, it can assume no one elsewhere will be changing it.
Of course, in my always humble opinion using a compiled language at all is a premature optimization most of the time.:)
When knowing a number is sufficient to use it (credit cards, SSN), security is impossible.
It is a fact of life that your important numbers hang around indeffinitely in various databases. Unless more than a number is required to use them, it will become impossible to maintain your identity.
While I'm somewhat surprised the average user pays attention to such things, I'm not surprised trust is failing in light of recent large scale compromises.
Until the industry as a whole adopts a strategy of preventing compromises, this is not going to improve. Most companies would rather pay a PR guy to fix their image after the fact than a security consultant to keep it from happening in the first place. That's certainly not how I want my information taken care of.
"Besides for PC users, if they only have USB1, then they almost certainly don't have firewire. (There will be a few exceptions like Sony with i.Link, but few other OEM manufactures had any significant number of IEEE1394 ports on thier models)."
I agree. The decision to leave out the Firewire cable affects Mac users much more than PC users, Mac users would be much better off buying a Firewire cable.
Sure, but not necessarily that that level of incom is sufficient to justify the purchase of an iPod. You'd have trouble convincing me of that because as a semi-penniless student I have a computer sufficient to support an iPod but I didn't get one until they released the shuffle.
If I really wanted I could have scraped together the money, but I would have had to do without something else. An MP3 CD player is more than enough for my needs, and costs a lot less, so I got one instead of an iPod.
But when that started to die a few years down the road the shuffle was released, and it cost the same as the replacement I was looking at instead of hundreds of dollars more, so suddenly the iPod looked like a pretty good deal and I got one.
Sometimes it's a lot worse, like the text will appear more than a screen to the right, or at the extreme left of the window, undernead the links on the left.
I've seen it on Windows, Linux, and Mac, on Mozilla and Firefox. Using a proxy server seems to increase the probability of it happening. Most of the time things load fine.
"$ dd if=/dev/zero of=/tmp/zero bs=100k count=10240 # 100 kb chunks totalling 1 gb, big enough to blow out the cache so we get a reasonable test. 10240+0 records in 10240+0 records out 1048576000 bytes transferred in 18.004315 seconds (58240261 bytes/sec)"
That's a 7200 rpm drive.
If I'm getting 56 mb/s after filesystem overhead, I think it's safe to say I'm getting at least 60-70 mb/s raw, and it's definitely more than Firewire 400 can do.
"What do you think the Shuffle is? $149 for a 1GB flash player is pretty cheap, and the Shuffle has practically no features to it."
The shuffle isn't close to the cheapest flash player you can get. Check your favorite consumber electronics site for 256 mb or less flash players. Sure they suck, but that's exactly what "bottom of the barrel" means.
The shuffle is the cheapest flash player you can get that's not a piece of crap, and is therefore by definition not the bottom of the barrel.
"I have also read that modern drives are faster than Firewire 400 in theory, while in practice most consumer drives never get close to that maximum 80MB/s you quote."
They don't get up to that speed, but 60-70 mb/s is perfectly reasonable to expect. On my Linux desktop machine: $ dd if=/dev/zero of=/tmp/zero bs=100k count=10240 # 100 kb chunks totalling 1 gb, big enough to blow out the cache so we get a reasonable test. 10240+0 records in 10240+0 records out 1048576000 bytes transferred in 18.004315 seconds (58240261 bytes/sec)
That's 55.5 mbyte/s. I don't know what that is counting filesystem overhead, but it's probably in the 60-70 mb/s range. It's safe to say that Firewire 400 drives wouldn't be going anywhere near that fast.
"From what I understand Firewire also splits the available bandwidth much more efficiently between multiple devices than USB does, so that helps."
That really depends. USB is optimized for completely different things. Firewire is better for video, drives, high quality scanners, that sort of thing. Jobs that produce a high sustained transfer rate. USB is better for stuff like keyboards, mice, small external devices like modems, USB pocket disks, that sort of thing. It's not as efficient with CPU usage but it's WAY cheaper to make devices that support it. Controller chips for USB devices are very easy to come by these days. Ideally we'd have one interface that could do both, but we're stuck with what we have.
"Oh yes, I forgot to mention Firewire networking! Mac OS X has the capability built-in to use Firewire ports to network between any two Macs at Firewire speeds (4 to 8 times 100baseT Ethernet?). Great for clusters, file servers and general geekiness."
Great for geekiness but in practice performance isn't as good as gigabit ethernet, indeed it's not that much better than 100 megabit networks. This reveals a weakness in Firewire. Networks are designed to move small packets around many at a time, Firewire is designed to move big buffers around one or at most several at a time. USB isn't particularly good at networks either, but ethernet is great at it.
The only reason I can see to use Firewire for networking is if you're stuck with a slower ethernet interface. Interrupts per second that a CPU can handle hasn't really changed very much in the last 10 years. A good gigabit card will buffer dozens of packets before burdening the CPU with an interrupt, while IIRC a Firewire card must trigger an interrupt for each one. You can tune the network by increasing the MTU (makes each packet bigger), but you're still going to be way behind on throughput compared to gigabit.
"So you have to define your market. Who is the iPod for? It's for people who listen to a lot of music, and it's for people who already own computers. That puts it pretty squarely in the 25-44, $40,000-a-year-and-up demo."
As you say, hard drive based iPods have done very well with people that can afford them. The same is true of most luxury items. Those people are in a substantial minority. Most of the other options suck, but that's not going to convince someone unwilling to spend that much money on a music player. Their (possibly MP3 capable) CD player, or tape player works fine.
That's why I think the shuffles will not so much replace other players in a fairly small market as they will expand the market to the point where other players are marginalized. They're appealing to people that have used other technologies until now. They're also the first flash player that's worth the trouble, my opinion.
Unfortunately Apple decided to use USB 1.1 on their "budget" lines until very recently, so the majority of Mac users have 1.1 machines.
I wouldn't want to transfer tens of gigs of music to an iPod with USB 1.1. It can do about 1 mbyte/s, so that's about 3.6 gigs per hour... 5.7 hours for 20 gigs, 8.5 for 30, 16.1 for 60.
'Course, my collection is 11 gigs, the subset I listen to is about 6, and when I transfer stuff to my shuffle the biggest slowdown is from transcoding to AAC (lower quality, but also lower battery usage and smaller files). It doesn't even get close to USB 1.1 speeds.
Firewire 400 is 400 megabits per second, which works out to 50 megabytes per second. That's a lot less than what current desktop drives can do (80-85 mb/s). Firewire 800 is fast enough to accomodate any desktop drives that I know of right now.
Firewire 400 and USB 2.0 are fairly similar in speed, but Firewire was designed for bulk transfers and is therefore better with its CPU usage when dealing with hard drives. You'd want it for an external hard drive (particularly a fast one), but I don't think it matters that much for iPods. They use comparatively small, slow drives.
You conclusion that Apple won't be moving away from Firewire is IMO correct. It costs little for them to continue to support it, and the benefits are significant.
"They are already a huge player. For all intents and purposes, they are the only player. Not "at the right price," however you define it, but at the prices they've been at for the past four years."
That isn't the case. Hard drive based iPod are too expensive to get to most people. While Apple dominates the hard drive player market to the point of monopolizing it, that market is a fairly small minority particularly when you consider other technologies.
Those that don't get cheaper flash or CD MP3 players are happy with old fashioned CD players, tape players, radios, or nothing. Those people don't even consider hard drive based iPods.
Of course, with what the shuffles cost I suspect Apple will be able to turn that around. Most players cheaper than a shuffle are pretty crappy, and Apple's never tried to compete with the bottom of the barrel.
There was an Apple speaker at the CUUG meeting on the 22nd and I couldn't get him to reveal any numbers on the shuffle, but I suspect they're going to be huge.
The difference isn't that big for the slower (by hard drive standards) drives in iPods. Firewire would get higher speeds with lower CPU usage... but the difference is questionable to anyone with USB 2.0.
Of course, the people that benefit would do well to buy the cable. For example, someone that uses their iPod as a removable hard drive, or someone with USB 1.1.
I imagine it's annoying for Mac users that have machines with USB 1.1, which constitutes the majority of Mac users (including myself)... but I'm not really that annoyed over it.
I have a shuffle with USB 1.1, but the thing that eats up most of the time is transcoding to AAC (128 kbps AAC has worse quality than a high bitrate MP3, but it takes less space/uses less battery and I don't copy the AAC files so there's no generation loss past that one step).
"Whats the point in buying a 64 bit system if you run it in 32 bit mode."
'Cause it's still a really nice machine?
"The Debian approach (lets argue and not get this right for too long and not really get our act together) has been a disaster."
The advantage, though, is that a stable release is very stable.
"Gentoo is apparently pretty good too, intend to try it soon."
They change too much stuff without enough testing for a production system, IMO. I've always had regular breakages when I've used Gentoo.
Some people want features and new versions. Gentoo is good for this, but it has a lot of troubles from staying that up to date, because the maintainers can't do proper regression testing every time something updates. Reliability suffers a lot, and drives people like me straight into Debian.
My motivation for using Debian comes from using Gentoo. I found the unreliability so profoundly annoying that I no longer care about using the most up to date version.
"you would install FreeBSD, which has had serious issues throughout its latest release cycle. I think you spend more time reading about these products than using them."
I'd probably run the 32-bit port of FreeBSD 4.x if I was going to run FreeBSD. Or possibly OpenBSD. Debian wouldn't be my first choice, but if I were a Linux guy it would be so I left it there as a nod to Linux people that think more or less like me.
"I find Debian annoying compared to BSD or Solaris but that may be personal preference."
Some of the automation in Debian makes me nervous, but I agree that it's a personal preference thing. I probably don't use it enough to be 100% comfortable.
Now all we need is for them to stop treating undergrads like scum.
While your arugments are true, nothing like this has ever been built before. I think the next biggest solar tower was a little 20 kW thing. This is a prototype. However much it costs, it's safe to assume they will get cheaper in the future.
huh, that's odd.
When people make notice of it when I do it, it's always something along the lines of "Huh, I like that.".
Also, there are often libraries with all the fancy optimizations all wrapped up in a neat little package. Better to use those than litter your code with anything hard to read.
When passing pointers, the "const" thing is a big deal.
:)
It has to make sure it uses the copy in memory everywhere if anyone else gets a copy of the pointer. That function might keep a copy, pass it around there's no way to know.
If you use "const" in the function decleration, it can assume no one elsewhere will be changing it.
Of course, in my always humble opinion using a compiled language at all is a premature optimization most of the time.
When knowing a number is sufficient to use it (credit cards, SSN), security is impossible.
It is a fact of life that your important numbers hang around indeffinitely in various databases. Unless more than a number is required to use them, it will become impossible to maintain your identity.
While I'm somewhat surprised the average user pays attention to such things, I'm not surprised trust is failing in light of recent large scale compromises.
Until the industry as a whole adopts a strategy of preventing compromises, this is not going to improve. Most companies would rather pay a PR guy to fix their image after the fact than a security consultant to keep it from happening in the first place. That's certainly not how I want my information taken care of.
He was reffuting my claim that the shuffle wasn't the "bottom of the barrel", as evidenced by the fact that he quoted me saying that.
"Besides for PC users, if they only have USB1, then they almost certainly don't have firewire. (There will be a few exceptions like Sony with i.Link, but few other OEM manufactures had any significant number of IEEE1394 ports on thier models)."
I agree. The decision to leave out the Firewire cable affects Mac users much more than PC users, Mac users would be much better off buying a Firewire cable.
Sure, but not necessarily that that level of incom is sufficient to justify the purchase of an iPod. You'd have trouble convincing me of that because as a semi-penniless student I have a computer sufficient to support an iPod but I didn't get one until they released the shuffle.
If I really wanted I could have scraped together the money, but I would have had to do without something else. An MP3 CD player is more than enough for my needs, and costs a lot less, so I got one instead of an iPod.
But when that started to die a few years down the road the shuffle was released, and it cost the same as the replacement I was looking at instead of hundreds of dollars more, so suddenly the iPod looked like a pretty good deal and I got one.
screenshot
Sometimes it's a lot worse, like the text will appear more than a screen to the right, or at the extreme left of the window, undernead the links on the left.
I've seen it on Windows, Linux, and Mac, on Mozilla and Firefox. Using a proxy server seems to increase the probability of it happening. Most of the time things load fine.
"$ dd if=/dev/zero of=/tmp/zero bs=100k count=10240 # 100 kb chunks totalling 1 gb, big enough to blow out the cache so we get a reasonable test.
10240+0 records in
10240+0 records out
1048576000 bytes transferred in 18.004315 seconds (58240261 bytes/sec)"
That's a 7200 rpm drive.
If I'm getting 56 mb/s after filesystem overhead, I think it's safe to say I'm getting at least 60-70 mb/s raw, and it's definitely more than Firewire 400 can do.
"What do you think the Shuffle is? $149 for a 1GB flash player is pretty cheap, and the Shuffle has practically no features to it."
The shuffle isn't close to the cheapest flash player you can get. Check your favorite consumber electronics site for 256 mb or less flash players. Sure they suck, but that's exactly what "bottom of the barrel" means.
The shuffle is the cheapest flash player you can get that's not a piece of crap, and is therefore by definition not the bottom of the barrel.
"I have also read that modern drives are faster than Firewire 400 in theory, while in practice most consumer drives never get close to that maximum 80MB/s you quote."
They don't get up to that speed, but 60-70 mb/s is perfectly reasonable to expect. On my Linux desktop machine:
$ dd if=/dev/zero of=/tmp/zero bs=100k count=10240 # 100 kb chunks totalling 1 gb, big enough to blow out the cache so we get a reasonable test.
10240+0 records in
10240+0 records out
1048576000 bytes transferred in 18.004315 seconds (58240261 bytes/sec)
That's 55.5 mbyte/s. I don't know what that is counting filesystem overhead, but it's probably in the 60-70 mb/s range. It's safe to say that Firewire 400 drives wouldn't be going anywhere near that fast.
"From what I understand Firewire also splits the available bandwidth much more efficiently between multiple devices than USB does, so that helps."
That really depends. USB is optimized for completely different things. Firewire is better for video, drives, high quality scanners, that sort of thing. Jobs that produce a high sustained transfer rate. USB is better for stuff like keyboards, mice, small external devices like modems, USB pocket disks, that sort of thing. It's not as efficient with CPU usage but it's WAY cheaper to make devices that support it. Controller chips for USB devices are very easy to come by these days. Ideally we'd have one interface that could do both, but we're stuck with what we have.
"Oh yes, I forgot to mention Firewire networking! Mac OS X has the capability built-in to use Firewire ports to network between any two Macs at Firewire speeds (4 to 8 times 100baseT Ethernet?). Great for clusters, file servers and general geekiness."
Great for geekiness but in practice performance isn't as good as gigabit ethernet, indeed it's not that much better than 100 megabit networks. This reveals a weakness in Firewire. Networks are designed to move small packets around many at a time, Firewire is designed to move big buffers around one or at most several at a time. USB isn't particularly good at networks either, but ethernet is great at it.
The only reason I can see to use Firewire for networking is if you're stuck with a slower ethernet interface. Interrupts per second that a CPU can handle hasn't really changed very much in the last 10 years. A good gigabit card will buffer dozens of packets before burdening the CPU with an interrupt, while IIRC a Firewire card must trigger an interrupt for each one. You can tune the network by increasing the MTU (makes each packet bigger), but you're still going to be way behind on throughput compared to gigabit.
"So you have to define your market. Who is the iPod for? It's for people who listen to a lot of music, and it's for people who already own computers. That puts it pretty squarely in the 25-44, $40,000-a-year-and-up demo."
As you say, hard drive based iPods have done very well with people that can afford them. The same is true of most luxury items. Those people are in a substantial minority. Most of the other options suck, but that's not going to convince someone unwilling to spend that much money on a music player. Their (possibly MP3 capable) CD player, or tape player works fine.
That's why I think the shuffles will not so much replace other players in a fairly small market as they will expand the market to the point where other players are marginalized. They're appealing to people that have used other technologies until now. They're also the first flash player that's worth the trouble, my opinion.
"and radios, CD players and walkmans aren't really in the same market."
MP3 capable CD players and minidiscs are in exactly the same market, and those are much cheaper than the hard drive based iPods.
It's true that sustained (not cached) performance is significantly lower, but 70 mb/s is still well over the speeds that Firewire 400 is capable of.
Unfortunately Apple decided to use USB 1.1 on their "budget" lines until very recently, so the majority of Mac users have 1.1 machines.
I wouldn't want to transfer tens of gigs of music to an iPod with USB 1.1. It can do about 1 mbyte/s, so that's about 3.6 gigs per hour... 5.7 hours for 20 gigs, 8.5 for 30, 16.1 for 60.
'Course, my collection is 11 gigs, the subset I listen to is about 6, and when I transfer stuff to my shuffle the biggest slowdown is from transcoding to AAC (lower quality, but also lower battery usage and smaller files). It doesn't even get close to USB 1.1 speeds.
Firewire 400 is 400 megabits per second, which works out to 50 megabytes per second. That's a lot less than what current desktop drives can do (80-85 mb/s). Firewire 800 is fast enough to accomodate any desktop drives that I know of right now.
Firewire 400 and USB 2.0 are fairly similar in speed, but Firewire was designed for bulk transfers and is therefore better with its CPU usage when dealing with hard drives. You'd want it for an external hard drive (particularly a fast one), but I don't think it matters that much for iPods. They use comparatively small, slow drives.
You conclusion that Apple won't be moving away from Firewire is IMO correct. It costs little for them to continue to support it, and the benefits are significant.
"They are already a huge player. For all intents and purposes, they are the only player. Not "at the right price," however you define it, but at the prices they've been at for the past four years."
That isn't the case. Hard drive based iPod are too expensive to get to most people. While Apple dominates the hard drive player market to the point of monopolizing it, that market is a fairly small minority particularly when you consider other technologies.
Those that don't get cheaper flash or CD MP3 players are happy with old fashioned CD players, tape players, radios, or nothing. Those people don't even consider hard drive based iPods.
Of course, with what the shuffles cost I suspect Apple will be able to turn that around. Most players cheaper than a shuffle are pretty crappy, and Apple's never tried to compete with the bottom of the barrel.
There was an Apple speaker at the CUUG meeting on the 22nd and I couldn't get him to reveal any numbers on the shuffle, but I suspect they're going to be huge.
The difference isn't that big for the slower (by hard drive standards) drives in iPods. Firewire would get higher speeds with lower CPU usage... but the difference is questionable to anyone with USB 2.0.
Of course, the people that benefit would do well to buy the cable. For example, someone that uses their iPod as a removable hard drive, or someone with USB 1.1.
I imagine it's annoying for Mac users that have machines with USB 1.1, which constitutes the majority of Mac users (including myself)... but I'm not really that annoyed over it.
I have a shuffle with USB 1.1, but the thing that eats up most of the time is transcoding to AAC (128 kbps AAC has worse quality than a high bitrate MP3, but it takes less space/uses less battery and I don't copy the AAC files so there's no generation loss past that one step).
"Whats the point in buying a 64 bit system if you run it in 32 bit mode."
'Cause it's still a really nice machine?
"The Debian approach (lets argue and not get this right for too long and not really get our act together) has been a disaster."
The advantage, though, is that a stable release is very stable.
"Gentoo is apparently pretty good too, intend to try it soon."
They change too much stuff without enough testing for a production system, IMO. I've always had regular breakages when I've used Gentoo.
Some people want features and new versions. Gentoo is good for this, but it has a lot of troubles from staying that up to date, because the maintainers can't do proper regression testing every time something updates. Reliability suffers a lot, and drives people like me straight into Debian.
My motivation for using Debian comes from using Gentoo. I found the unreliability so profoundly annoying that I no longer care about using the most up to date version.
"you would install FreeBSD, which has had serious issues throughout its latest release cycle. I think you spend more time reading about these products than using them."
I'd probably run the 32-bit port of FreeBSD 4.x if I was going to run FreeBSD. Or possibly OpenBSD. Debian wouldn't be my first choice, but if I were a Linux guy it would be so I left it there as a nod to Linux people that think more or less like me.
"I find Debian annoying compared to BSD or Solaris but that may be personal preference."
Some of the automation in Debian makes me nervous, but I agree that it's a personal preference thing. I probably don't use it enough to be 100% comfortable.