Didn't see a section to ask about basic electronicy stuff here. So not really sure where to ask this... As for me, I come from a software background, so some of the more subtle things with electronics elude me.
1 of 2: I think I get Ohm's law, but it doesn't seem to mesh with my experience -- which means something in my experience must be wrong.
2 of 2: I want to build something, and I want to build it right, so I want to learn this well, how would you build it, where can I learn more?
Okay here goes:
1.) In my experience, matching power adapters with things (like a Nintendo for instance) you want to get the voltage as close to possible, the polarity correct (if it outputs DC), and a current rating that's either equal or higher. I usually do this in electronics as well, get the voltage correct, and either don't worry about current, or make sure your source can put out enough of it that it's not a problem (i.e. more batteries in parallel).
However, recently, I'm looking closer at data sheets, solenoids, motors, etc... and I'm seeing maximum current ratings -- I'd always figured devices would just take the amount of current they wanted and leave the rest, not like voltage where if you go too high you're shoving it down the devices throat force feeding it, current it just takes as much as it wants and leaves the rest. But I keep coming across things that say stuff like "Don't run more than 40ma through this motor or it will ruin it", etc... or microcontroller data sheets which say stuff like "don't draw more than 100 ma current from port X or you will fry the chip", how can you try to draw more current from the chip than what it wants to give? The chip pushes the current out the pin, the device doesn't pull the current from the chip, does it?
2.) I want to build a couple of things with motors, mini DC brushed ones, and steppers, and maybe solenoids, etc... and I don't want to just go and buy the $50 "motor controller circuit board" or some random IC and be dependent on that -- I don't mind doing that for a project here or there, but I want to know how it works first -- I want to really "get it".
I think I understand Ohm's law... C(or "I") = V/R.
so if I run 5v over a 100 ohm resistor, I'm dissipating 50 ma (in heat?) across the resistor. So, if my source was putting out 50 ma too much, I could use this to shave off a bit, no? But isn't that bad for battery life? Also what if the next set of batteries puts out a different amount of current? Or what if I'm using a power adapter, and the user replaces it with one very similar, but a different current rating?
So I guess my question is, how do you do proper current limiting to a specific well known amount, with an unknown/variable current input?
And how do you step up current (say 1A, or even a lot more, like 10A) from an MCU pin (without a relay, obviously).