I'v set all the ports as outputs. I think the problem is solved :) thank yo= u all, but to undestand why this happens (aka why does only the pwm module = is affected??) can i have some reference? i don't know exactly what to goog= le :) Yes, i decided to disable MCLR because i think i'll use it, short of pins ;= ) > Date: Mon, 26 Sep 2011 22:45:44 +0200 > From: jan-erik.soderholm@telia.com > To: piclist@mit.edu > Subject: Re: [PIC]PIC18F2550A, Pwm doesn't work when using on external po= wer supply >=20 > Hi ! >=20 > Wherever the supply comes from, never have any "open CMOS inputs" ! > If PORTA are inputs, and are un-connected, that *might* produce > the effect you are seeing. >=20 > How is MCLR handled. When conncted to the PICkit2, the PICkit2 > manage the MCLR pin, but how is it handled when connected to > the "power supply" ? >=20 > Jan-Erik. >=20 >=20 >=20 > Jacopo Monegato wrote 2011-09-26 22:33: > > > > Well, PORTA, but the program actually skips that part at the moment.... > > I think the crucial point is that the problem comes when i connect the > > PIC to the power supply instead of the PICkit > > > >> Date: Mon, 26 Sep 2011 22:22:10 +0200 From: > >> jan-erik.soderholm@telia.com To: piclist@mit.edu Subject: Re: > >> [PIC]PIC18F2550A, Pwm doesn't work when using on external power > >> supply > >> > >> > >> > >> Jacopo Monegato wrote 2011-09-26 18:57: > >>> > >>> but if i touch to some random and unconnected parts... > >> > >> Are those "unconnected parts", parts of the PIC ? This sounds as a > >> open-CMOS-input problem. Do you have any I/O pin that are inputs > >> (which is the default if you do not config them at all) and not > >> connected to anything ("open") ? > >> > >> Jan-Erik. -- http://www.piclist.com PIC/SX FAQ& list archive > >> View/change your membership options at > >> http://mailman.mit.edu/mailman/listinfo/piclist > > > --=20 > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist =20 --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .