Embedded Systems Software, Computer Networking and Geeky Fun

nerd1951.com

April 20, 2007

# kill -9

Filed under: News, Geeky Fun — harvey.sugar @ 12:19 pm

Almost a year ago I had a post about Geek Rhythms, a silicon-valley group who produced a couple of hip-hop like tunes that were featured on NPR’s Marketplace. Well I’ve stumbled on to another hip-hop nerd gem called “kill -9.” In case any of my readers have never used Unix or Linux, kill -9 is to Unix what Alt-Ctrl-Del is to Windoze. It is the ultimate power the user has short of pulling the plug.

Kill -9” is much rawer and has some explicit lyrics; much more in the spirit of real hip-hop or rap. This song will never be on Marketplace but it is definitely Geek Culture

• • •
 

April 17, 2007

Business Rules for Consulting

Filed under: Rants — harvey.sugar @ 9:31 pm

I did free lance consulting work for over ten years. I learned a number of lessons the hard way. The most important things are to conduct your self in a professional manner with honesty and integrity, do the best job you can and deliver work that exceeds your clients’ expectations. Even when you do these things you can run into problems with clients, especially in a tough economy. Here are a list of rules that can help keep you out of trouble.

  • Never, ever give an estimate or a bid without a clear understanding of the work to be done. This can be as simple as a one-page statement of work or as comprehensive as a complete software specification.
  • Make sure the client understands that deviating from the specification in any way means more work, hours and money.
  • Never, ever, work without a written work order or purchase order.
  • Make sure that the person that authorizes the work really has the budget authority they need to pay you for the work. If you are going to exceed your estimate, get authorization from the person with the budget authority.
  • Make sure that the pay rate (I know this is obvious but it happens) and the terms of payment are in the agreement.
  • Keep copies of all confidentiality agreements, non-disclosure agreements and non-compete agreements. Stick to them and never discuss your customers’ business with anyone else.
  • Have a clear collections policy for when you don’t get paid on time and give this to your customer up front. Actions can include late fees and stopping work. Stick to it and never let a customer get so far behind that you can’t afford to walk away from the job.
  • Know what forms and documentation you need to submit for payment including what signatures you need. If you are dealing with a large company, hand-carry your documents to the people that need to sign them.
  • Get to know the people who process your payments. Make sure they get to know you. When the day comes that you have a problem they will see you as a person instead of a problem.
  • Find out when your client processes invoices. Most companies process invoices once or twice a month so align your billing cycle with their payment cycle. Get the invoice in a few days before their processing date. Being a day late with an invoice can mean getting paid fifteen or thirty days late.
  • Keep detailed records of your hours and what you worked on. If there are ever any disputes about your hours these records can save a contract. Use some automated time tracking software that pings you periodically. (Check out UUR, a free time traking utility).
  • If you are asked to settle for less than the hours worked, agree if you have to but make it clear that you won’t work for them again.
  • Never stop marketing and selling yourself. Even if you are on a full time long term contract, don’t let former clients forget about you. Once in a while do a part time project even though this makes life tough it keeps your name out there.
• • •
 

April 12, 2007

Packet demultiplexing in hardware

Filed under: News, Projects, Tools — harvey.sugar @ 3:37 pm

I have to admit that ever since the fad in network processors back in the late ‘90s, I’ve been interested in developing hardware for packet processing. This has been at least part of my motivation to learn a Hardware Description Language such as Verilog or VHDL. I remember a time when logic could only be programmed with a soldering iron and wire but I did design some hardware back in the ‘80s using programmable logic and a language called ABLE. But ABLE is like the HDL version of FORTRAN.

The problem with most of the network processors was that they were trying to solve too many problems at the same time. This was an era when Frame Relay was still in common use and ATM was nearing its peek. Designing hardware that could deal with Frame Relay, ATM, MPLS and the Internet Protocols made network processors so complex that they were impracticably difficult to program. They were also physically large, expensive and power hungry.

Two things have changed since then. The capabilities of programmable logic have grown immensely due to their increased density and speed and the quality of development tools. We have a much smaller set of protocols to deal with since the Internet Protocols now dominate networking. This makes it possible to develop more specialized hardware for specific functions such as packet demultiplexing and header check-summing.

Two things came together that got me thinking along these lines. On my way to the Embedded Systems Conference I read the chapter on packet demultiplexing in Network Algorithmics and a paper about a specific packet demultiplexing scheme called Pathfinder. Pathfinder included a hardware implementation. The other influence was Altera’s booth at the Embedded Systems Conference.

(Disclaimer: my employer is an Altera Certified Design Center Partner). Altera was showing a low cost development kit that they market to schools for logic design courses. The student project was pretty cool. It took two video streams, one from a DVD player and one from a live camera feed and displayed them on one screen with the live feed in the upper left quarter of the screen.

I struck up a conversation with the guy at the booth and he told me about two low cost evaluation kits. One is based on Altera’s Cyclone II FPGA and lists for $150. This kit has the interfaces required if you want to fool around with audio or video signal processing. The second design kit was just announced to support the Cyclone III FPGA. The board includes a high speed interface connector and gobs of RAM. This kit usually lists for $200 but is available at $150 for a short time. Altera has design tools free for download from their website.

