USB gizmo (PIC 18f13k50)

I made this working a while ago, using source code included with the USB stack. However, in the meanwhile, I reinstalled Windows, and changed to MPLAB X.

I spent the whole morning trying to compile it using XC8.
Many different errors, and many problems with directories.

Finally I downloaded MPLAB X 1.41 (some bugs seem to be fixed now), and also the C18 compiler. I copied the include files into a new directory.

Actually I did not use the old source code. It is not so difficult to change the source code (and the linker script) to use the 13k50 instead of the 14k50, but isn't so easy either.

It is 3PM now, the source compiles, I reflashed the gizmo, and it really works again. Back then, in March 2012, I had issues with the oscillator, I did not succeed at all using a 6 MHz resonator, and worried many hours what was wrong. Until I simply had the idea to use a canned 12 MHz oscillator- it worked!

I want to build a new circuit, using the same chip for a LED matrix scrolling message. I want to download the message via USB! The problem is, there are only about 2K Flash left, which is not much, and also there is not too much RAM remaining. Eventually I will have to change to 14k50, but I will try and see if I can implement it on the 13k50.



Blog entry information

Last update

More entries in General

More entries from takao21203

Share this entry