Become a fan of Slashdot on Facebook


Forgot your password?

Slashdot videos: Now with more Slashdot!

  • View

  • Discuss

  • Share

We've improved Slashdot's video section; now you can view our video interviews, product close-ups and site visits with all the usual Slashdot options to comment, share, etc. No more walled garden! It's a work in progress -- we hope you'll check it out (Learn more about the recent updates).


Comment: Re: Deal of the century? (Score 4, Interesting) 246

by pjrc (#49110541) Attached to: In Florida, Secrecy Around Stingray Leads To Plea Bargain For a Robber

This all hinges on what "that money" is.

Sure, they repaid with interest "that money" which was their bailout, fronted by taxpayers when nobody else could loan cash.

But if "that money" refers to all the losses they caused to investors, losses to businesses incurring cash flow problems they wouldn't have had, losses to individuals whose homes dropped in value and were foreclosed, and the huge amount of financial loss and pain felt by pretty everyone else who works for a wage, especially people paid off work, I'm pretty sure those bankers never repaid any of "that money".

Comment: An alternative (Score 5, Insightful) 572

by pjrc (#48220685) Attached to: FTDI Removes Driver From Windows Update That Bricked Cloned Chips

Today Atmel, Microchip and others make inexpensive microcontrollers with native USB peripherals. The Atmel "8u2" chip, for example, is less expensive than even most of the FTDI clones, and certainly a LOT less than a genuine FTDI chip.

For years, I've published a very simple and easy-to-use USB code for those chips.

I also publish a signed INF installer that works with ALL USB Serial based on this standard protocol (called Communications Device Class, Abstract Control Model, or CDC-ACM). All 3 operating systems have the necessary driver built in. Mac OS-X and Linux load it automatically. Windows needs the user to add a INF.

Sadly, the CDC-ACM driver in Windows (called USBSER.SYS) is buggy. About a year ago, I sent Microsoft this reproducible bug report.

In a follow up email a few months ago, they were supposedly testing a fix. I'm hopeful that Windows 10 may be the first version of Windows to ever ship with a good quality USB Serial driver (as Linux has done for many years, and Apple as done since releasing Lion a few years ago).

Comment: Re:DDR2/3/4 (Score 3, Interesting) 181

by pjrc (#47786861) Attached to: Intel's Haswell-E Desktop CPU Debuts With Eight Cores, DDR4 Memory

Just to put "some time now" the time frame into perspective, the last mainstream PC memory form-factor to use asynchronous DRAM was 72 pin SIMMs.

When PCs went from 72 pin SIMMs to the first 168 pin DIMMs, in the mid-1990s, the interface changed to (non-DDR) synchronous clocking.

Comment: UBB makes sense to me (Score 1) 475

by petecarlson (#47013633) Attached to: Comcast Predicts Usage Cap Within 5 Years

I have to admit that I see his point. Residential bandwidth pricing is based on the concept of oversubscription. I run a small local ISP and have seen sustainable oversubscription numbers move from around 75:1 ten years ago to somewhere around 12:1 today and am using 8:1 to plan deployments for the next 2-3 years. Equipment and transit costs have come way down, which have allowed us to keep pricing relatively stable while increasing package speeds, but as we approach 1:1 usage, there is no way to make the model work without passing on full bandwidth costs, core costs, and last mile costs to the end user. Around 3% of our subs end up costing us more in bandwidth usage then they pay us for service which is supportable for now, but as that percentage grows with increased full time streaming, we will either need to raise prices across the board, or start charging based on actual usage. What would be ideal, IMHO, is 95th percentile billing, i.e 10mbps on a 100mbps circuit with 95th percentile billing above 10mbps, but the vast majority of users just wouldn't get it.

Comment: 3D Printing - Anachy ? (Score 4, Insightful) 207

by pjrc (#46800147) Attached to: Cody Wilson Interview at Reason: Happiness Is a 3D Printed Gun

I find it amusing that Anarchy will supposedly spring forth from a technology that depends on highly refined, multi-disciplinary engineering and built from precision materials that are only manufactured and sold at affordable pricing in the context of a highly ordered society.

Comment: Scope usage (Score 3, Insightful) 215

by pjrc (#45477565) Attached to: Ask Slashdot: What's On Your Hardware Lab Bench?

I'm the author of Teensyduino, software for an Arduino compatible board.

I sometimes use my Agilent scope when developing or porting Arduino libraries. Sometimes I just want to check the relative timing of stuff, so I'll set a pin high or low at some point in the code, then capture with the scope to see if the code is taking a long time. Often it's surprising how fast, or how slow certain code can be, and pretty often it's relatively easy to discover and fix performance problems. You can do quite a lot by normal software debugging processes, but pretty much all those approaches involve running the code much slower. When you're debugging real-time code, like libraries that synthesize waveforms by bit-bashing or tricks with timers or DMA channels, there's really no substitute for a good scope.

But admittedly, this is a pretty narrow fringe. Most people probably don't do this sort of low-level coding.

Comment: Re:Too bad it's a C++ library... (Score 1) 147

by pjrc (#45397127) Attached to: WxWidgets 3.0: First Major Release in Several Years

Really, you've written GUI programs using GTK's C-only API and liked it?

Did you really enjoy all that type casting of pointers? That's a lot of unnecessary trouble, when clearly some dialog box must be able to use the more generic window style setting functions. If only the compiler somehow could know your reference to the dialog box is compatible with all that other stuff the dialog box is built upon.... if only....

Comment: Re:But what does it really mean in practice? (Score 4, Interesting) 147

by pjrc (#45397047) Attached to: WxWidgets 3.0: First Major Release in Several Years

I've build programs with wxWidgets 2.8. It does automatically handle those platform specific style issues!

I used wxMenuBar, populated with a heirarchy of wxMenu and wxMenuItem objects. I just pass a point to the main wxMenuBar object to SetMenuBar, which is from the top-level frame of the GUI.

On Mac OS-X, it automatically appear at the top of the screen. One Linux and Windows, it automatically appears on the top of my program's window.

Likewise for toolbars, I simply used with wxWidgets objects as documented, without any specific style stuff. They automatically adapt to fit the style of each system.

That's the magic of wxWidgets. That work you mentioned, adapting things to fit the stylistic expectation of each system, is exactly what wxWidgets does so very well. It's vastly superior to other toolkits which attempt draw their own widgets, because the wxWidgets developers have gone to tremendous effort to actually use the native widgets from each platform. You just use the rather generic API for wxWidgets and you end up with really good native GUIs on all 3 platforms. Best yet, when the user customizes fonts, colors and whatever else, your program adapts like other truly native applications. Other cross platform toolkits fall down in that respect to the customized style, because they aren't really using the platform's native GUI.

Comment: Re:But what does it really mean in practice? (Score 5, Informative) 147

by pjrc (#45396687) Attached to: WxWidgets 3.0: First Major Release in Several Years

I use wxWidgets. Most of my experience is with version 2.8.

If you care deeply about making a native applcation that truly has a native GUI on Windows, Mac and Linux, wxWidgets is great. Nothing else even comes close. Java, QT, XUL, FLTK, TCL/KT and others all produce programs that aren't quite right on some plaforms.

If you don't care about cross platform native GUI applications, or you target browsers with javascript+node+[insert newest buzz], then wxWidgets is not for you. If you really only want to produce a program for Windows but maybe someday have the option to easily port to Mac and Linux, while wxWidgets can give you that, if you don't truly care are doing all 3 from the beginning, I believe you'll find wxWidgets it simply too much trouble.

The truth is wxWidgets is pretty much its own system, an SDK in itself. It has a tremendous amount of somewhat complex design, like sizers, which means you have to go to some extra effort. Of course, for making things work well on all platforms... not simply just work, and not work well on Windows but end up sub-standard on Mac or Linux, but work truly well on all 3, the extra effort to use wxWidgets is definitely worthwhile.

But the truth is you do have to put in extra effort. wxWidgets has great documentation to help, but the other truth is everything is heavily steeped in C++ class heirarchy. If you're good with C++, it'll feel pretty natural. If not, well, you'll get much better with C++ in the process, if you persevere. In the end, if your goal was a native application that truly works natively on all 3 platforms, the sort of thing users take for granted and never notice, you'll be rewarded.

But if you don't really, truly, earnestly care about targeting all 3, if only Windows has to be high quality and the others are afterthoughts, or if you just want to get things done as quickly as possible with minimal learning, you'll probably find wxWidgets to be far too much trouble.

Comment: Re:Is it still relevant? (Score 4, Informative) 147

by pjrc (#45396369) Attached to: WxWidgets 3.0: First Major Release in Several Years

I use wxWidgets. I've mostly used verson 2.8 with ansi strings.

As far as I know, wxWidgets is the only cross platform toolkit that compiles to program that use the native GUI widgets on Windows, Mac and Linux.

You can usually spot Java and QT programs. They work, but things look a little out of place. Firefox does a better job, but things start going wrong if the user customizes or "themes" their desktop. Emulating the look of native GUI controls just isn't ever as good as actually using the native ones.

wxWidgets isn't perfect. I've hit a good number of bugs. It has a pretty steep learning curve. It also doesn't seem like "new" technology. But it works. If you want to write a native application that truly looks and feels and actually is native on each platform, short of writing the code 3 times, wxWidgets is pretty much the only toolkit.

Comment: Re:Pardon my ignorance but... (Score 5, Informative) 273

by pjrc (#45202219) Attached to: USB Implementers Forum Won't Play Nice With Open Hardware

I have read the entire spec, except a few parts about the physical molding/construction of cables and some parts of the last chapter about hubs. I've read many of the change notices that come in the zip file with the main PDF. I've also read the entire HID, Mass Storage class specs, most of the CDC class spec, substantial parts of many of the others, and a good portion of the OHCI spec. I've also read the datasheets for numerous chips, API documentation for Mac, Windows and Linux (at least libusb on Linux), and numerous other related documents.

Yes, there's a lot of documentation. No, I haven't gouged my brain out.

I have implemented 2 USB device-side stacks on microcontrollers (a.k.a. "bare metal") from scratch. Both are commercially successful and in widespread use on Teensy 2.0 and 3.0 and numerous projects and products people have designed and incorporated my code.

While you've done neither, I most certainly have done both: read the specs and implement portions of USB. I would disagree with your opinion that summarizes USB as "horrible".

It's actually a pretty well though out system.

"One Architecture, One OS" also translates as "One Egg, One Basket".