Hi, thanks for the advice, i have set it up to use 4 AAA batteries but it does pretty much the same as the potential divider (wondering what the difference is) however on closer inspection of the ticking comming from the servo, the shaft is actually moving albeit very slow and weak (like a ticking clock) so i am beginning to suspect that my timing pulses must be off? here is some of my code: ;========================================================================== ; Variable Definition ;========================================================================== TIMER1 EQU H'20' ;Used in delay routine TIMER2 EQU H'21' ; " " " TIMER3 EQU H'22' ; " " " ORG 0 ;Reset vector address GOTO RESET ;goto RESET routine when boot. ; ********************************************* ; * Example of a delay routine * ; ********************************************* DELAY_ROUTINE MOVLW D'38' ;54 Generate approx 1.5mS delay at 4Mhz CLK MOVWF TIMER2 DELAY_ROUTIN MOVLW D'255' ;54 Generate approx 10mS delay at 4Mhz CLK MOVWF TIMER3 DEL_LOOP1 MOVLW D'255' ;60 MOVWF TIMER1 DEL_LOOP2 DECFSZ TIMER1,F GOTO DEL_LOOP2 DECFSZ TIMER2,F GOTO DEL_LOOP1 RETLW 0 ; ********************************** ; ** RESET : main boot routine ** ; ********************************** RESET MOVLW B'00000111' ;Disable Comparator module's MOVWF CMCON ; BSF STATUS,RP0 ;Switch to register bank 1 ;Disable pull-ups ;INT on rising edge ;TMR0 to CLKOUT ;TMR0 Incr low2high trans. ;Prescaler assign to Timer0 ;Prescaler rate is 1:256 MOVLW B'11010111' ;Set PIC options (See datasheet). MOVWF OPTION_REG ;Write the OPTION register. ; CLRF INTCON ;Disable interrupts MOVLW B'11000000' MOVWF TRISB ;RB7 & RB6 are inputs. ;RB5...RB0 are outputs. MOVLW B'11111111' ;all RA ports are inputs MOVWF TRISA BCF STATUS,RP0 ;Switch Back to reg. Bank 0 CLRF PORTB ; EFFECT_1 MOVLW B'00001100' ;Activate LD4 (RB3) & Send the pulse to servo on LD3 MOVWF PORTB CALL DELAY_ROUTINE MOVLW B'00000000' ;Deactivate LD4 (RB3) & Servo MOVWF PORTB CALL DELAY_ROUTIN ;Small period delay GOTO EFFECT_1 END this is basically an example LED flash code i modified and judging from the original comments 255 = 10ms pulse so 38 should give around 1.5ms, maybe i have miscalculated something or overlooked some detail, as i said this might be easier if i could simulate and see the timing pulses myself but that doesnt seem possible with some of the linux software i have tried so far Jason Jinx wrote: > > Hi Jason, could you use 3 or 4 AAs instead of a 9V (I guess > this is a PP3 type ?). Or is there a weight problem ? Maybe > AAA or AAAA ? > > Losing almost 1/2 a 9V battery's voltage in a linear regulator like > the 7805 is very wasteful, and PP3s don't have a lot of capacity > to start with. A better linear choice that's common would be the > LP2950-5.0, and there are other low quiescent current ones. One > of the big drawbacks with a 7805 is that it consumes 8mA just > on its own. That's acceptable for a big battery or mains supply > but not for smaller batteries. Low quiescent current regulators > use only a fraction of the 7805, usually under 100uA (that's just > an 80th or better of 8mA) > > The above probably won't solve your motor problem but it's > really worth thinking about > > -- > http://www.piclist.com PIC/SX FAQ & list archive > View/change your membership options at > http://mailman.mit.edu/mailman/listinfo/piclist > > -- View this message in context: http://www.nabble.com/pic-servo-power-supply-problems-16f627-tf3424352.html#a9546667 Sent from the PIC - [PIC] mailing list archive at Nabble.com. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist