Essentials of PWM

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
all right today I'm going to discuss pulse width modulation otherwise known as PWM okay now PWM it seems complicated but it's not and in fact one of the things that I try to encourage you guys to do is pay attention to language don't don't look at pulse width modulation as a phrase and be intimidated by it look at the individual words or lever every one of you has a pulse you don't you know and your heart's lectured by the way uses Ohm's law to control your control your heart rate and you know your heart kind of looks like this it's got four chambers and it goes bloop bloop bloop bloop and it's actually got bicuspid and tricuspid valves that are basically one way check valves and it's a variable displacement pump just like anything you have on a hydraulic system and the word Takas means speed right so if you have tachycardia cardiac means he a heart and Takas mean speed so tachycardia means your heart's racing all right well in this particular case you have a pulse I think it goes mmm that's fraud that probably means you're like dying or something but you get my point and then width is width right so you know this is narrow and this is wide all right so width is width the only words you may not be familiar with but you really are is the word modulate which is the same word as module and module or modulate literally means to change so modular maintenance modular home engine control module an engine control module is easy to change which of course is where a lot of our problems arise because people want to change them all the time so literally the word pulse width modulation means to change the width of a pulse okay and you can have either PWM inputs or you can have PWM outputs okay and PWM inputs take an analog signal and the word analog means analogy actually and an analog signal does this and a digital signal does this because digits means 1 and 0 and it converts an analog to a digital signal and the computer is looking at time alright so for a PWM throttle position sensor as you move the throttle position sensor the PWM sensor is sending a time signal to the ECM and output on the other hand doesn't really have any of this going on it's the same idea but it's actually average voltage okay and voltage is what controls amperage because as you know from my previous conversations volts and ohms make amps alright well if we're changing the resistance that's a rheostat and that will change amperage or we can change voltage which in this case is PWM and either changing the rheostat resistance or changing the pwm voltage will change the amperage output and when it comes to a solenoid that's doing a solenoid thing okay solenoid has a magnetic field so let me see if I can find am I've done it such a freshen horn one sorry so inside the solenoid is a coil of wire just as a reminder okay that coil of wire produces a magnetic field and the magnetic field looks like this which is why you can use a compass it's a very bad magnetic field but it's still a magnetic field and you get the idea okay so the strength of this magnetic field in a pwm actuator is what controls how much it pulls so we need to be able to control the amount of proportional magnetism which is why it's called a proportional solenoid okay proportional simply means Pro Porsche no actually just means a little as a little in a lot as a lot right so you pull the stick a little bit you get a little bit of movement you pull the stick a lot you get a lot of movement all right that's some fundamentally how that works all right so you've got basic idea here alright we can either send a pulse wet signal into the computer alright to tell the computer something because that's what inputs do switches and sensors or we can use PWM to send a signal out to the to an actuator in order to control the hydraulic system or a throttle or something to that effect so that's the basic idea and I'm going to pause now and go look for my markers because I think my daughter's daughter took them up to her room to do something for a project for school or something and I have to go get them back now so give me give me just a minute here okay so here's my Star Wars lunchbox and lo and behold look at all my markers oh yeah my daughter she's just okay get some markers out here I can use them for different different colors just like her she's pretty good artist evening she does shuttle all kind of neat stuff she's pretty pretty good at it so I encourage that I want to take pink out just because I can I'll take out light blue okay so what I'm going to do is move to the next portion of this but I'm going to put this put the term back up there because I want you guys to get used to understanding language language is so important okay critically important I mean even the word solenoid comes from the word Sun Sol okay so language is is is really important I've already talked about that with rheostat Rio means flow potentio potentio means voltage so I really hope you guys are focusing on language and I'm actually working on mechanic's glossary but um it's stuff struggling so what I'm going to do here is use something you're familiar with so I'm going to start here let me say 2 4 6 8 10 12 14 16 18 20 22 24 all right well 24 hours in a day alright so in this particular case the cycle or circle is going to be a day so the pulse width will be how long the width of the pulse is and the cycle or frequency is going to be 24 hours so the cycle or frequency is going to be 24 hours and the pulse width is going to be literally the length in time that your this signal is on okay so let's say that you work an eight-hour day okay well there's two four six eight all right so let's say that you were on duty eight hours okay so you're on duty eight hours which would mean of course you know not taking into consideration drive time and locker room time and all that other stuff we have to put up with it we're not paid for then you would be off duty sixteen hours okay so that that's the idea you'll be off duty 16 hours the pulse-width in this case is going to be 8 so our PWR pulse a literal pulse width would be measured in hours and the width of the on pulse is 8 hours well there's also another element to this and that is that this is one-third on and two-thirds off so now our duty or our duty cycle hits the duty okay it's going to be 33.3% this is what's referred to as percent duty okay so the duty cycle would be 33.3% or one-third on that's all it means ok that's that's literally all it means all right um so how does that translate into what we're doing and how we're doing this with with machinery and stuff well first of all just a quick reminder digital signals are on and off on off on off on off one is on zero is off and in some cases the signal would be considered high or low meaning on and off and you may never have actually paid attention to it but if you ever look at something electrical you may have an on-off signal that looks like that and or an on/off button I'm sorry and what you may not realize is that that's a 1 and that's a zero and one and zero means on and off right okay so how does this work well let me see if I can put a pretty decent graph up here try to anyway okay so we'll do four okay now let's say that this is a 24 volt system and let's say that the computer is sending an output pulse we're going to do outputs here we'll do this as an output to illustrate what we're talking about all right well let's say then in a 24 volt system the computer is sending a 50% pulse okay my blue markers dying my daughter used it up my daughter is up I believe our our stand-in marker okay so I've got a 50% duty cycle on 50% and off 50% there you go okay which means we're dealing with approximately there all right that's it well what is 50% of 24 so at 50% the voltage average voltage is 12 volts remember said we're dealing with average voltage right so those look at Ohm's law 12 let's say we have a 24 ohm solenoid and a 24 volt system which is not unusual so 12 volts over 24 ohms means that at 50% duty cycle the current flow through the solenoid is going to be 0.5 amps okay that's I mean that's just--that's Ohm's law that's that's why you need to know Ohm's law you now let's say for the sake of argument that we decide to go to a seventy-five percent duty cycle because we either want to go faster or dig harder or whatever so now we're on it's at 75% well it's 75% the average voltage is 16 volts so now let's do this 16 year 18 18 volts damn damn it Jim I'm a doctor not a mathematician sorry 18 volts screwed up I just the number lit I do this in class on the number look wrong okay so let's do the math now 18 volts divided by 24 ohms which is Ohm's law we get 0.75 amps well what's changed well what's changed is our amperage which means the amp flow through the solenoid has increased or decreased and in doing so has changed the strength of the magnetic field and in changing the strength of the magnetic field we're changing the amount of hydraulic oil that's moving or whatever and that then becomes a proportional solenoid because this is a proportional output a little bit is a little bit and a lot of it is a lot of it and that's really all there is to it okay so I'm going to go get my pulse width modulated sender and my meter I'm going to hook it up to my battery and I'm going to actually show you how this works so you can read it and I'll show you some actual numbers and then hopefully at that point you'll have a much better understanding of what this is and won't be afraid of it because we're right back to day one in electrical class with Ohm's law right we're right back there so don't ever think you don't need it and even though I did the math here it's really more important to understand that volts and ohms make amps right so more volts is more amps more volts more amps and that's how the that's how the the mechanic uses Ohm's law to understand that relationship okay okay um now what I've got here this is Caterpillar and it's fairly standard cat pretty much makes every single pwm sensor the same this would be in a throttle or it would be in a hand stick controller and there's fundamentally electronic circuitry inside here it has an oscillator which oscillates the signal in this case that oscillates it I'm not actually sure to be honest with you my other one was 5000 Hertz I don't know what the frequency is on this one but we'll know in a minute so every particular system has a cycle alright so if you're reading a waveform for injectors or if you're reading an output for a for a controller of some kind or whatever okay fundamentally the system has to have a cycle and then in order for it to work the on and off has to be a percentage of that cycle so it's a percent on if you remember percent on and percent off alright well I wanted to point out that um it does affect voltage and this is your average voltage right so in this particular case we're down at about four tenths of a volt at low and then we're about five at high now that's why I have this one because it's it's broken it should be 0.5 and 4.5 but it's not alright so that's just typical but the bottom line is in a sensor the voltage doesn't matter this this number here is irrelevant okay because what we're really doing is time so if this is going to work the way up it will if I go to frequency notice I get five point six one eight kilohertz so this one is also roughly 5,000 Hertz okay it's important to understand that as I adjust this the frequency is going to change slightly just because it does because that's this the aberration but notice it only changes three or four Hertz out of roughly forty six hundred okay so that's that's the frequency alright now if if we did the math on it four thousand six hundred 20 cycles per second that we do four thousand six hundred and twenty make sure you can read that four thousand six hundred and twenty and then invert that and we get I was right ha I was right point zero zero zero - so the actual cycle is point zero zero zero two one six four five so that's two ten thousandth of a second for the cycle alright so this cycle here was 24 hours but the cycle in here is two ten thousandths of a second you so that means any of these on-off signals are going to be a percentage of point zero zero zero two which means if we're at 50 percent this system is only on four point zero zero zero one second so anytime you're dealing with injectors or anything where you deal with pulse width modulation or PWM or duty cycle okay the first thing is that the cycle is the length of time in seconds that the system is cycling it goes from basically goes in a circle those from here to here to here is the percentage duty cycle is the amount of that circle or cycle that the signal is on all right so now okay though couger all right that's all so now if I hit frequency again that puts me in two percent and if you notice it says percent right there okay so in the fully off or fully reduced position where it's six point five percent now I think it's going to go to o l1 oh I don't know the C some of these note there we go so notice as I increase it I'm not increasing voltage of increasing percent on time and this goes up to about 95 percent and then comes back down alright now if I did this right I've never done the math on this 0.382 volts at low you and 4.83 so let me do this here four point eight three minus point three eight two equals four point four four let's divide that in half and then add that back to 0.38 two you if I'm lucky I'm not always lucky but if I go to 50% and I get point to 8.26 or skip to point six oh six let me see how close I can get to point close if I did this right this should be at 50% yep about cycling yeah see that's why I had it's broken it was 50% a second ago there we go 50% yeah this one's broken any rate 49.9% average voltage so oh holy crap I got 50 straight up alright so that's how this works alright so terminology is important understanding language is important understanding physically mechanically what's happening is important and the reason we do this is because computers like turning things on and off but they do not like analog signals all right so an analog signal would look like at least a different color an analog signal would look like this okay an analog signal would look like this and computers don't like that that's that computers hate that that's very difficult that's a very difficult thing to make computers do at least you know relatively so if if we can avoid that and do this instead the system is going to work a lot better so if you have any questions of course you can email me let me know that's essentially all there is to it keep studying your you're smart enough to do this and I hope this helps so you guys be safe and stay confident you I'm back
Info
Channel: Daniel Sullivan
Views: 28,240
Rating: 4.9360566 out of 5
Keywords: sullivan, power probe, power, probe, training, electrical, relay, fet, pulse, width, modulation, pulse width, pulse width modulation
Id: 5VGh1g2ovA8
Channel Id: undefined
Length: 24min 54sec (1494 seconds)
Published: Sun Apr 17 2016
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.