Author Topic: New pic programmer DONE !  (Read 7830 times)

0 Members and 1 Guest are viewing this topic.

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
New pic programmer DONE !
« on: March 10, 2007, 02:56:19 AM »
Finally its done , now i can start on some overdue projects.

if anyone wants a programmed pic for pwm experiments send me an email.


project number one is of course the wind turbine monitor,wind speed , RPM, battery charger , dump load controller with a PC connection for data logging. should keep me busy for a little while. :)


i have allready monitored several channels of various voltages and passed them to the pc , using the PC serial port and a PIC uController .

i could copy a system that allready exists ,but what fun would that be.

i may have to learn Visual basic for the pc side , we'll see.

« Last Edit: March 10, 2007, 02:56:19 AM by (unknown) »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #1 on: March 10, 2007, 07:37:44 AM »
i found a viable chip.

its called 'PIC12F683-E/P'

it has an a to d converter  

and one PWM output and a built in oscillator


and costs a $1.29 each

« Last Edit: March 10, 2007, 07:37:44 AM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #2 on: March 10, 2007, 08:46:12 AM »
this is all thats needed for the 12F683 to get pwm

it has a built in oscillator , so ya dont need one of them.





this is tha actual pinout of the 12F683



the varible resistor is connected between 5V and ground


The wiper on the ' pot' connects to the analog input of the 12F683.


the Varible PWM goes from full off to full on in 1024 steps, at 20Khz ,

but it can go faster ,with fewer steps .


this is a possible use for the varible pwm

a boost circuit , but with only one pwm channel just connect battery minus to ground

the pwm connects to the gate of the fet M2



« Last Edit: March 10, 2007, 08:46:12 AM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #3 on: March 10, 2007, 09:14:02 AM »
this is a circuit that i've used a lot.

the resistor is a small section of stainless wire to cut foam.

the resistor could also be a motor , such as a portable drill




« Last Edit: March 10, 2007, 09:14:02 AM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
does efficiency matter?
« Reply #4 on: March 10, 2007, 05:18:19 PM »
In low winds , when boosting , which i've just simulated on the exercise bike, is efficiency really that important?


Being able to charge a 12V battery at really slow speeds seems enough to me

besides when effieciency is crappy there is just more load on the blades, or the pedals in my case.


Not that i havnt been able to get the efficiency up there , i have , because i can look at the current into the battery , and feel the drag on the alternator at the same time.


i can adjust the efficiency from these two inputs, i think.

« Last Edit: March 10, 2007, 05:18:19 PM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #5 on: March 10, 2007, 06:29:28 PM »
Right now I'm just trying to nail down the best frequency for boost, using the inductor that i have.


i've been able to raise the boost frequency to 65.8Khz with 256 steps ,


next i'm going to try 7 bits resolution and get the boost frequency up to around 156Khz, or a little less .

« Last Edit: March 10, 2007, 06:29:28 PM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #6 on: March 10, 2007, 07:16:55 PM »
at the higher freq boost it does a half an amp into a 12V batt at 135 rpm.
« Last Edit: March 10, 2007, 07:16:55 PM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #7 on: March 10, 2007, 07:19:25 PM »
where previously it started charging at 220 rpm.
« Last Edit: March 10, 2007, 07:19:25 PM by willib »
Carpe Ventum (Seize the Wind)

Boondocker

  • Full Member
  • ***
  • Posts: 193
Re: New pic programmer DONE !
« Reply #8 on: March 10, 2007, 07:22:41 PM »
How are driving the gate on fet M1?  Are you keeping it in sync with fet M2?
« Last Edit: March 10, 2007, 07:22:41 PM by Boondocker »

Tom in NH

  • Full Member
  • ***
  • Posts: 191
Re: New pic programmer DONE !
« Reply #9 on: March 10, 2007, 08:26:08 PM »
Hi Willib, It looks like you're having lots of fun. What sorts of voltage boosts are you seeing? Have you looked at any switched capacitor designs?


If you can re-configure your phase wiring, here's something to play with. Wire each phase separately, each to its own bridge rectifier. Take the three dc outputs and wire them together in series. Instead of a Sqrt of 3 voltage increase, you'll see a 3x increase.

--tom

« Last Edit: March 10, 2007, 08:26:08 PM by Tom in NH »

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #10 on: March 10, 2007, 09:02:53 PM »
Hi Tom , yes it is a ton of fun.

i've put the 'pot' on a wire so that when i'm pedaling i can vary the pwm. to find the sweet spot.


well as soon as i start pedaling it starts charging with 220mA at 12.63V , its hard to pedal any slower.

i could measure the alt output at that point , if thats what you mean?

i can tell whan the efficiency goes up because the pedaling resistance is almost non existant( when going slow)

i must not have things right yet , because even when pedaling slowly , i think i should be able to get more current.

dont know , yet , lots more testing to do

« Last Edit: March 10, 2007, 09:02:53 PM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #11 on: March 10, 2007, 09:06:06 PM »
I'm not using M1 at the moment , i have the battery minus connected to ground
« Last Edit: March 10, 2007, 09:06:06 PM by willib »
Carpe Ventum (Seize the Wind)

Boondocker

  • Full Member
  • ***
  • Posts: 193
