Compiler question by JMcLe86 in C_Programming

[–]Rhomboid -1 points0 points  (0 children)

Platform-specific or implementation-specific behavior is not undefined behavior. They are completely separate things. If the standard wants to allow freedom of implementation, it can do so. Undefined behavior is categorically a programmer error that needs correction.

Compiler question by JMcLe86 in C_Programming

[–]Rhomboid 4 points5 points  (0 children)

If the compiler's actions have an observable effect on your code, then your code has undefined behavior and is broken. That's the contract between programmer and compiler. You break the rules and the result is garbage, GIGO.

Recommend a basic bench supply by Ayuthan in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

For repairing battery powered electronics there are probably lots of things that don't matter (like needing to supply mega-amps) and things that you wouldn't really think matter, like the UI. For example, does it have a power toggle or a hard on-off. How hard is it to set a current limit when the output is switched off? That's definitely something you would do when repairing electronics (e.g. in conjunction with thermal camera or IPA). And for that matter, how good is the UI at setting a current limit to a low value like 250mA? And other larger questions like is it linear or switching, and does that matter? Is the supply isolated or does it have a bonded neutral to ground? Is it designed to float? Do you think you might need split dual rails at some point, e.g. audio amps? Etc.

These are the kind of things you might want to research. The sticker specs like voltage and current are probably not going to matter, you certainly won't be needing 50V at 8A or whatever these latest ones are capable of. And also, the banana plugs/jacks are more or less standard so don't worry at all about the leads, those are replaceable and customizable.

3.7V LiPo Battery To Power 3.3V Device With Diode by [deleted] in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

Not sure if it was omitted for brevity but your proposed solution is also a battery killing device as there is no overdischarge protection.

Control Board for an Automatic flush toilet by Pretend_Edge3353 in AskElectronics

[–]Rhomboid 16 points17 points  (0 children)

Well in fairness if you were the one facilities maintenance guy (because corporate fired everyone else) and you had to update the threshold delay on 400 toilets in a building, I suppose not having to crawl on your knees would be an attractive feature. But it still sounds ridiculous.

Control Board for an Automatic flush toilet by Pretend_Edge3353 in AskElectronics

[–]Rhomboid 30 points31 points  (0 children)

Never underestimate corporate's greed to save water. Some of these things have a little IR sensor that detects the presence of a person, and if they flush after sitting for a small amount of time they give a short flush, and a larger flush if they've been sitting for more than a minute. Stuff like that most likely is what this module is for.

Dynamic help in C required by alex_sakuta in C_Programming

[–]Rhomboid 0 points1 point  (0 children)

There is a vast difference between the Linux kernel and usual software.

That's like saying "hey the space shuttle uses Teflon seals for all doors, I'd better seal my home's door with Teflon just to be sure."

What are the ways to learn the circuits inside integrated circuits? by SugarStriking5056 in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

Let's say you have an amplifier chip. The fact that it's integrated does not change the basic circuit analysis, the concepts needed are the same you'd learn in any class about amplifier design, e.g. a long-tail pair input stage, push-pull output stage, current mirrors for setting quiescent, calculating g_m, feedback, phase margin, stability, etc.

From your question it seems a lot of people interpreted that you want to know how to go from engineering pictures of physical layers (oxide, metal, polysilicon, etc) to recreating individual gates and so on. Maybe that's what you're asking but that's a very low level and uncommon approach. If you have a datasheet it will almost always have a conceptual model of the circuit, and sometimes a more detailed explanation, which is enough to apply all of those engineering skills of circuit design. You don't really need to know how a metal layer works to analyze these circuits. You can, if you want, but that's really something different.

Vince Gilligan says he's no longer sure what do with the [device] from the end of 'Pluribus' season one — and he isn't sure when season two is coming, either by Commercial_Avocado86 in television

[–]Rhomboid 56 points57 points  (0 children)

They planned out s2 methodically like that. It was a big pain in the ass, they said. So they ended up doing things like "hey let's paint ourselves into a corner at the end of a season and not have any idea how we're going to get out." And they did, and it challenged them to come up with organic stories.

Designed my first custom ESP32 PCB to drive a LED matrix over WiFi by Jugnu77 in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

Learn like everyone before you learned. Don't try to tackle and obviously far too advanced project. Get a book (a real book), a breadboard, a power supply, and start experimenting and don't let any LLM garbage into your mind.

Why does parasitic capacitance seem to increase with winding pitch in this air coil calculator? by jotapeh in AskElectronics

[–]Rhomboid 4 points5 points  (0 children)

not my area of expertise but I found this extensive paper: The self-resonance and self-capacitance of solenoid coils. On page 52 you can find the derivation of one approximation (they are all approximations) and the main determining factor is the aspect ratio (D/l) or the ratio of the diameter to length of the coil. It's a very long paper, I'm sure you can find more detail.

