Notifications
Clear all

How about a new region called "Best Practice"?  

Page 1 / 3
  RSS

WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-17 9:51 am  
@Admins and Bill:
 
Hi Guys,
 
I would like - especially as a newcomer to this topic - an area in which members give other members tips from their own experience on how to achieve your goal effectively and, above all, successfully.
As a software developer, I have been living this "best practice" for many years and have learned a lot during that time to make code more efficient. And it is worth.
In my idea, I can learn from other people there, how they do something, lets say workarounds etc. Bill lives this in his tutorials, but he just can't explain everything because of time. 
Best practice has to do with experience I don't yet have. But I am convinced that everyone has questions about how to do this or that better. And everyone has experience he can share with others.
I am thinking of general and not specific knowledge. This could be an additional knowedge base to Bills amazing tutorials. 
Writing code or building an electronic circuit doesn't make a big difference to me.
 
friendly greetings to you 
Wolfgang
 

If I am not here, then I am most probably somewhere else


MadMisha liked
Quote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1801
2020-08-17 1:59 pm  
Posted by: @wolfgangw

I am thinking of general and not specific knowledge.

You can post your thread on "Best Practices" in Components and Programming.    Offer up the ideas you feel are best for you and ask others to offer ideas that work best for them.

One thing about a concept such as "Best Practices" is that it's never carved in stone.  What works well for one person may not work well for someone else.   So it's best to just offer your ideas and what you have learned and consider the ideas and experience of others.

You might even want to consider changing your topic to "Ideas and Methods for Programming and Electronics Design".  And then just go from there.  The very topic of "Best Practices" will likely cause controversy over which methods are actually "best" when in reality different people simply prefer to use different methods.

I could give quite a few examples of different methods in programming and electronic design that may or may not be "best" for you particular application.

For example, right now I'm studying FPGA and CPLD design.  There are constant "arguments' from people in that field on which approach is "Best".   Some prefer to layout an initial design in schematic form, others prefer to use Finite State Machines as their design template, still others prefer to begin a design using abstract HDL or Hardware Descriptive Languages, still others prefer to draw up flow charts for their initial ideas.

Also when it comes to which language to use there are often heated debates over whether a person should use Verilog or VHDL,  In fact there are those who favor other less popular HDL languages as well.

The idea that there is a "best practice" is basically a misconceived concept.   Whatever method works best for you is the one you should use.   And even in that case you may wish to approach different projects in different ways.

The same is true of any kind of programming or electronic design.  Different people program from totally different points of view.  Same goes with designing electronic circuits.   The idea that there is a "best practice" is actually a quite impractical idea. Perhaps even a dream for a perfection that cannot even be achieved in reality.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-17 4:01 pm  
Posted by: @robo-pi

Perhaps even a dream for a perfection that cannot even be achieved in reality.

It is a pity, but unfortunately true.

Never mind.

If I am not here, then I am most probably somewhere else


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1801
2020-08-17 5:05 pm  

I wouldn't say to never mind it.  It's always good to keep searching for the most efficient way to do things.  The key is in recognizing that there may be many efficient ways that things can be done.  And to also note that different people prefer to work using different methods.   It's also worth noting that different projects and goals may also be better approached using different methods.

I mentioned the example of FPGAs and CPLDs which I'm currently studying.   I'm currently looking at many different methods and I'm also learning both Verliog and VHDL.

What I've learned about people:

There are people who swear by Verilog and swear at VHDL.

There are people who swear by VHDL and swear at Verilog.

Which is best? <- An interesting philosophical question.

What I've learned about Verilog and VHDL.

They both have pros and cons.  I've also learned that which language to use can indeed depend upon what type of digital structure you would like to create.  I see Verilog loaning itself more efficiently to certain types of situations, but I also see VHDL loaning itself more efficiently to other types of situations.

So which is "best" to use may indeed depend on exactly what it is you'd like to create.

My suggestion is that it's "best" to learn both of them.  This way you'll know which one will be better suited to your specific project.

The same goes for designing the initial logical structure.  Whether you use a Finite State Machine, or a graphic flow chart, or some form of abstract boolean algebraic mathematical manipulation, is up to you.  Some of those methods loan themselves better to certain types of situations.  I think it's "best" to get a feel for all these possible methods and then you can be in a better position to decide which method to use for a specific project.

 

You mentioned programming and electrical circuit design in general.

Same thing applies there.

Which is the best language to use?

That can depend on what type of programming you want to do.  Obviously if you are looking at a particular piece of hardware you're going to want to use a language that is designed to run on that hardware.  There is no such thing as a "best" computer language.  Although there are people who will argue that their favorite programming language is the "best".  I tend to avoid the advice of those people. 😊 

Although having said that, it does make sense to use a programming language that is best suited to your goal.  If you're going to be programming AI, then Python is the "best" choice, IMHO.  Is it the best language for programming AI?  Probably not.  But it's what almost every AI programmer is using.  So if you want to be on the same page as they are on, it's "best" to use Python.  This way you can use what other people are doing and they can understand your work as well.

What's the best way to design an electronic circuit?

My approach to this usually begins with the main components I'll be designing around.  Choose the main components you will be using, and build the design around those.

I also tend to think of the hardware.  For example I tend to draw up my schematics in a way that reflects how the circuit will ultimately be laid out in hardware, either on a PC board or in terms of other wiring.

A typical way to draw up electronic circuits is to start with all the inputs on the left side of the schematic and the outputs on the right side and draw everything up that way.  That makes the schematic easy to read, but may not be even remotely close to how things are physically laid out in reality.

There's just so many ways to approach things it's hard to say what would be a "Best General Principle".

In fact, on a philosophical level if I had to offer up a "Best General Principle", I would suggesting starting with the hardware configuration and let that be the deciding factor in what is the best way to begin.  But a lot of other people might disagree with this and suggest to just design the thing based on functionality and let the cards fall as they may when it comes time to assembling the darn thing.

Those are usually the products you find yourself cursing at the engineers when you need to build or repair them. 🤣 

I personally put hardware and maintenance at the top of my priority list when beginning a design.   But, as I say, other's may disagree that this is the "best approach".   And I have a lot of very poorly designed products laying around to prove it.  What those engineers were thinking is beyond me.  They clearly didn't have to build or repair the products they designed.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-17 6:44 pm  

@robo-pi

 

Thank you James,
I can not only live with these statements, I also gladly agree with them from my experience.
You're right, there is never the only real truth or the only right way. We, the learners, or people who want to improve, have to and often grapple with self-appointed popes who recommend and propagate their best practice. And it is precisely these that are not always the best recommendations or simply do not fit our problem.
It is quite correct, as you said, that one either presents oneself with a single solution or tries to appropriate different ones.
Then if we compare 2 or more paths, we may find the best path for ourselves.
After working my way through your contribution, I can already say that I have already learned from you.
I just lack experience, I just have to admit. If it were different, I probably wouldn't be here.
As a programmer, I particularly liked the paragraph on programming languages, as I have often said the same thing to other people.
At the moment I copy a lot of what is mainly from Bill's toturials, like computers, copy & paste. So I'm still a long way from finding the best practice. But the more I build up, the more freedom I take to improve one thing or the other for myself. 
I feel like I'm back in my early 20s, only that I can now figuratively grasp the bits and bytes. I guess I have the same experiences as most professionals had before they became professionals.

It's quite interesting

Wolfgang

If I am not here, then I am most probably somewhere else


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1801
2020-08-17 8:26 pm  

@wolfgangw

It is indeed a quite interesting topic.  In addition to all the various technical ways to do things there's also the psychological aspect.  It can actually be quite amusing reading psychology papers on ideas of how people's personalities differ, and which personalities types a particular psychologists recommends as "best".   In fact, they often even offer up the idea that different personality types are "best" suited to specific tasks or careers.  I would personally take all these opinions with a grain of salt.   And in addition to that I don't think it really makes sense to put people into such confined boxes to begin with.  People are probably more flexible than psychologists would like to believe. 😊 

It just makes the psychologist's job easier if they can put people into definite boxes or categories. 

In any case, here's a short list of some "Personality Types" that psychologists have "boxed up":

  1. Results Oriented
  2. Goal Oriented
  3. Process Oriented
  4. Perfectionist
  5. Pragmatist

Note: This is a very short list of personality types psychologists have invented.   It's also assumed that the people are assumed to be honest and sincere.  In other words, it's assumed that the persons are going to try to do a good job and not purposefully cheat or take advantage of anyone.

With this in mind I'd like to expand on these 5 personalities types.  I might add that I chose these particular ones because I actually think they all apply to me simultaneously, although different aspects of these traits may be called upon at different times.

1. Results Oriented

This is definitely me.  I love to see results ❤️. This is why I like computer programming languages that allow you to instantly run the code as you are programming.   I prefer to see the results of my immediate work rather than having to wait until the whole program is written and then have to debug the entire thing.

I also like to do this with physical projects.  And this leads me to building everything in a modular fashion.  This way I can see each component working before I move onto building the next component.  I also find that using a modular method to build things makes them far easier to modify, repair, or replace at a later time.