Re: New pic programmer DONE !
« Reply #12 on: March 11, 2007, 04:26:47 AM »
Will,


Thanks for posting your results.  What kind/size of inductor are you using?


Boondocker

« Last Edit: March 11, 2007, 04:26:47 AM by Boondocker »

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #13 on: March 11, 2007, 07:04:06 PM »
Here is the inductor i'm using .

it used to be all four coils in parallel.

but i thought i would split it up and use two Fets for boost , now i just have to figure out how to get the Fets to alternate, or at least not fire at the same time.


i could just delay one by a couple hundred nano seconds by putting the signal through some TTL chips

have not decided yet.

i purchased some fet drivers that produce a very nice signal and drive the fet gate at 12Volts.




« Last Edit: March 11, 2007, 07:04:06 PM by willib »
Carpe Ventum (Seize the Wind)

Boondocker

  • Full Member
  • ***
  • Posts: 193
Re: New pic programmer DONE !
« Reply #14 on: March 11, 2007, 07:34:56 PM »
Take a look at this driver, IF2104, for running two MOFETs.  
« Last Edit: March 11, 2007, 07:34:56 PM by Boondocker »

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #15 on: March 11, 2007, 08:36:18 PM »
is that a international Rectifier part?

cant fid it
« Last Edit: March 11, 2007, 08:36:18 PM by willib »
Carpe Ventum (Seize the Wind)

sdscott

  • Newbie
  • *
  • Posts: 43
Re: New pic programmer DONE !
« Reply #16 on: March 12, 2007, 05:37:34 AM »
Hi Willib!  You may already be aware of this... the PIC12F683 is the Pic-chip used for the famous PICAXE-08M :)

Cheers!
« Last Edit: March 12, 2007, 05:37:34 AM by sdscott »

Tom in NH

  • Full Member
  • ***
  • Posts: 191
Re: New pic programmer DONE !
« Reply #17 on: March 12, 2007, 08:49:57 AM »
If you can't do it in software, hook the PWM output to a nand gate or inverter chip.

The output of this will be low when the PWM output is high, and vice versa.

-tom
« Last Edit: March 12, 2007, 08:49:57 AM by Tom in NH »

Boondocker

  • Full Member
  • ***
  • Posts: 193
Re: New pic programmer DONE !
« Reply #18 on: March 12, 2007, 06:39:39 PM »
Sorry, it is IR2104.  It will drive two PWM with a single input.
« Last Edit: March 12, 2007, 06:39:39 PM by Boondocker »

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #19 on: March 12, 2007, 07:54:24 PM »
I think it works , i have sent the origional signal through a few inverters and used the inverting output on the TC4428A ( fet driver), and got 600mA output at 127 rpm at 12.38 volts , this battery is badly in need of a charge , it is a lead acid auto battery .

i have had the boost up to about 2.4A at the point where it woould normally just be starting to charge ( 220 RPM).

 i really have a lot more testing to do , i didnt get much done yet tonight.


over the weekend i charged almost every NiMH battery that i own

« Last Edit: March 12, 2007, 07:54:24 PM by willib »
Carpe Ventum (Seize the Wind)

Bruce S

  • Global Moderator
  • Super Hero Member Plus
  • *****
  • Posts: 5422
  • Country: us
  • USA
Re: New pic programmer DONE !
« Reply #20 on: March 13, 2007, 08:13:10 AM »
Hey Willib;

   Charged every NiMh you own huh? maybe it time I put you on the list of NiCd packs.

Maybe start you out slow work up to NTL's size :--)

BTW: Very nice job on the circuit. The next best thing to conservation is being able to make as much use out of what is available as possible!!


Keep it up!!

Bruce S

« Last Edit: March 13, 2007, 08:13:10 AM by Bruce S »
A kind word often goes unsaid BUT never goes unheard

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
Re: New pic programmer DONE !
« Reply #21 on: March 13, 2007, 09:44:28 PM »
Bruce are you still looking for a way to charge them (the NiCd battery) packs?


just an update :

tonight i set two different PICs to different frequencies , i might try setting them both to the same frequency , the odds of them both being exactly triggering at the same time is small .


when i use the same trigger source for both FETs ,(and the delay) the output is barely more than with one. I think this is because when one fires the other is trying to fire too close to the allready depleated voltage from the first .

or maybe  i should use the two 1 Farad caps as a buffer between the alt and the boost like in the diagram.

i dont know , first i'll try setting them both to the same pwm frequency , use two different clock sources , and see what happens

« Last Edit: March 13, 2007, 09:44:28 PM by willib »
Carpe Ventum (Seize the Wind)

willib

  • SuperHero Member
  • ******
  • Posts: 2414
  • Country: us
over 90 watts
« Reply #22 on: March 14, 2007, 11:25:39 AM »
91.2 watts from minigenII , without boost .


 6A at 15.2 Volts


6* 15.2= 91.2 watts


This was into an Interstate Mega Tron Plus with 700 CCA , 850 CA


rest voltage after test 12.65V


i could not keep it up for long though because of the RPM  necessary to get this output , i should really look into using that smaller drive sprocket

« Last Edit: March 14, 2007, 11:25:39 AM by willib »
Carpe Ventum (Seize the Wind)