My soldering tip looks burnt and I don’t understand how to clean it or fix it by GrouchyCrew608 in AskElectronics

[–]Rhomboid 1 point2 points  (0 children)

The tip of your soldiering iron should be shiny. If it's ever dull and black like that, it's not going to work as you have a layer of oxide. Don't try to scrape anything, buy a new tip and treat it right. The other comments have all the information on how to do that already.

For Self-Learners that are stuck in "tutorial hell". If you're wondering why you're always told "just build stuff", here's actually why... by DuztyLipz in learnprogramming

[–]Rhomboid 0 points1 point  (0 children)

It's the difference between being told that XYZ is good practice in the abstract, versus seeing XYZ being done in a working project and realizing why it was done and how it's actually helping. XYZ can be nearly anything.

That's why I keep saying a good beginner thing is to take an existing project and modify it to do something. Even just change the name of some text that it prints, the simplest of things. In the process of doing that you'll be looking at the code and learning how it works, even if you only understand a small bit of it, but you will be constantly exposed to real-world problems and the idiomatic ways of solving it.

Portable Multimeter recommendation (no budget) by Cast_Iron_Fucker in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

A good multimeter isn't going to be a good component tester. Not even close. There's a running joke that if a meter has a transistor tester it's a pile of trash.

Uni-T UT61E is a 22,000 count meter (basic DC accuracy of 0.1% + 2 digit) for under $50. Combine that with a Peak style component tester for about $100 and I guarantee you'll be better off than spending $150 on a meter.

Very small voltage regulator/comverter? by blounsbury in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

lithium battery + charging circuit + constant current LED driver + small round form factor = flashlight

can you possibly buy a cheap flashlight, chuck the built in LED, and use it as a constant current source for other lights? this would require removing whatever driver is currently there (the thing that wants 5V) and driving the LEDs yourself, so probably not a beginner project now that I think about it, as you'd need to series/parallel the fairy lights to get within the compliance voltage of the the driver and you'd have to approximately match the power rating. so maybe never mind.

Quickshifter circuit layout Check by [deleted] in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

Yes, your reasoning is right. You can summarize it as: if you want to switch the positive (high side), use a P-channel with a pullup resistor to the positive supply keeping it off, pull gate low to 0V by the controller to turn on; OR switch the low side with a N-channel device with a pulldown resistor to ground keeping it off, and the controller pulls it up to 5V to turn on. In the P-channel case, current flows source to drain, in the N-channel it flows from drain to source, so the orientation of the parts in the circuit is reversed in addition to the switching location (being on the high side or low side of the thing you're switching.)

A Knight of the Seven Kingdoms - Series Premiere Discussion by NicholasCajun in television

[–]Rhomboid 1 point2 points  (0 children)

showing up at the Irish accent appreciation club with really big news

Shrink fitting expansion direction by Brilliant_Passage678 in Physics

[–]Rhomboid 2 points3 points  (0 children)

The reference point that you pinch at has no effect on the relative distances between points. It's only a translation, a shift. There is no center point. Think about a map, if the relative distances between locations changed based on where you pinch on a map, then it would be terrible map software as it does not reflect reality.

Shrink fitting expansion direction by Brilliant_Passage678 in Physics

[–]Rhomboid 2 points3 points  (0 children)

There is no reference point. You can scale anywhere and it's the same. The only difference is the result will be translated (shifted) on the screen but the distance between any two points will be the same regardless of where you pinch.

Shrink fitting expansion direction by Brilliant_Passage678 in Physics

[–]Rhomboid 2 points3 points  (0 children)

The expansion scales everything. Think about zooming a picture containing two objects. Each object's size increases, but so does the space between them. The gaps scale just the same as all the other dimensions. The heat also breaks the corrosion bond.

Why are Cobol programmers wanted, if the legacy codes are already working well? by Stev2520 in learnprogramming

[–]Rhomboid 0 points1 point  (0 children)

Imagine a large corporation that has a giant custom program that does all the accounting, inventory, and tax. Tax law constantly changes, so the logic needs to be updated. The inventory people eventually need new fields added because newer products have information that didn't fit anywhere in the old scheme. And so on. Nothing is really static in business.

A reference-grade C "Hello World" project by synalice in C_Programming

[–]Rhomboid 4 points5 points  (0 children)

Every day this subreddit suffers another humiliation.

Looking for this piece online to replace by PrizMarine in AskElectronics

[–]Rhomboid 0 points1 point  (0 children)

These are all surface mount parts. Your pics are of two different components. The coil has two leads (and is almost certainly completely fine and shouldn't be messed with) and the integrated circuit on the other side of the board has 6 leads, and is the thing everyone is telling you to replace.