Are micro controllers a help or hindrance to learning electronics? - Page 1
Forum section: electronics / general

author: gb243
author_rank: Contributor
timestamp: November 29, 2016, 07:00:38 am
content: Everyone must start somewhere but I do feel concern that given a problem so many automatically reach for a micro controller for a solution. What do they learn in the process? You want to blink an LED. OK, well: -1. Use an Arduino.2. Use only an analogue IC3. Use two transistors.4. Use only one transistor.5. Use only an LED with no active or passive components.Using google number 4 is out there but easy to find. Number 5 can probably still be found in use in several homes. Personally, I feel this is a way to extend knowledge and pick up a range of physics and electronic concepts. Am I being reasonable or just a grumbling old fart (which I am anyway)?

author: ataradov
author_rank: Super Contributor
timestamp: November 29, 2016, 07:16:48 am
content: They learn a useful skill (programming). It does not matter if you can blink an LED with a single transistor if no one actually needs this. Sure, there are some jobs that will require purely analog solution, or some deep RF black magic, but most things in the hardware world right now are about programming. No matter if you like it or not.Also, in many cases it is cheaper to put a micro than to figure out analog solution.PS: I've seen similar grumblings from people making digital clocks. "I can make a clock that uses only 74xx logic, and all those kids just put a way overpowered micro and call it 'electronics'". Nevermind that a dozen 74xx ICs cost like 5 of those overpovered MCUs and the clock does not have nearly as many functions.

author: gb243
author_rank: Contributor
timestamp: November 29, 2016, 07:36:01 am
content: I am not anti digital. It is an analogue world out there. Only knowing how to write C programs can mean that as soon as you have to interface with anything real you hit an intellectual brick wall. Impedance, velocity factor, transmission line theory, electro magnetics, op amps etc. are just a few words that describe a deep field of knowledge essential for an engineer.A single transistor oscillator may not be a practical solution but knowing how it works at the circuit and atomic scale is knowledge that can be applied elsewhere. A product is almost never just an arduino. It may have a controller but there will be analogue sections. Probably several hundred million Chinese children can program in C. That offers no advantage in the real world.

author: ataradov
author_rank: Super Contributor
timestamp: November 29, 2016, 07:40:58 am
content: Quote from: gb243 on November 29, 2016, 07:36:01 amAnd I'm not anti-analog. Picking up typical analog issues that software person will face in a typical MCU applications (impedance mismatch and all that stuff), is way easier than picking up programming for an analog person.Now, if you actually do hardware design as a job, then balance shifts the other way - you do need to know a lot of analog stuff, and some marginal programming just to know what programmers expect.And if you do both things professionally, then you are doing something wrong. Unless you are a solo full-cycle consultant.

author: Berni
author_rank: Super Contributor
timestamp: November 29, 2016, 08:14:12 am
content: Well depends on what you do with it. If you buy an arduino and a LCD shield to plug in to it so you can draw pretty stuff on it means you learned absolutely nothing about electronics, but you did probably learn quite a bit about programming.This is not inherently a bad thing. Not everyone is interested in electronics but might be in to programing. But as soon as they hook up something as simple as a switch to an arduino they will learn about pullups and pulldowns and such.While most non electronics people that buy an arduino don't get far past blinking a LED, but a small percentage of them might pick up a soldering iron for the first time that otherwise wouldn't.At the end of the day one has to have enough interest to get anywhere.

author: imidis
author_rank: Frequent Contributor
timestamp: November 29, 2016, 08:25:53 am
content: I think it depends on the person I think. I'm more interested in the hardware side of things, I've had some of the basics for a while, but didn't go too much beyond component repairs (bad capacitors, inverters, things like that). I have learned a bit messing around with an arduino, if you need to power something higher than 40mA you learn quickly about transistors. And yeah, pulling high or low, even for i2c addresses. And I think daves right, you learn the most when things go wrong.But it just depends on the person and what they want to do.

author: AndyC_772
author_rank: Super Contributor
timestamp: November 29, 2016, 08:40:07 am
content: Don't forget, a microcontrolleristhe way to solve many problems that might have been solved using discrete parts 20 years ago. Learning to use oneislearning electronics.A microcontroller != a 'duino (of whatever flavour). The range of microcontrollers out there far, far exceeds the number which have been conveniently mounted onto a PCB and wrapped up in a step-by-step UI, and so does the range of problems which can be correctly solved using one. Please, don't confuse the two; I strongly recommend graduating from and becoming independent of the whole 'duino way of thinking at the earliest possible opportunity.Let me give a real example. Not so long ago I was designing a board which was exceptionally tight for space, and which needed to deliver a couple of digital outputs given some analogue inputs.The 'discrete' way of doing it would have needed comparators, half a dozen discrete resistors, some D-type latches and a handful of other logic gates. The 'old-school' would no doubt have nodded in approval of a design using these simple building blocks.Today, though, it's just a bad solution in every measurable way.A much better solution was an off-the-shelf microcontroller; a single chip containing the comparators, a DAC to set their threshold, and even some configurable 'hard' logic to process the digital signals independently of the CPU core. One chip, nine square millimetres, and the same cost as the comparator would have been on its own.

author: Rerouter
author_rank: Super Contributor
timestamp: November 29, 2016, 09:06:48 am
content: Generally its when you run into the limitations of the micro controller you prefer that you learn the most about the many other fields of electronics.

author: tszaboo
author_rank: Super Contributor
timestamp: November 29, 2016, 09:19:12 am
content: Quote from: Rerouter on November 29, 2016, 09:06:48 amYes. The issue with microcontrollers, is simple. If you only have a hammer, everything is a nail. It is not the only solution for all problems, but since it requires less thinking, people go that way. I very much like to solve problems with logic chips or ASICs. Because you solder it together and it works. And you dont need to worry about bootloaders, compilers, board support packages. i would replace a micro with a comparable ASIC every time, because when I did that, it is someone else's problem. Yet, 90% of the projects I do contain a microcontroller. It is when you say "I need a second microcontroller" that is when you are supposed to think.

author: jonovid
author_rank: Super Contributor
timestamp: November 29, 2016, 10:15:25 am
content: Quotemy Answer is use two transistors.electronics is like a library.you can read the whole book.read one or two chapters in the bookor read just one page.but few have ever read the whole library on electronics.why we have forums & google, to help .Arduino is like the commodore 64 was back in the 80sIMO transistors then move to 555 ic's before Arduino

author: @rt
author_rank: Super Contributor
timestamp: November 29, 2016, 11:42:20 am
content: Programming has plenty of merit on it’s own,but I don’t allow anyone around me to confuse plugging some boards together with electronics, or “making”.There are Youtube videos out there titled “Project bla bla”, and “Biuld log of bla blah” that are simply plugging boards together.They should just call that programming and be due proper merit.Now if you’re going to use a bunch of logic to solve a problem in the digital domain that could have been solved with a much cheaper micro,well that’s plain dumb, unless you were actually making a point of doing that, or not already proficient with programming,and the project wasn’t worth the learning curve.Admittedly, if I wanted to flash an LED I’d go for a 555, but I’d also have nothing to learn by making a transistor flip flop.

author: jonovid
author_rank: Super Contributor
timestamp: November 29, 2016, 12:25:17 pm
content: Quoteif I have a goal to make a unit do a job, then I will look at plugging some boards together off the shelf, so it saves time & money.howeverlearning electronicsso you can design from scratch is another matter entirely. learning is IMO slow and time consuming.but the reward is worth the effort in the long run IF your still young..

author: CJay
author_rank: Super Contributor
timestamp: November 29, 2016, 12:30:27 pm
content: They're one gateway to learning electronics, there are plenty of routes to analogue through microcontrollers.Coding is becoming a very necessary skill these days, as others have noted, it can be trivial to achieve results with a micro that would take many dozens of jellybean chips so why not use them, the electronics skill comes in integrating the micro into a larger system which has control or input from other devices which will also need electronics skills to implement.

author: rstofer
author_rank: Super Contributor
timestamp: November 29, 2016, 03:41:28 pm
content: Feature creep!It is seldom interesting to just blink an LED. Sooner or later there will be a switch to change the pulse rate. Then there will be an analog pot to linearly change the pulse rate. Then then will be an LCD to display the % of on-time so intensity versus on-time can be computed. And so on...I haven't used a 555 in 30 or 40 years and will probably never use one again. That's just the way it is in my little corner of the electronics sandbox. Clearly, others use the chip much more often. That's ok, it's a pretty big sandbox. There's room for everybody!Interesting projects have a UI of some kind. Often it is easier to implement the UI with a uC.

author: jonovid
author_rank: Super Contributor
timestamp: November 29, 2016, 07:45:25 pm
content: QuoteCoding is a very necessary skill in video games too. like the development of the nextFlappy Bird.the dividing line between the amateur and the professional in field of computer science & also electronics.as a hobbyist its the one thing I did poorly at, when I was in school. advanced Mathematics! or Maths!

author: mrpackethead
author_rank: Super Contributor
timestamp: November 29, 2016, 08:05:34 pm
content: digital is just a special case of analogue anyway.

author: SL4P
author_rank: Super Contributor
timestamp: November 30, 2016, 08:48:09 am
content: This is quite a good question - based on what I see on the Arduino forum...There are an incredible number of newbies that buy a uC board, some shields and expect it toassemble itselfinto a completed working project, then realise they have no idea how to select a power source, connect a switch and LED - then are totally confused by blocking code (e.g. delay).Writing code is the last skill they learn, closely followed by hardware and writing code.One can't exist without the other.

author: CJay
author_rank: Super Contributor
timestamp: November 30, 2016, 11:09:38 am
content: It is a good question, but how many of them give up entirely and learn nothing compared to the number who persevere and learn, either enough to achieve what they set out to do or get hooked and continue to learn?I'm happy with anything that helps people learn more, seems rather churlish of some people to sneer at others because they use a microcontroller to accomplish things they'd do with two transistors.All worthwhile in my opinion.

author: JPortici
author_rank: Super Contributor
timestamp: November 30, 2016, 12:03:28 pm
content: i had to make a led strip thingie for a publicity panel recently. i could have gone analog but instead i decide to put a microcontroller and control the whole thing via pwm. Because i anticipated the question that would follow, if i was able to make it do some animations.. and everything was already there. a few more lines of code andvoilaanalog, digital, depends on the application. it's better to know more ways to do one thing, one solution will never always be the best one.but one has to start somewhere and then move on. At school i started with both, high level programming and then more and more low level while on the hardware side i started from the bottom. I won't say it's the best way.. but it worked very well with me

author: idpromnut
author_rank: Unknown
timestamp: November 30, 2016, 12:23:11 pm
content: Quote from: gb243 on November 29, 2016, 07:00:38 amI am quite the newbie when it comes to electronics, so this solution possibility intrigued me. I had a look on the google, and found a few posts saying that this could not be done. Can you give me a hint on how to do this?

author: MK14
author_rank: Super Contributor
timestamp: November 30, 2016, 12:52:21 pm
content: Quote from: idpromnut on November 30, 2016, 12:23:11 pmYou can get LEDs with built in flash ICs. So you just connect them up to power, and they flash automatically.Example:http://uk.farnell.com/kingbright/l-56bhd/led-blinking-5mm-bright-red/dp/1142543

author: BravoV
author_rank: Super Contributor
timestamp: November 30, 2016, 01:02:12 pm
content: Quote from: gb243 on November 29, 2016, 07:00:38 amMaybe ..... j/kFacts about availability especially for hobbyist and it's eras ...1. Use an Arduino. (or mcu)Not very sure about time frame, maybe before the 90's ? MCUs basically was out of reach for ordinary hobbyist before that time frame.2. Use only an analogue ICMaybe in 70s ?3. Use two transistors.Maybe in late 60s as transistor became cheaper ?4. Use only one transistor.Mid 60s maybe, as transition from tube and transistor still expensive ?5. Use only an LED with no active or passive components.Not sure about this.My opinion, yes, it helps, not as a hindrance as technology evolves, and mcu actually is a new method (not all though) of getting thing done and working, especially just to blink a led.

author: mc172
author_rank: Frequent Contributor
timestamp: November 30, 2016, 02:36:10 pm
content: You can make an LED flash with no external components by turning the power on and off manually.

author: Ducttape
author_rank: Regular Contributor
timestamp: November 30, 2016, 03:44:04 pm
content: Quote from: mc172 on November 30, 2016, 02:36:10 pmYou've now become an external component.

author: idpromnut
author_rank: Unknown
timestamp: November 30, 2016, 04:45:39 pm
content: Quote from: MK14 on November 30, 2016, 12:52:21 pmI was aware of these, but I had assumed that was "cheating" in the context of the original poster

author: rstofer
author_rank: Super Contributor
timestamp: November 30, 2016, 05:16:07 pm
content: The divide between 'electronics' and 'computer science' is blurred when computer science is taught in the department of Electrical Engineering and many universities have it set up this way.'Learning electronics' is also a poor term when you consider just what you have to know to be considered an electronics engineer (or designer). Not too many hobbyists get into Laplace Transforms yet that level of math is an absolute requirement for engineering. Maxwell's Equations? Boy, I had a tough time with that class! Fourier Analysis? I used FFT for a real application just once in a 30+ year career in electrical engineering. But the results were cool! Charts and graphs and all that stuff!So, what do we mean when we discuss 'learning electronics'? Ohm's law and a handfull of resistors? Audio amps? Transistor biasing? Analog computing? Breadboarding a 2 transistor flop designed by others? How about FPGAs and CPLDs, they must count as hardware, thus electronics. And yet, it takes a bit of coding skill to get them to implement much of anything. Nobody would build an FSM out of flops and gates when they could just code it into a CPLD.I guess my definition of electronics has gotten pretty expansive. I include everything except power substations. Building lighting and environmental is centrally managed by a computer talking to boxes full of electronics. Web pages monitoring and controlling energy use. RS-485 networks all over the plant. Manufacturing automation...The microcontroller is just a jelly bean chip like everything else.

author: MK14
author_rank: Super Contributor
timestamp: November 30, 2016, 05:27:50 pm
content: Quote from: idpromnut on November 30, 2016, 04:45:39 pmYou might be right. It depends on if the no-actives only applies to external components, or if it applies, even if it is part of the LED.tl;drIs a self blinking/flashing LED, still counted as a normal LED ?

author: CJay
author_rank: Super Contributor
timestamp: November 30, 2016, 06:44:26 pm
content: Quote from: MK14 on November 30, 2016, 05:27:50 pmI wouldn't say it was but who knows, it's a single component in the way a hybrid is.However, I can make an LED flash once...

author: CraigHB
author_rank: Regular Contributor
timestamp: November 30, 2016, 07:36:18 pm
content: Quote from: rstofer on November 30, 2016, 05:16:07 pmMe too, RF stuff is the least interesting for me, but it's pretty much an essential aspect of most electronic devices now. These days things like wifi and bluetooth are incorporated using single chip solutions so there's not a huge amount of engineering involved at the system level, which is fine with me.

author: MK14
author_rank: Super Contributor
timestamp: November 30, 2016, 07:41:22 pm
content: Quote from: CJay on November 30, 2016, 06:44:26 pmI can do a lot better than that. As long as it is battery powered, I can configure it, so it flashes, exactlyonce, every time the batteries are changed or if mains powered, it flashes once, every time it is switched on and off, at the mains.Alternatively, assemble the connections to the LED, in a very weak/poor fashion. Then it will flash every time someone coughs, the wind changes direction or a car drives past where you are.

author: free_electron
author_rank: Super Contributor
timestamp: November 30, 2016, 07:42:03 pm
content: Microcontrollers are not electronics.They are an electronic COMPONENT. knowing how to write code for one doesn't teach you ohm's law or how to calculate a bias resistor...nevertheless, they are very useful as aaprt of an electronics system.

author: hamster_nz
author_rank: Super Contributor
timestamp: November 30, 2016, 07:46:46 pm
content: Quote from: idpromnut on November 30, 2016, 12:23:11 pmWhen I hook up my LED direct to the battery, it blinks, but only once.It also starts to smell funny....

author: rstofer
author_rank: Super Contributor
timestamp: November 30, 2016, 08:07:42 pm
content: Quote from: free_electron on November 30, 2016, 07:42:03 pmOf course they are! Ignoring the code wienie work, uCs have a datasheet. Sometimes it is several hundred pages describing in too little detail how the internals work. Sure, the diagrams are more complicated than those for a 7400 or an LED but they still try to tell a story. Look at the AC and DC Characteristics of a uC and tell me it isn't electronics!uCs have input and output characteristics, just like any other electronic component. The output pins will source or sink a certain amount of current to a specific voltage level. The inputs have switching thresholds that need to be met. The A/D converters place an output impedance constraint on the driving signal. Sometimes the application will require a voltage follower to provide enough driving current. Sometimes there is a need to do a bit of offset and scale with op amps before stuffing the signal into the A/D. Maybe a little filtering... Single supply vs dual supply, rail-to-rail versus older technology.It's one thing to take an Arduino and add a little code and an LED. That's no more 'electronics' than using a 555 to blink the LED. And no less... Either way, the current limiting resistor needs to be calculated from Ohm's Law. If you count an 8 pin 555 and LED as electronics, you have to include an 8 pin uC and LED as electronics. In any case, the timing components of the 555 will be calculated from a Web app located by Google. Nobody does that nonsense any more. The LED code will probably also be located via Google.It's quite another thing to apply a uC to a bareboard project. There's a heck of a lot of 'electronics' in doing something like that! Things like the power supply, decoupling capacitors, current limiting resistors, crystals and their load capacitors. All that stuff is electronics. Most of it will involve Ohm's Law and perhaps a good deal more. How about adding some USB serial capability (FTDI, et al)? Maybe a Compact Flash for the disk subsystem...Most every project that can be built, has been built. All of human knowledge is available on Google so most projects are really just a lot of copy/paste.