2. Goal Oriented

Because I tend to work in a modular fashion I don't personally see a lot of difference between being results oriented and goal oriented.   I kind of consider each module to be my "goal".   In this way getting results is the goal.   But I guess for some people being "goal-oriented" can mean different things.   Obviously psychologists have different ideas on this as they often talk about the differences between people who are results-oriented versus goal-oriented.  I personally think I'm both.

3. Process Oriented

A process-oriented person supposedly pays closer attention to the process that leads to the result of the goal.   The psychologists claim that people in this box are more likely to pay closer attention to the details of a process making sure ever step is taken correctly.  For this reason they recommend these personality types for careers where someone needs to oversee a process.

Again, I think they are just making up silly boxed.  Just because I'm results-oriented doesn't mean that I don't also pay close attention to the process of reaching that final product.   In fact, I'm often told that I have my processes "down to a science".   So because of this I would say that I'm also process-oriented.   But I guess there are people who are so deeply involved with the process that they really don't care whether anything actually gets done or not.  I'm not so sure that would be a good thing?

4. Perfectionist

I'm definitely a "Perfectionist Wannbe", I do like to do things in the most efficient and best way possible.  However, I have come to learn in life that sometimes just getting results is a far better goal. 😊 

5. Pragmatist

This is what I have become in my elderly years. 😎   If can get the dang thing to work, that's good enough for me. 🤣  I've given up on the pursuit of perfection.  I do still try to do the best I can.  But I'm not going to waste time and resources on trying to get something perfect.  I'd rather have something that functions fairly close to what I would like and is actually working instead of having a "perfect product" sitting on a drawing board not working at all.

~~~~~~~~~~

So that's my rant for the day. 🥂 

I say, be who you are, and do what feels right for you.

Let's put the psychologists in a box and see if they can find their way out. 🤣 

 

DroneBot Workshop Robotics Engineer
James


ReplyQuote
WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-18 8:17 am  

@robo-pi

Sorry James, 

that was too much stuff to anwser last night.

It was just too late last night to reply to your post. I like your humor and sometimes I did more than just smile. In some places I also found myself, like the saying I found in a developer forum for programmers.
 
The programmer's three enemies: fresh air, sunlight and the unbearable roar of birds. 😆 
 
Now I have a lot of interests. I also read reports from psychology from time to time, but I don't really take them seriously. But I absolutely agree with you when you claim that this area is almost inexhaustible.
But just look like this:
Psychologists need a "right to exist", a place in this world. You need electronics and software. They give us a roof over our heads and bread to eat. 😀 
I myself am one of the few chosen who can rightly say that they have turned their hobby into a profession. I would like to thank the psychologists and you for the pleasant conversation.
 
Now that I've been in the field of electronics with controllers for just a few weeks, I can already say - here I refer again to your previous post - that I basically now use almost the same approach as I do for Software do too.
 
First the thoughts on the project. Sort your thoughts with a mind map and - also in your private life - write in small specifications. (helps me to be structured)
Then the analysis. Software developers and electronics engineers are problem solvers. In both cases we have to see the whole thing before we even take the first resistance in hand.
Then it comes to the analysis, dividing the problem into its sub-problems. The modular work you mentioned. I actually find that again in electronics and software development.
And at some point we will finally be at the point where we will finally pick up code / electronic components and assemble them.
Then the testing and degugging. Correcting errors and repeat with testing.
That's probably why I like working with Raspberry and Arduino so much. I can touch the bytes in the form of resistors, ICs and capacitors, on the other hand I can apply my knowledge of programming.
I wouldn't really change this workaround much anymore.
 
Nevertheless, I would not completely discard the idea with such a subsection.
In our company there is a culture after projects that is called "Lessons Learned". It should be discussed what went well and what was not so good, so that you could benefit from it in the next projects. Nobody does that, but the thought is good in principle.
Old hands like you know their job. They already think with their spinal cord. Not only have you found your workaround that suits you, you also have the necessary technical and manual background, which is exactly what I am still missing in the field of electronics.
In the past few years I was able to attend an annual developer symposium in Nuremberg, where mostly good lectures took place. Also good, very convincing speakers. And yes, I agree with you. There are many popes in every industry who preach the truth from heaven, but it doesn't always apply to your work. One of them had once said that very clearly.
That is probably why the one who stands above the popes - whether you believe in them or not - gave us a brain down there to think and decide.
 
Nonetheless, I want to learn from the professionals. Benefit from their experience. For better or for worse. I don't have to keep reinventing the wheel, even if it's sometimes fun or even educational. In return I thought that such a new section, calling it "Best Practice" or "Lessons Learned" might be helpful.
Nobody likes to admit mistakes. But - let's come back to the psychologists to close the circle - it is precisely from mistakes that one learns best.
 
