Marechiare wrote: >> ...It is often easier to take a working system, and tweak >> it until it does what you want, instead of writing one from >> scratch. Even if you end up rewriting it from scratch anyway. > > I agree, BTW. Easier, sometimes (not as often as people seem to think), but that is not always the objective. Trying to implement something yourself based only on seeing other things work can be a real eye opener. The educational value of running into the same problem others faced, then realizing that's why that other system has a particular quirk is way better than having it told to you. I remember learning way more about operating systems in general by writing one from scratch in assembler on a small minicomputer. I missed a few things, like a tree structured file system, but I also got a few things right and actually came up with a some clever ideas of my own (dynamic relocatable linking for example) because I had the advantage of not knowing the "right" way to do something. The end result was a lot better than the poor excuse for a operating system this computer had before, and my OS was still in regular use 4 years later when I left there. The point is that it wasn't any kind of super operating system, but by going thru the design process I came face to face with tradeoffs other operating system designers encountered, and a lot of seemingly arbitrary quirks in other systems suddenly made a lot more sense. It also made it easy to absorb subsequent information about operating system architecture which probably would have gotten partially lost without the special insight from having been there myself. You can't of course do everything yourself. You have to pick what you will use as a tool and what you want to accomplish and what your end goal is. This is one point Solarwind still needs to learn. It's not clear what he really wants to accomplish and what he wants to get out of it, which is partly why the responses he's getting are all over the place. Does he want to learn about low cost light-weight networking and the problems associated with corruption, flow control, guaranteed delivery, response time, etc? If so, implementing his own RS-485 network from scratch is a great way to go. Is his real objective to get a house monitoring and energy management system up and running and explore the higher level control algorithms? In that case just use the CAN hardware already and stop making things so complicated and don't worry about trying to use a PIC 16 at all. I also take issue with the statement that it's often easier to take a working system and tweak it. Most of the time I've taken someone else's code and tried to integrate it into a embedded system it was more trouble than it was worth. The other code is rarely well written, and of course never fits into the philosophy of how my particular system is structured. I can't think of a single PIC system where in hindsight I wouldn't have been better off creating the subsystem myself. The only bright spot I remember about using existing code were the JPEG image routines that I integrated into my own imaging library. The routines I found for free on the net from the from the Independent JPEG Group just worked, and the interface fit well enough into my image file driver architecture. Of course this was PC code, not PIC code. ******************************************************************** Embed Inc, Littleton Massachusetts, http://www.embedinc.com/products (978) 742-9014. Gold level PIC consultants since 2000. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist