I'm adding some 0.01uF caps in parallel with some of the 4.7uF caps to cut down on the little spike that's on the 5v line. The next board will add some ferrite beads, but this should be fine. I mean, it works even without the 0.01uF caps added. According to the people on the Microchip forum, any tiny disturbance causes the debugger to halt. They thought just running it at 30MHz was too much for the pickit 3 debugger. So, it may not be noise on the 5v line that was the problem with that. I think it's just touchy. It wouldn't even program with the original ribbon cable, and I had to shorten it to 3 inches or so of shielded wire cable. 30MHz has more annoyances than the traditional 16MHz that I usually use. The nice thing is, I can probably lower the frequency down to 15MHz later. It will still only be using less than half of the processing power.
If it loses the resolver signal (or encoder), my thinking was just to set a fault if the change in rpm was too big, and the change went from nonzero to zero. If it was already zero, and continued to be zero due to being unplugged, I guess that wouldn't be too dangerous. It would know about it in 1/128 sec, and could disable the igbts at that point, or whatever. I'll test it out.
Last edited by MPaulHolmes; 10-20-2014 at 01:47 AM..
|