PIC MCU Programming Page

March 30 2004
So I got the latest version of Salvo yesterday, and I am trying to put everything together. Also, the new boards have been ordered and I am really anxious to get my hands on them. I am so crazy with all this extra work. I need a break!

March 15 2004
The board prototypes were delivered a few days ago. Pics are here.

I can say that board layout skills definitely improve with time. Anyway, the prototypes are just great. Noise has been eliminated almost completely. Now it's just a matter of finishing up with the software.

The TCP/IP part is still giving me trouble. I think this is mostly due to the fact that I still expect the memory in the RTL8019AS to be used as a buffer. There is simply no good way to create a reliable state machine, with packet history, without main memory. I hope I am wrong. At this point, it looks like the connection might be a bit unreliable. I see 1 in 128,000 packets just being garbled and causing the connection to drop. I am not giving up on this yet.

February 3 2004
I sent an email to Realtek and after about 3 days I got a responce. The tech person was very helpful, and included many hints and source code.

One big heads-up was that if the 9346 EEPROM is not part of the circuit design, then: The EED0 pin, MUST BE pulled LOW, or the NIC might enter the "inactive mode" at random times!!!

This exact thing was happening to me and I couldn't figure it out. Here is the file from Realtek.

I can't post the entire archive that Realtek sent me, since it seems to have some proprietary stuff in it, and I did not see a release note. You just have to send them an email if you need it.

So, more problems have been discovered with the software, but at least now I can trust what I am reading from the NIC. The rest is just making the protocol state machine work.

January 26 2004
Well, it seems that the RTL8019AS User's guide is almost worthless. The information there is very limited. I found much more info on other sites that had NE2000 compatible chips. National Semiconductor has a chip called DP8390D which has much info on programming an NE2000 compatible NIC. Also, davicom has much info on their NE2000 compatible chip (the DM9008).

Besides that, there are some serious bugs with the Microchip TCP/IP stack software. These bugs show up when the 8019AS is driven by a high speed MCU (like the 18F8720 at 40MHz.) It is so frustrating when you don't know if its software or hardware that's killing you. More soon...

January 13 2004
I am having some serious problems with the RTL8019AS Network Interface chip. I haven't been able to find two drivers on the net that act the same. Then, when I try to drive the chip using the Realtek timing diagrams, nothing works.

The Microchip network code for the PICDEM.net is ok, but it needs work. I need to fix the network code before I even think of moving to the Salvo RTOS.

Anyway, good thing I have the right hardware tools. It makes life so easy. For one thing, my Logic Analyzer is nothing fancy, but is has saved me many hours of debugging. If you guys work with embedded systems, you must get one of these babies!

I wish I had a Tek scope that can analyze jitter. It would really help. Well, the 7854 is actually really good. It is just a bit slow.

October 30 2003
My first Web server using the Microchip stack is online. ... Yes!!! Naturally, I made some very nice optimizations :)
I am a bit confused about the License for the code. It says "free" on the web site but the code says: Owned by Microchip. Well, which one is it? Also, the book that comes with the "PICDem Net" board, says that the code provided is not to be used for commercial purposes. Well, forget that! I can write my own. The book is very annoying in other ways also.

Next step is to incorporate the SALVO RTOS into the project.

October 28 2003
The NTP digital clock is in progress. I have three versions of the TCP/IP stack. One by Microchip (PICdem NET), one by, EDTP Electronics (Packet Wacker) and one by OpenTCP.org. I am currently in favor of the OpenTCP version since it is not very complex and it looks like I can incorporate my Salvo RTOS into it. More to follow on this very busy project.

August 7 2003
Despite the fact that I have sold some of my programs to a commercial interest, I am still available to answer any questions on Salvo OS and Hitech PICC18 compiler. I will be happy to help where I can. Please feel free to contact me (click here).

I recently upgraded my Salvo OS and PICC18 compiler. Right now I am running Salvo OS Version: 3.2.2 and "HI-TECH PICC-18 COMPILER (Microchip PIC18) V8.20 PL4"

The upgrade went without problems and I was able to compile all my stuff without changing a thing.

July 30 2003
Well, I sold all my PIC programs and, all the rights, to a third party. At this point I am not allowed to divulge who. Sorry everyone. The programs that I link to, below, are still free.

The Microchip PIC processor is becoming the most popular platform for embedded systems. Since I have a few ideas of my own about certain projects, I thought it was time to get my hands dirty and learn all about the PIC MCU line.

I bought Myke Predko's book: "Programming and Customizing PICmicroŽ Microcontrollers" and I couldn't put it down. I highly recommend this book for beginners and advanced PIC programmers.

It seems that there are several architectures of PIC MCU's. For my purposes, the 12,16 and 17 series were underpowered. I settled for the 18F452 and 18F8720 for my projects. The 18F452 and 18F8720 are both flash devices which means I would not need a burner.

One thing I did not want to do was write assembler code for my projects. In my lifetime, I must have written close to 100,000 lines of assembler code and I've had enough. Which left me with C as the target language. Among PIC C compilers, the HI-TECH PICC-18 product is the best in the market.

In the Predko book, there is a sample program of a RTOS written in assembler. This got me thinking that it would be really nice to have an RTOS for my projects. When I was looking through the Microchip web page, I saw a reference for the Salvo RTOS made by: Pumpkin Inc.

Well, I bought both products and I am working full time with them. As of September 24, I have the first working program using HITECH PICC18, Salvo and the 18F452 MCU. Click here to view

The first attempt at a PIC program. Can you spot the glaring bug? It took me 12 hours of debugging to find it. Click here to view

I keep a daily log of my programming for the PIC, so check there for updates.