Live long and in peace and may the Force be with you
Greetings Wolfgang
 
 
 

If I am not here, then I am most probably somewhere else


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1801
2020-08-18 4:48 pm  
Posted by: @wolfgangw

Nonetheless, I want to learn from the professionals. Benefit from their experience. For better or for worse. I don't have to keep reinventing the wheel, even if it's sometimes fun or even educational.

I have a lot to say about the above quote.

First, I agree that learning from professionals, and even other hobbyists is definitely the way to go.  In fact, that's the very basis of all academia.  The fact that we humans can learn from each other rather than having to figure out everything ourselves is indeed a very large part of what elevates us intellectually from others animals.

Teachers are an invaluable resource to be sure.  I take online courses all the time.  I especially like the MIT courses on physics topics.   In electronics and robotics I find many YouTube channels quite valuable,  In fact, that's how I became a member here.  Bill videos on the Arduino, and other things have been very useful.  In fact, when speaking of searching for "best practices", I would even say that I've learned a lot of "best practices" from YouTube channels.  Paul McWhorter got me started on the Jetson Nano and OpenCV in a way that was far easier than just about any other way I could have learned about it.  This is because he had already suffered through the learning process and just condensed everything into a very well-structured course.  There are a lot of things about it that just aren't easy to discover or learn if you're grappling in the dark.  Information that well organized on those topics is very RARE to find. 

However, there's much to be said also about taking the time to reinvent the wheel in specific situations.  There are several reasons for this.  One reason is that often times wheels are taken for granted so much that no one even bothers to think about the potential of reinventing them.   And the problem there is that the wheels then become outdated and could actually benefit from being reinvented in new ways with a fresh approach.  This is especially true when speaking abstractly about technological wheels.   Technology changes so quickly that wheels invented only a short time ago can often be far better designed if someone will simply take the time to go back and redesign them.

And then there can also be great educational value in reinventing a wheel, even if no changes are required.  By reinventing the wheel you have a far better idea of what it does and what its capabilities and limitations are.  Obviously you don't want to get bogged down in having to reinvent every little thing.  So you need to pick and choose which "wheels" are worth reinventing, even if it's just for the learning experience.

I'm currently taking an MIT course on Schrodinger's Equation.  This isn't the first time I've studied Quantum Mechanics.  In fact, I've been studying physics my entire life.  I'm taking this course specifically to "reinvent the wheel".    In a sense I'm "going back" to study the derivation of the Schrodinger in depth to learn more details of how this particular "wheel" was invented.   Of course I have other incentives to do this having to do with better understanding entanglement and the necessity of the conclusions of Bell's Theorem.   I've come to realize that understanding the "wheel" of Schrodinger's equation is paramount in gaining a better understanding of this phenomena. 

In fact, I'm doing a similar thing in robotics AI as well.  The "wheel" there is the perceptron.  A wheel that most everyone takes for granted.  However, even those in the AI community are well away that it's not the best wheel in the world.   The problem is that everyone has moved on to things like "Neural Networks" and "Deep Learning" that no one wants to bother going back and learning more about the wheels.

So there are situations where reinventing the wheel can be quite powerful.  Even if all it amounts to is gaining a better understanding of how the particular wheel of interest actually works.  And why it was invented to be the way it is.

Choosing which wheels are important to gain a better understanding of is probably the key to the art of engineering.

DroneBot Workshop Robotics Engineer
James


ReplyQuote
codecage
(@codecage)
Member Admin
Joined: 1 year ago
Posts: 749
2020-08-19 12:35 pm  

@robo-pi

It's been a long time since we've gotten to see any poetry from you!  We need to have our hearts lightened and our smile perked up!

What better place than in a Best Practices thread to "Practice" some poetry?

This post was modified 2 months ago 2 times by codecage

SteveG


ReplyQuote
Robo Pi
(@robo-pi)
Robotics Engineer Moderator
Joined: 1 year ago
Posts: 1801
2020-08-19 4:41 pm  

@codecage

Poetry practice would be like a cactus
prickly and painful and would likely distract us

I'm working too hard to think of the words
that would lighten the hearts of electronic nerds

The practice that's best to suit you and me
may be grounds for divorce in a trio of three

For every man and woman who works
there exists unique individual quirks

Telling someone that their methods are wrong
will likely result in not getting along

When Einstein discovered the nature of time
everyone thought he'd committed a crime

The wheel he destroyed was the Newtonian dream
And the wheel he invented made people scream

