[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

I have a little question for my term project. They've asked

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 35
Thread images: 7

File: FU011AZGYGF8IV4.MEDIUM.jpg (82KB, 480x320px) Image search: [Google]
FU011AZGYGF8IV4.MEDIUM.jpg
82KB, 480x320px
I have a little question for my term project. They've asked of us to make a kind of analog air conditioner. We have to design a temperature adjustment unit which uses duty cycles of a square wave. %0 duty cycle is -50C, %50 is 0C, and %100 is 50C etc. Question is, how can I convert this duty cycle percentage to a proper dc voltage which I can compare with a sensor's voltage output? We can only use op-amps, resistors, transistors, diodes, capacitors, inductors, and a dc power supply. All help is appreciated.
>>
>analog air conditioner
What. Why? This is certainly an exercise in analog controls but the reasoning is a little baffling, anyone could do this with a microcontroller in a day.

It'd be nice if you gave us a proper diagram of what you THINK it should look like, at least at the block diagram level. I'd start with that.

As best I can tell right now, you need to design something that will read in an analog voltage from a sensor, and convert this into a PWM output of some duty cycle? Sounds like it will be a number of comparators that output to a square wave generating circuit
>>
>>1093931
why use a microcontroller when you only need a sawtooth wave and a comparator?
>>
>>1093938
Because analog components are more sensitive to temperature change and aging for one. And even as simple as this circuit is the PID tuning of a microcontroller control system rather than an analog PID would be much simpler. Take a little less knowledge and time to setup a microcontroller than an analog control circuit with feedback
>>
>>1093931
>What. Why?
Because homework.

>>1093926
You can probably assume the low and high levels of the input signal are fixed, for example 0V and 5V. You could filter it to get a DC voltage in range 0 (-50C) to 5V (+50C).
>>
>>1093926
Convert the PWM input duty cycle to an analog voltage with a low pass filter. This is how PWM DACs work. Use a comparator to compare that to the analog voltage from the temperature sensor. Op-amp can be used as a comparator if you don't have one.
>>
>>1093931
Well they need not give us a reason. That's how school works.

You got the concept the wrong way. The sensor is for ambient temperature and the system is supposed to stay at a set temperature. The adjustment unit is for setting said temperature. For the adjustment unit I have a square wave generator which I can control the duty cycle by using a POT. That may be retarded but that's what they ask of us. I want to convert the duty cycle of that wave to a corresponding voltage. Then I will compare it with the voltage from the sensor.
>>
>>1093969
Can you explain to me how that low pass filter works? I saw that solution in some arduino sites, but as we haven't used it in the course, I don't know how it works and to use it in the project I have to explain how it works.

I will most probably do the comparing part with a difference amplifier, because as a bonus we can do a speed control, i.e. if the temperature I want is 20 degrees more, the system will work more than if it is 5 degrees more than the ambient temperature.
>>
File: feedbackloop.jpg (24KB, 632x230px) Image search: [Google]
feedbackloop.jpg
24KB, 632x230px
>>1093973
I well understand what you're designing and how it is supposed to work. I don't know why they would throw a problem like this at someone who doesn't (seem) to have a priori controls knowledge unless your actual requirements aren't that stringent, it may end up being more of a bang bang control system. Did they specify anything like steady state accuracy or rise/fall time?
What is the plant? a fan of some sort?
>>
File: dac_high.jpg (38KB, 426x173px) Image search: [Google]
dac_high.jpg
38KB, 426x173px
>>1093977
> >>1093969
Can you explain to me how that low pass filter works?

If you've got a 5v 50% duty cycle PWM input the voltage of the capacitor will go to 2.5v. Capacitor can't change state quickly because the resistor limits how much it charges and discharges with the PWM highs and lows.
>>
File: 1.png (36KB, 680x202px) Image search: [Google]
1.png
36KB, 680x202px
>>1093989
Yep, this is for a basic electrical circuits lab, so no controls knowledge. They specifically asked of us to make an adjustment unit using a square wave's duty cycle. There will be a heater (stone resistor), and a cooler (a computer case fan) and a control unit will decide on whether to power cooler or heater using that and sensor data.
>>
>>1093990
Thanks, but what I meant was a more theoretical explanation. A circuit analysis or formulas that kind of stuff. If you can suggest some reading material, that would be great too.
>>
>>1093995
Okay so the you're designing the temperature adjustment unit and the control unit is already there?

Temperature adjustment unit just takes in a square wave and based on duty cycle will output a voltage level that will be used as a temperature input to the control unit or the compensator as indicated on my diagram. Is this correct?
>>
>>1093998
No, I will design the whole thing. Square wave is also in the temperature adjustment unit but doesn't matter, and yes the other ones are correct. Also the "steady state accuracy" is 2 degrees Celcius.
>>
>>1094008
Pretty demanding for a basic circuits lab
>>
>>1094010
Life is hard around here.
>>
>>1094011
Where? just out of curiosity
>>
>>1094012
METU in Turkey.
>>
>>1094018
Hahahaha kardeşim kolay gelsin. Bizde de saçma sapan şeyler istemişlerdi.

In my time, they didn't even allow us using transistors. I mean, we would always use OpAmps for simplicity anyways.

As your question goes, you should know that if you observe PWM waves, the mean value (the DC value) is Volts * Duty_cycle_percantage. As other anons have said, a simple RC circuit as a low-pass filter should be used. When the signal is HIGH, the voltage of the capacitor will increase w.r.t. it's time constant. When it is off, the cap will discharge. There will be ripples in the capacitor voltage, but it will be around the mean value. It seems like you have figured out the rest (using comparator to turn on/off).

Also, you can check the lab manuals of ee214. The first 1-2 labs deal with getting DC from AC which is close to your problem.

Arco'da cevaplarını bulabilirsin. Sizin dönem öğrendi mi bu kaynağın varlığını bilmiyorum ama, güzel bir derleme bıraktık sizlere :)
>>
>>1094055
Bakayım 214'e sağolasın. Arco dediğin şuysa evet biliyorum. https://mega nz/#F!j9txABrL!n_9chH6zZCTYiegE8hLsPA
>>
>>1093938
>simpler circuit
>cheaper components
>easier to make ir work
>less sensisitve to ambient factors
>>
>>1093926
>how can I convert this duty cycle percentage to a proper dc voltage which I can compare with a sensor's voltage output?

op amp adder followed by large-ish cap with high-ish drain, feed that into your comparator
>>
>>1095688

forget the adder, you just need a diode.

damn, optical computing messes with your head
>>
>>1093926
low pass filter
>>
My take on the duty cycle vs voltage on cap is the following:

Say you have a 0V-10V PWM signal at 50% duty cycle.
As you power up the circuit, the capacitor is completely discharged but starts to charge when the input goes high, it also discharges a bit when the input goes low. Now: the charge/discharge rate is dependent on the current when charging/discharging, which is dependent on the voltage across the resistor, which happens to be 10V-Vcap at 50% of the time (charging) and only Vcap at the other 50% (discharge). At first you have the voltage on the cap very low, therefore it will charge faster than it discharges and will keep doing so until it reaches 5V (50% of 10V), which is the point of equilibrium when the charge and discharge rates are equal (because 10V-5V == 5V). Different duty cycles achieve different points of equilibrium, but the reasoning is practically the same (plus, you also have to consider the time difference).
Increasing the resistance or capacitance will reduce the ripple but it will also slow down the charging/discharging process and the time necessary for the circuit to reach equilibrium. Obviously, the PWN frequency also has quite an effect on the ripple.
>>
File: To sensor .jpg (190KB, 1403x1008px) Image search: [Google]
To sensor .jpg
190KB, 1403x1008px
>>1093926
So, you want to take an NTC sensor, linearization of T1, T2-central-, T3, and get an output Vo?
I'd take a course on Practical Instrumentation, but that's the circuit you could follow.

One simple method of linearization is to use a resistance R parallel to the Rt sensor.
The value of R is basically R= ( Rt2(Rt1+Rt3) -2Rt1Rt3 ) / (Rt1 + Rt3 - 2Rt2)

where Rtx is the resistance of the NTC at that Tº (check data sheet).

You'll also have to set the values of R1 and Ra/Rb to get your expected Vo.
>>
>>1096760
Sounds more like that PWM thingy is supposed to be his sensor, so no linearization needed.
>>
>>1093926
Holy shit why the fuck is that switch even in the system

So fucking stupid
>>
>>1096856
It's not stupid.

You frequently use 10ks to ground for configuring chips and whatnot. The switch effectively bridges the resistor from pin directly to ground.
>>
>>1096856

DIP switches only have two pins each, dingus. You HAVE to have a pullup/pulldown resistor, otherwise the pin just floats when the switch is open. This is one of the first things you ever learn in digital electronics (or even regular electronics, for that matter).

Actually, it looks like you're pointing out it's not connected to anything, according to your diagram.

...except it is, if you actually bother to pay attention.
>>
>>1093990
Typically with arduino, you would use a RC LPF with 1kΩ and 10μF to properly filter the output. I suggest you get a 1kΩ pot and monitor your output on the scope to fully understand the filter effect.
>>
>>1095617
>doesn't need to actually understand electronics to operate
>basically just next level lego
>the cancer of electronics studies
>>
File: 1480873230852.jpg (38KB, 480x320px) Image search: [Google]
1480873230852.jpg
38KB, 480x320px
look this ;)
>>
Full schematic:
http://www.ecs.umass.edu/ece/m5/tutorials/parallel_serial_shift_register.html

He should have at least reverse image searched before overreacting.
>>
>>1096765
Well man, you should have mentioned that you're already getting the linearized voltage temperature input, because that's the hard working calculation of that project. Just calculate the other resistances.
Thread posts: 35
Thread images: 7


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.