author: JPortici
author_rank: Super Contributor
timestamp: December 01, 2016, 07:18:53 am
content: Quote from: free_electron on November 30, 2016, 07:42:03 pmbut in the moment you look away from the monitor to the real world and say "now what do i do with this thing?" it has become electronics, need to know stuff.

author: CraigHB
author_rank: Regular Contributor
timestamp: December 01, 2016, 03:49:52 pm
content: I think if you design a PCB, install a controller, then code it that's electronics right there. OTOH, just plugging a duino board into a USB port is not, that's only programming.In any case it's pretty hard to isolate circuit design from programming, they're so intertwined with such high level components available now. There was a time when you had to do things with discrete components, any kind of computing device required a boatload of them. Even then there's still the programming aspect. You needed memory and something to execute the code stored in that memory.The difference is that designing electronics at the system level is done at a much higher level now with such heavily integrated components like MCUs and ASICs. It's almost more like assembling Legos than designing circuits. Still it's good that way and rewarding to do projects even if you're just basically connecting chips. Now if you happen to be designing chips themselves that's electronics purely at the circuit design level, but your average hobbyist and even most design engineers are not going to be doing that. There's a lot that do though, someone has to design those things.

author: technix
author_rank: Super Contributor
timestamp: December 02, 2016, 08:03:37 am
content: Quote from: CraigHB on December 01, 2016, 03:49:52 pmEven if you are designing chips most of the time you are connecting LEGOs in the form of IP cores. Not too different from designing a board using chips, just this time all chips are HDL entities instead of physical objects. Only those dealing with writing IP cores themselves are exposed to raw electronics design, and then the HDLs are more often than not modeled after programming languages...

author: AndyC_772
author_rank: Super Contributor
timestamp: December 02, 2016, 08:39:17 am
content: Quote from: technix on December 02, 2016, 08:03:37 am...followed, I presume, by a long and detailed programme of timing analysis and formal verification of the device's function, which actually forms the bulk of the IC design process?I can't say it's ever appealed - to the extent that I turned down a job at ARM back in '97 or thereabouts.

author: technix
author_rank: Super Contributor
timestamp: December 02, 2016, 10:48:21 am
content: Quote from: AndyC_772 on December 02, 2016, 08:39:17 amI am new to this thing (really) but some of my instructors used to complain that designers now have the easy jobs of simply slapping IP cores together, and the resulting chip will almost guaranteed to work.I do know that there are quite a bit of IP cores out there that is self contained, with timing already guaranteed by its internal design.

author: CraigHB
author_rank: Regular Contributor
timestamp: December 02, 2016, 05:38:04 pm
content: It's interesting that electronics has become more akin to an assembly of building blocks even at the chip design level. There was a time where any electronic product came from a circuit design drawn up with elemental components, but that's technology moving ahead. Even so it's still worthwhile to learn that stuff just to understand what things are doing under the hood.

author: Berni
author_rank: Super Contributor
timestamp: December 05, 2016, 06:50:58 am
content: Thing is that working with known to work lego blocks makes your job easier and faster. At where i work DC/DC converter PCB layouts are simply copy pasted from the first PCB that used that chip. Saves lots of time and datasheet reading when you just think of it as 6 to 36V goes in to this box and 5V at 3A comes out.As for making digital ASICs you are still quite far from the transistor level. HDL is about as close to bare metal as something like C++ is. You tell it what you want it to do in code and then the compiler first looks at what is the simplest logic behavior that acts like this block you wrote. Once the compiler understands what you want it to do in its "internal raw logic language" then it tries to replicate it using logic gates or in the case of gate array ASIC or FPGA it looks at how the logic blocks in it could be cobbled together to get the behavior. Then it also does the equivalent of "-O2" in C where it looks at timings, clock skew, net fanouts... etc inserting extra logic or rearranging the logic in a mysterious ways to make it run faster. So yeah the end result is sort of the compilers "artistic vision" of your HDL idea.Something close to what you would call "bare metal" electronics is the Fluke 410B high voltage PSU i just repaired. There is not a single IC to be found in it. Regulation loop is done using a discrete BJT opamp implementation and the output is driven by a giant tube (transistors don't handle 10kV too well). The tubes warmup delay is even done using a bimetal delay relay. Whole schematic of it fits on a A4 sheet. But one could still break it down in to blocks.