Schrodinger screamed, "My cat's in two states!
as he pondered the paths of his animal's fates

An electron is here whilst it's still over there!
Until we examine to make it appear

The world has has become a indeterminate place
where the thought of best practices has become a disgrace

Perfection is lost to chaos and chance
and the dream of coherence is but a romance

So program your robots to expect the unknown
and beware of the apps on your intelligent phone

DroneBot Workshop Robotics Engineer
James


huckOhio and codecage liked
ReplyQuote
codecage
(@codecage)
Member Admin
Joined: 1 year ago
Posts: 749
2020-08-19 8:16 pm  

@robo-pi

I knew you were up to the task!

SteveG


ReplyQuote
WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-22 3:34 pm  

@robo-pi

@codecage

 

Hey Guys,

I was out and busy, that's why I was so silent. Thanks to your poetry I just wet my trousers because laughing so much. Enjoying the last days of vacation and paying tribute to the approaching end of summer, I've built a workbench for my electronics projects in my small office here. So I haven't had time to answer here in the last few days.

@robo-pi: You are truely not a Shakespeare, but I laughed a lot. 

I wish my English was good enough to give you an adequate counter, but it's just not enough for this level. And believe me, it had fun and I would have more fun if only my English would be better. So forgive me both for not being so.

About the "reinventing of the wheel": I do this. And I did this many times before. Why so? Because it makes me -and I think many other people on this planet  - understanding better what I do. I didn't make clear enough, you got the reason, I don't mean to repeat something another one already developed by "reinventing the wheel". What I meant - and I hope this time I catch the point - is, that I don't want to make all the same mistakes other people have done before.

Sometimes we have to do those mistakes. But - I guess you agree - not always.

I thank you both - you codecage for the nice poem and you robo-pi for the - honestly meant - detailed and interesting points that you have listed in your explanations.
Due to the corona crisis and a chronic illness, I've been working here at home for almost 6 months and there isn't much good conversation.

Greetings Wolfgang

 

If I am not here, then I am most probably somewhere else


ReplyQuote
codecage
(@codecage)
Member Admin
Joined: 1 year ago
Posts: 749
2020-08-22 4:20 pm  

@wolfgangw

Robo-Pi is our poet, so I can't take credit for that.  Just for waking him up long enough to entertain us with  another bit of his light hearted renditions of poetry.  He has graced these pages on multiple occasions in the past with his prose.  As you wade through postings from the last year you will surely come across some of his more entertaining posts.

And there is no reason to have to apologize for your English.  It is very good, but I understand the difficulty in conveying the exact meaning of what you are trying to say.  Just be thankful that you don't have to read anything I might have to type in any other language than English.  I can tell you for a fact it would be totally unintelligible.  It would probably be more like a 6 month old child just banging away on a keyboard!

Folks from other parts of the world seem all to speak multiple languages, while the majority of Americans speak only English, and some don't do a very good job at that. 😀 

SteveG


ReplyQuote
WolfgangW
(@wolfgangw)
Trusted Member
Joined: 3 months ago
Posts: 72
2020-08-22 6:29 pm  

@codecage

Posted by: @codecage

but I understand the difficulty in conveying the exact meaning of what you are trying to say. 

Indeed Steve, that is a real problem, in every language. That is reason, why so many automated translators fail, even many of them are really good. Thank you for the credits to tell me that my English is not so bad. I like to communicate in your language, even there are natural borders, and outsider never catches, because he/she never sucking from mothers breast as we say.

May I brag a little when I tell you that I studied Japanese for a few years. Terrible language. Interesting, but very hierarchical. I gave up at some point when I could read quite well, but in real life - that is, in class - couldn't form a correct sentence.
A language needs to be practiced. Just as your hands learn to use a knife and fork, the keyboard, memory components, etc., your brain must constantly learn to move between two grammatical worlds. My father once told me that you can understand a language soon as you think in that language without noticing. In Japanese, I didn't have a caregiver with whom I could simply talk. Too bad. So I gave up.

Somehow I am not surprised, that that poem came from James. He's quite the quy, this is somehow matching to him. 

 

Wolfgang

If I am not here, then I am most probably somewhere else


ReplyQuote
codecage
(@codecage)
Member Admin
Joined: 1 year ago
Posts: 749
2020-08-23 11:27 am  

@wolfgangw

My tiny bit of Japanese came from being stationed on Okinawa while in the military back in the late 60's.  There are only a few words remaining and I was never able to carry on a conversation.

Your signature line goes just great along with one of my favorite lines, "Everybody has to be somewhere!"

SteveG


ReplyQuote
Page 1 / 3