What really makes this interesting is that they have a processor core that fits on the Cyclone III and still leaves room for special purpose logic. There are also cores available for Ethernet MAC interfaces. I’m thinking that it could substantially reduce the overhead for processing packets if the MAC interface, packet filtering and check-summing logic and the processor all communicated over on chip busses. The packet headers could be processed in parallel with writing received packets into RAM.

But I’m getting way ahead of myself. I still want to finish a software version before I start designing hardware implementations.

• • •
 

April 9, 2007

Cannonball Update: Packet Demultiplexing

Filed under: Projects, Cannonball — harvey.sugar @ 9:37 pm

I was reading about packet demultiplexing in Network Algorithmics during my flight to San Jose last week. The chapter discussed the advantages of “early demultiplexing” vs the traditional protocol layer-by-layer demultiplexing. In early demultiplexing the packet’s entire path through the protocol stack is determined in one operation as I discussed in Cannonball Update: A Radical TCP/IP Architecture.

Two high-performance packet demultiplexers were discussed in the chapter: Pathfinder and the Dynamic Packet Filter. Of the two implementations, the Dynamic Packet Filter is faster but requires run-time code generation and I feel that this is beyond the scope of my project.

Both of these implementations are based on a data structure called a trie (from retrieval). As shown in the diagram the data is laid out in a tree like structure but the nodes do not contain the keys. Rather a complete key is represented by the position of the node in the trie. In a demultiplexing scheme, each node would contain a header field, a mask, and a bit pattern to match. For example the root of the tree would decode the Ethernet protocol type field.

trie example

Evgeniy Polyakov is working on tries for the Linux TCP/IP stack as he discusses in his blog: Zbr’s days.

Right now I’m designing classes to implement a demultiplexer similar to Pathfinder then I plan to generalize the classes into template classes. These will be the first component in my Networking Protocol Library.

• • •
 

April 5, 2007

My Dilbert Moment

Filed under: News, Geeky Fun — harvey.sugar @ 8:03 pm

I had a Dilbert moment yesterday when I returned to my hotel room. I got off the elevator and walked down to my room. The maid was there so that door was open and I walked in. It looked like my room. My Dell laptop charger was there on the floor by the desk where I left it; forgetting to put it away with the laptop. My jeans and Embedded Systems Conference t-shirt were thrown over the chair and I could see my brown sort of “nice” shoes under the desk where I left them. But something was wrong. There was an empty Linksys wireless router box on the desk and the brown shoes were not quite the same style as mine. I felt like I was in a Twilight Zone episode and had stepped into some weird parallel universe that was an imperfect replica of our own. I was afraid I would bump into my other self from this universe an rip an un-repairable hole in the fabric of time and space.

Then I checked the room number. I realized that I had gotten off the elevator a floor below my hotel room. This was someone else’s room but his stuff was almost a copy of my stuff. Are we really all that much alike? OMG, I hate it when I am the stereotype. I am Dilbert.

• • •
 

April 4, 2007

Fun at the Embedded Systems Conference!

Filed under: News, Geeky Fun — harvey.sugar @ 8:48 pm

There’s really so much to write about that I don’t know where to begin. The west coast version of the Embedded Systems Conference is almost like an entirely different show than the Boston version. There are about five times as many vendors here with bigger booths and more cool stuff.

They seem to understand what makes engineers excited and what we consider to be fun. For example they took apart a Toyota Prius on the exhibits floor to see what makes it tick. Talk about nerd-vana! If you’ve ever seen the show American Chopper on the Discovery Channel then you’ve heard of Orange County Choppers. Intel had Orange County Choppers build a custom bike for them. In addition to being a classic copper, the bike had some high-tech goodies. Instead of using a key lock, there is a thumb print reader by the right handle. The bike also sported a GPS navigation system that is really just a rugged computer, based on an Intel processor, of course.

Well I have to run off to the Speaker Reception but I’ve got loads more to talk about so stay tuned!

• • •
 

April 1, 2007

Off to the Embedded Systems Coference - Silicon Valley

Filed under: Rants — harvey.sugar @ 10:49 pm

Well, I’m off to the Embedded Systems Conference. Al Gore is my opening act. Well actually, he’s giving the keynote address and my presentation just happens to be in the next time slot. I’m sure the former Vice President’s speech will be about climate change. On that note, I followed my usual transportation habits and took the bus to the subway to get to the airport this morning and caught a nice nap on the way.

Besides giving my presentation on efficiently coding communications protocols in C++, I plan to sit in on some of the other sessions. I’ll probably sit in on a few of Dan Saks’ lectures on embedded systems programming in C++. Dan is a good presenter and I usually pick up something that I’ve missed before or forgot. Dan Saks has been a mainstay at the Embedded System Conference ever since the first one I attended about a dozen years ago. That was at the beginning of my first C++ project when a couple of us went to the Embedded Systems Conference in Boston; mostly to hear Dan Saks and Bruce Eckle (Thinking in C++, Volume 1: Introduction to Standard C++ and Thinking in C++, Vol. 2: Practical Programming) talk about programming embedded systems in C++. I’m also going to sit in on presentations on Agile Development and IPV6.

I’ll also be checking out the exhibit hall to see what’s new. I’ll probably post a couple of entries about anything particularly interesting or exciting that I see there.

• • •