| Devil_H@ck |
I don't know if I should post this here, but I really need help, so I'll do it anyway :).
I want to make a digitally controlled preamp, therefore I need a microcontroller. I chose the PIC18F452, which is one of the top models of Microchip and can be easilly had.
So, to program everything I build myself the JDM Programmer. I designed my own PCB layout, which you can see here. The Eagle project files are here.
On this site they tell you how to measure everything. This is also the site where I got the schematic from. I measure everything like told there, but I get very strange measurements:
Ground reference is pin #12/31.
x -> y means that the measurement is first x then starts going up/down until it reaches y.
MCLR (pin #1): 9.75V -> 8.68V (1-2 mins later) - Off: -0.5V - Should be: 14V
Vcc (pin #11): I measured about everything below 1V (starting at 0.95V and then it keeps getting lower) - Off: 0.2V lower than On - Should be: 5V
Clock (pin #39): 15.7V/12V - Off: 0.2V -> -0.2V - Should be: 5V +- 1V
Data Out (pin #40): 0.4V -> 0.15V (2 mins later) - Off: -6V - Should be: 5V +- 0.5V
Can anybody help me with this? I've checked the layout of my PCB for at least 10 times now and I don't see what's wrong. Also, everything seems to be soldered in the right place.
I'm getting quite desperate. Help is appreciated ;). |
|
|
| SoundOff |
If you have the board wired correctly then nothing should be able to be more negative than Vss. The readings you have would be around correct if you were measuring with reference to Vdd rather than Vss.
These self powered serial port programmers always seem to be more trouble than they are worth. I've always used the classic buffered and powered jobs like the David Tait (or a Fobbit) for PICs, and the ISP dongle for AVRs.
I've just fired up a breadboard of my digitally controlled preamp, using PGA2310s in balanced configuration, controlled by an AVR with RC5 and encoder input. It's all looking good!
Colin |
|
|
| Devil_H@ck |
| Well, I'll consider making the Tait programmer. |
|
|
| loonatron |
The JDM can easily be upgraded to be powered by two 9v batteries. Have a look at the link I provided. You may have to do some 'forum searches' but here you will find excellent hints. There is a thread under the 'troubleshooting' forum, it is 'sticky' so it is always at the top of the list of topics.
good luck. |
|
|
| Devil_H@ck |
| quote: | Originally posted by loonatron
The JDM can easily be upgraded to be powered by two 9v batteries. | Take a look at my website, I added an option to connect a separate power supply to it. |
|
|
| maylar |
| quote: | Originally posted by Devil_H@ck
Take a look at my website, I added an option to connect a separate power supply to it. | Either that's hidden really well or I''m blind, because I don't see anything on your web page except the original. |
|
|
| jackinnj |
always test out your programmer -- every time I do a project with a new variety of PIC I program it with a "BLINK" project -- to blink a LED -- as simple as this sounds it will point out whether the programmer is working in the first place.
i don't think i would have chosen the 18FXXX line for a first project anyway -- you can search the PIC LIST (go to www.melabs.com) for the quirks which people experience with PICS of different flavors.
btw. I usually build my projects on a BasicStamp II, then port it to a PIC using PICBasic Pro. The BasicStamp II has a very easy DEBUG function which allows you to make changes on the fly, i.e. without taking the device in and out of the programmer. The stamps lack the utility of the PIC's, but will get you most of the way there. |
|
|
| Devil_H@ck |
| quote: | Originally posted by maylar
Either that's hidden really well or I''m blind, because I don't see anything on your web page except the original. | It's just 2 holes & 1 resistor really, look at the photograph, lower left corner, there are no pins in the holes yet, but the resistor is next to the biggest cap. I can connect a power supply input there.
| quote: | Originally posted by jackinnj
i don't think i would have chosen the 18FXXX line for a first project anyway -- you can search the PIC LIST (go to www.melabs.com) for the quirks which people experience with PICS of different flavors. | Well, I've read a lot on the PICList and most of the time people tell you to start with a PIC16F877.
However, the PIC18F452 has as much pins and can be programmed in C. I know some Visual Basic, PHP & other programming languages and this C stuff for PICs doesn't look hard.
Another advantage of starting with a top of the line PIC is that I'll have every option available. If I don't want to use an option, I don't, if I want to, I do, simple as that. I also believe that learning to program "lower rank" PICs will be easier than starting from a "low rank" PIC and later upgrade to a "high rank" one.
The PIC16F877 costs 6€, the PIC18F452 costs 8€, so that isn't a reason not to choose it either.
| quote: | Originally posted by jackinnj
btw. I usually build my projects on a BasicStamp II, then port it to a PIC using PICBasic Pro. The BasicStamp II has a very easy DEBUG function which allows you to make changes on the fly, i.e. without taking the device in and out of the programmer. The stamps lack the utility of the PIC's, but will get you most of the way there | The BasicStampII cost +-50$, right? PICBasic Pro costs 250$ if my memory serves me correct? Now, with a bit more debugging you could lose the BasicStamp, that 50$ saved.
Then, if you decide to use a PIC18xxx you could use a free C compiler. That saves you 250$. I found PICBasic very interesting at first, since I know Visual Basic, but I can't spend that amound of money on just a software package that I might find usefull while there are alternatives.
I'm a student and I can't justify spending +250$ on software and parts needed for 1 part in a project. |
|
|
| jackinnj |
| quote: | Originally posted by Devil_H@ck
Well, I've read a lot on the PICList and most of the time people tell you to start with a PIC16F877.
|
If you shop carefully you can get the PIC16F877 for a couple $. I was thinking of carrying them on my webstore, along with the PIC16F873 but don't want to carry a couple hundred in inventory.
If you really want to be at the cutting edge, then USB compatibility is the way to go, but most of these devices are "Future Production". in the PIC18FXXX line.
btw, I only subscribe to the PICLIST periodically as it gets clogged with SPAM. |
|
|
| GUILHERME |
Hi.
Just a thought:
Have you checked the cable connecting the computer to your programmer ? Depending on it being a nullmodem cable or not, some of your signal wires could be switched. More info here:
http://www.cc86.org/~pjf/hwb/ca_Nullmodem9to9.html
BTW, I'm also corrently working with a pic in the same range as yours ( 18F442 ). I've built the "programmer" into the device I'm designing so I can do in-circuit programming. I've compiled the Brocolli source code into a win32 binary and use that with the hex output from mplab to program the pic.
Guilherme. |
|
|
| Devil_H@ck |
| I just searched some more for a possible error. First I turned the two transistors 180°. That seemed to yield better measurements, but still not good. Then I saw that pin 6 from the COM connector was pin 9 on my PCB, so I cut some lines, soldered some wires, ... In the end I found out that I had read my PCB layout upside down :smash:. And so I'm back at where I came from :(. |
|
|
| Devil_H@ck |
In case anyone is interested, I decided to make another programmer. After lots of searching I found the PPWin programmer, which has a 8-, 18- & 40- pins socket already on board, so almost all PICs can be programmed without an adapter. There's also an ISP socket on the board.
I made the PCB last Thursday and I was amazed at the kind of detail I could obtain with just a transparency and an inktjet printer. 5mil tracks without a problem, nice :).
Yesterday, I soldered everything onto the board & today I connected the parallel port connector. I just tested it and it worked from the first time.
Now I like buffered, powered programmers better than programmers who get there supply from the RS232 port :).
Link to the programmer: http://www.semis.demon.co.uk/Pics/PICmain.htm
If you want to make the PCB, I suggest you download Easy-PC from here: http://www.numberone-usa.com/downloadrequest.asp.htm. It allows you to import the Boardmaker .pcb file that can be found in the zip file on the programmer's site. The result should be a lot better compared to using the bmp in the zip for printing.
Pictures will be on my website soon.
Oh, btw, the parts (+ parallel cable) + pcb cost me +- 12€. I'm pretty sure you can't buy any commercial programmer that can do as much as this one for that price :D. |
|
|
| jackinnj |
| this is the one I use (I do have a PICSTART which Microchip gave away at one of their seminars, but it always needs reprogramming), the MELABS serial programmer is a breeze to use: |
|
|
|