The Lounge is rated PG. If you're about to post something you wouldn't want your
kid sister to read then don't post it. No flame wars, no abusive conduct, no programming
questions and please don't post ads.
1. The lounge is for the CodeProject community to discuss things of interest to the community, and as a place for the whole community to participate. It is, first and foremost, a respectful meeting and discussion area for those wishing to discuss the life of a Software developer.
The #1 rule is: Be respectful of others, of the site, and of the community as a whole.
2. Technical discussions are welcome, but if you need specific programming question answered please use Quick Answers[^], or to discussion your programming problem in depth use the programming forums[^]. We encourage technical discussion, but this is a general discussion forum, not a programming Q&A forum. Posts will be moved or deleted if they fit better elsewhere.
4. No politics (including enviro-politics[^]), no sex, no religion. This is a community for software development. There are plenty of other sites that are far more appropriate for these discussions. Or if you must, use the Back Room[^] - but enter at your own risk.
5. Nothing Not Safe For Work, nothing you would not want your wife/husband, your girlfriend/boyfriend, your mother or your kid sister seeing on your screen. For those discussions where you wish to be a little more frank, use the Soapbox[^]
6. Any personal attacks, any spam, any advertising, any trolling, or any abuse of the rules will result in your account being removed.
7. Not everyone's first language is English. Be understanding.
Please respect the community and respect each other. We are of many cultures so remember that. Don't assume others understand you are joking, don't belittle anyone for taking offense or being thin skinned.
We are a community for software developers. Leave the egos at the door.
The jack-ace who made that site is a real card. And should be dealt with.
I'm pretty sure I would not like to live in a world in which I would never be offended.
I am absolutely certain I don't want to live in a world in which you would never be offended.
Freedom doesn't mean the absence of things you don't like.
Simple question: If you can build a circuit with discrete logic or simply program a cheap microcontroller and be done with it, what would you do?
Discrete logic costs next to nothing, but can very quickly hog up expensive space on your circuit board and complicate the board's layout, including problems with noise on the signals.
The microcontroller often comes in the same price category as the discrete logic chips it is supposed to replace. It's a single chip that has to be programmed to perform the function you want to have it for. It may solve the problem more elegantly than some bare bones logic could. Then again, a microcontroller with internal ROM and RAM and often diverse I/O ports seems a little wasteful for such a trivial job.
For example, I could build my interrupt control logic with discrete ICs or with a single microcontroller. The discrete logic would be simple. Interrupts that were not serviced by the time the signal becomes inactive are lost. There would be no masking and the priorities would be fixed.
The microcontroller could easily do such things, like buffering and holding interrupts until they have been acknowledged and serviced, masking interrupts or assigning different priorities.
Which way would you prefer? An 'object oriented' microcontroller where I just look at the interface and don't care how it does its job internally? Or better the minimalistic approach with discrete logic where everything is 'global'? Still, preparing a tiny computer on a chip for such a simple job seems extremely wasteful...
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
Definitely a microcontroller... The only downside of it can be the cost, but event there is no big difference... And of course there is the possibility of reprogramming the microcontroller with better code or even for an enterley different purpose...
"The greatest enemy of knowledge is not ignorance, it is the illusion of knowledge". Stephen Hawking, 1942- 2018
Depends on the speed required: uControllers get more expensive at a faster rate as speeds rise that discrete logic does.
But generetrally, I'd go the programmable route, as it's a lot easier to add features or even make the main software easier and more efficient.
I had one board with three PIC devices and a Z180: one PIC for the head control (to offload the actual serial data timing), one to interface with the LCD (after we found that the Z180 was far, far too quick for the display to cope), and one to auto-range the PSU and provide a self destruct if the software was tampered with.
Sent from my Amstrad PC 1640
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
I agree with OG, uControllers are easy to modify if requirements change and may have wasted functionality but at the prices WTH! Also better to have the extra functionality and not need it than to not have it and need it, should requirements change.
Everyone has a photographic memory; some just don't have film. Steven Wright
For me, the criterion would be can I possibly use the MC for anything else? If so then I would definitely go the MC route. If not then I would probably use the discrete logic. The exception would be if I really wanted another thing to program and I preferred that programming to wiring up a few more components. Only you can answer that.
The question isn't as philosophical. You named several practical aspects of the decision yourself and with practical aspects, it's not philisophical.
My personal choice would be an MCU. Nowadays, those things are cheap and you said yourself that this would be way more flexible. Plus, that's the way the big boys do it, less albeit more complex chip. On the other hand, if the setup is supposed to be (at least somewhat) educational, dicrete ICs are way superior as one can see what's connected to what (a shift register to a counter because of reason X) and an oscilloscope can be used to monitor the workings of the machine. With a programmed MCU, it's "signals go in, signals go out, here's the spec".
The problem solved by discrete logic, philosophically, is the successful amalgamation of various IO to one or more standard interface, to expand the capabilities of an existing system.
The problem solved by microcontrollers, again philosophically, is the successful amalgamation of various IO to create a standalone system.
So, it entirely depends on what you want.
If you want to use a set of radio's / sensors / mechanical parts as a standalone system, you should pick the microcontroller design.
if you want to use a set of radio's / sensors / mechanical parts as a single device in a larger overall scheme, you should pick the discrete logic design.
To be honest, I think most people default to microcontrollers, because they don't understand what they're doing.
Most IoT hardware I've seen, for example, combines microcontrollers and wireless chips.
Apart from the non-obvious stability issues arising from power-draw and overheating, it also introduces a huge attack surface for hackers and they are childishly easy to DDoS.
As a rule of thumb, I'd say:
- prototype it with microcontrollers if you want
- build it with discrete logic if you can
My machine (i7, 8GB Ram, SSD) began running slow a few minutes ago. I could hear the CPU fan running faster. something was going on, but I couldn't tell what. Checked running processes, nothing really eating up processor. Finally, after about 5 minutes this popped up:
Okay, so the Java Platform SE binary wants access through the firewall,right?
It's probably an update.
How would any non-tech user ever understand what to do in this case?
I barely know what this means and it all feels like nefarious activity.
These kind of error messages have to go away. All these advances in technology and yet we have error messages like this which require research to even understand how to deal with them.
All that work MS is doing on updates and stuff and they can't put one competent person in charge of error messages and making them understandable to users? Gaping hole!
Public v Private Networks
Also, look at that closely and you'll see that it looks like the thing already has access to public networks but now it wants access to private networks also, which seems very backwards and that whole explanation is confusing anyways. I'm sure few non-tech users even understand it.
Instead of just ranting I'll offer a solution
1. Microsoft could hash the javaw.exe and whatever else is running
2. Let the user know that, yes, the exe is actually a confirmed version of the thing but we cannot guarantee it or what it does is safe, but it is likely safe.
3. Provide an interface for software which will be updating to provide a message or some kind of fingerprint that gives the user a higher level of confidence of what is going on.
why would an update need an image (.png) file
why would it look for an update on imgur?
why is a blocked access spinning up the CPU so hard?
Seriously I'd find out what was running at the time and remove it real fast,
everything is pointing to something both not right and not good.
You may also want to copy up your most important files to a thumb drive,
could be a ransomware firing up and trying to encrypt everything (if you're lucky it failed)
- that would well explain the CPU going nuts.
This internet thing is amazing! Letting people use it: worst idea ever!
It is the _normal_ java update process.
That's my point though, it acts very suspiciously and there is no obvious way to differentiate between nefarious behavior and something updating something you need on your computer.
Last Visit: 31-Dec-99 18:00 Last Update: 21-Jun-18 21:48