 Our next talk is about fun with electronics development. The assumptions that people make, the traps you can fall into, because, well, that's the way you've been doing it all the time. Maybe you've done some copying and pasting from other projects. Those 100 nano always go in there, and then suddenly we wonder why there are electric impulse problems. We have a speaker that can talk about exactly that, and that's Luky. Please. A warm welcome to Luky and his expertise, and have fun. Right. Hello. I'm glad that some people are here. First question. Are there hardware developers present? Professional ones? Okay. I hope that there was something for every one of you. I had to mix it all quite from different kinds of levels of difficulty. Let's start with something simple, resistors. You know these, you have many of them on your board. Now two things will be appearing across this whole talk. First, do you really need this? Second, is this really correct? So, this resistor has 4.223 kilo ohms. It would be more regular if you would be using standard values. You've saved a lot of hassle, things get cheaper. You could perhaps choose the same value as some other resistor on the board. Yeah. Second item. Is it actually true? No, it's not. That resistor will not have 4.223 kilo ohms. There are ranges, there are torrents, there are things that can damage a resistor, there are all kinds of things you have to look out for. There are power losses which are becoming more and more important, not just because boards have to use little power, but mostly because small resistors 0.4, 0.2 can actually take, for surprisingly little, and in case of something goes wrong, you can easily have something going up in smoke. 0.402 things normally have 2 milliwatts, which is very easily reached. Very quickly because this is where makers often make errors. There are pull-up resistors that you can, that you have in modern boards, but these are quite imprecise and can vary from one charge, from one batch to the other. 30 to 60 kilo ohms often is not enough to keep a signal going easily, cleanly. If a resistor is really important, you must never rely on the built-in pull-up resistor in the microcontroller. If it's not that important, an external thing, it's not that important. If it's important, better have something external that you can control better. A small detail, a marginal detail, someone has very good microcontrollers that are very precise and 4.7 kilo ohms takes you quite a distance. So what do you do with resistors? For example, you can very nicely measure current which can be precise, cheap and quite easy. What happens though in practice with a setup like this? The resistor has to be connected somehow and these connection resistances, if you choose a small measurement resistance, they can be significant. The normal approach here is for terminal measurements. So you take care that the measuring and the power is at different rails. You can have really good and expensive resistors in there, but you can also use different resistors. I've got some knowledge about that. If you want to, you can couple it. Capacitors are the next important... Capacitors I think is the word. Everybody knows that. And this is the real capacitor. It's not different than the one you can see on the drawing part. You can see on which tool you use or which distributor you use. Those other elements are smaller or bigger. And you always, if it's not a really uncritical device, think about what does it do. For example, higher frequencies. It may happen that it's really small and the resistor that is in series to it is quite big or it may oscillate with the capacitor here, which is also there. That is not only a problem with that, but every real device has other elements inside, parasitic elements that are just there, which are really important. Surprisingly, it's the diodes between gate and drain with MOSFETs. However, I have the good experience to just put it into the paper, the schematics, and you notice that and you will see that there are these powers that go through it and you will see it. With a resistor, there is, depending on how it's built, sometimes significance inductivities. So a normal resistor is unusable at 300 MHz. With inductivity, it's important how they are built. Inductivities where they are won't, it's often significantly. One practical example for the capacitors, huge microcontroller with capacities, so in every FLCC connection, an additional bypass capacitor is needed. So someone said with the 15 nanofarads could be complained with the other capacitor. So it started, everything worked, and then it started making arrows. Someone looked at the arrows at the software and everybody expects the arrows in the software, but no, it was the hardware, small talk about. Why do we need capacitors? Why bypass capacitors? Why are they important and where we aren't, we forget them. On the board, there's also free hidden elements. In the trace, there are also some inductivity and capacity to the ground or to any other line in the university. Sometimes they're negligible, but the one that's right next to it mustn't be neglected. I hope, I can expect that I don't have to explain that CMOS microcontrollers and other integrated circuits are defective, only use power while moving or while changing the state. At short periods, they need a lot of power and after that, not that many. They have to come from somewhere. The big electric cap are far away, so bypass capacitors are needed and the bypass capacitors have to be close. The great hint that has already moved a lot of problems is first of all, after placing the ICs, put the caps as close as possible, put it in their big line and with every bypass capacitor gets two of its own wires that are not shared with anybody. One to ground, one to VCC and you have to do that with every one. In this case, it was done and the problems were big. Capacitors is important. In this case, the capacitor is one microfarad. It's not with the base tolerance, it's always there. Condensators of ceramics are depending, the capacity is dependent on the voltage. The important is the smaller the device is and the higher the voltage, sometimes just 20% of the ordered capacity can be actually used. So, one microfarad, the capacitor has with one volt bias voltage. That is quite difficult to get those information. It's usually not in the data sheets, manufacturers offer their own data sheets if the manufacturer does not offer these information to choose a different manufacturer. A small thing, of course, with ceramic capacitors, there are three letters at the end. What do they mean? It means something about the temperature and how stable it is about the temperature. The rest you pay, the worst it gets. Most of the grills are zero. They are not dependent on the temperature, but you don't get anything bigger than one nanofarad. So, you can't use them as bypass capacitors, but as filters, you have to use them. Also interesting, I also had to learn the hard way, ceramic capacitors are ceramics. Ceramics breaks easily. And if you don't care, then small fractures appear. I unfortunately don't have an image of that, but through these small cracks moisture enters the device and that is not good with electronics. Another battery problem. The battery has that many milliampere hours. That is not really good. The effective way is, as always, after the tolerance is with batteries, especially with the temperature and with how much power you use them. The more you take out of the battery the smaller the capacity gets. So the 2600 milliampere hours are only valid if you take a certain current, but you'll never use that. You'll always be above that or below that. So if you have a device with batteries and you design it, you have to test that. Only with the datasheet you don't get any more information. Now, large topic, datasheets. The datasheet says, well, the datasheet unfortunately is written by humans as well, and humans make errors. That can happen. So if you have a datasheet, open up. First of all, look if these people made errors. Are there any known errors? Are there some corrections? The editing history could be important. So that will tell you what has been changed and corrected. Now, next interesting part. Typical. On the first page you have the typical details. Typical means unfortunately nothing, but we would like it to be that way. Yeah, well, if you think about it a bit and read the footnotes, you will notice that you will get some very nice answers. Typical means non-tested. So the only thing that has been tested with an integrated circuit are the min and max. Now, these are hard pass and fail tests. If the circuit is supposed to work reliably, even next week, you should keep inside these min and max in worst case scenarios. Now, the absolute maximum ratings, because more and more frequently I've seen circuits where the microcontroller was operated with 6 volts because it says in the data sheet, absolute maximum, yes, that is allowed, no, you are not allowed. Absolute maximum ratings means if you keep below that nothing should happen, if you just exceed that even with one value shortly, a short amount of time, nothing may happen. We don't know, maybe nothing bad, maybe it will fail immediately. So avoid maximum ratings. Electrical characteristics is the right page to use. That is where you should look if you are going to operate your IC. Another nice story. On the first page of a data sheet, the Fed can switch 429 amperes. Wow, five pages further on. Well, yeah, well, the Fed can, the casing, it can't really manage to carry more than 160 amperes. So what's meant is the Fed's own temperature and if you don't take care and include lots of cooling devices, things can get really hot. And this is from an Arduino motor sheet. There was a driver on that. That said, I can do 50 amperes and that's what it was sold for. Yeah, well, at room temperature, optimum cooling. The pin bar can do 3 amperes per pin and the connection can do 20. So the motor has nothing to do with what you can expose the whole device to. So diodes. These diodes have just half the kind of loss that typical diodes have. So VCC, clean 5-voltage and nothing else. How much is the X5-volt? 0.5? Who will offer more? Well, it depends on the temperature. Shot-key diodes have a temperature-dependent blocking current. If you heat the tool, the thing, it can happen that 10 million pairs in the wrong direction where you could normally mean that the diode should block that. Maybe these will go through. So you get a nice little voltage gradient there. And if you're then supposed to start a USB application or something, you'll have lots of fun. The 12-volt on-board network in the car, always an interesting story. Yeah, well, it's not 12 volts, it's actually never. First of all, a 12-volt LED battery has 13 or if it's fully charged, 14.4. If it's nice and cold in the car and you start the car, this will fall to something like 6 volts or even less. So below that, everyone is afraid because the light machine won't work at that. But on the other hand, 120 volts may be too much, but 60 volts does happen. There are relays there, there are a lot of many issues and it's not stable. The Americans have everything bigger and if the battery is empty, a start hold of the AlphaV may be useful, 24 volts. If the battery is used for 12 volts, it will not start and reverse battery, yeah, it may happen that you put the battery the wrong way around. If it's not protected against the reverse voltage, it's bad. Another thing with the car, and car means, it's 40 to 125 degrees. The NEC has different limits. In reverse case, it goes to 140 volts and if you have to move it to the gearing or the motor, that may not be enough. But usually, if you grade 3 to minus 40 degrees to over 85, it will probably not reach that high. Always interesting with temperature range, look at what it means with that. Surrounding temperature, building temperature, all the never measurable junction temperature. So, the temperature of the seletium inside the device, usually it's ambient or case temperature, but look at it or ask about it. All right. Another secret. The inverting and bias current. All right. You have seen the schematic. It really happens with real old controllers without integrated input bias compensation. The input bias power of operational is quite big, so they developed devices that they don't need that much. It's not perfect and not the same well on class at minus, so it may happen that there is no power going into the operational but on the outside, and that's different on class at minus. So, with modern operating, you should change to use a different one, because the bias power is specified as class at minus, but it's standard and the trigger is still there, but it will probably not work. Operational, you're getting better and more stable. You can put a couple of picofarades, which is a bag and a dozen, immediately start to oscillate, but you can't trust that. Always check. The easiest way is if you put a jump in front of it and not really scientifically the correct method, you look at how the exit overshoots and if the overshoot is smaller than 30%, you can say the phase version is less than 45 degrees, that's okay. It doesn't always move or work, but it is practical and it's quite easy to measure. To notice these errors beforehand, operating and having other important specifications, the gain battery would sell the bandwidth. So if you have a gate, 50 MHz gate bandwidth, you put a 100 kilohertz signed signal in the entry and it's configured as a buffer, so at the outside, it should be exactly the same signal. No. Gain bandwidth product is a small signal happening. If the signal is big, the slew rate may happen. The slew rate means how much the output can do. In this case, the output cannot follow the output signal sufficiently fast and the sign goes into a triangular wave. Active filters, probably everybody knows them. To calculate them by hand, it's not very easy, there are tools to do that. So let's build something like that and the same gain bandwidth product, but at a couple of kilohertz, something happens. What happens there? So, it has something to do with the frequency-dependent output impedance of the operation mode. So, you build a voltage divider with C2 and R2 parallel to R1. That means the filter does not burst to a certain frequency like it's supposed to, but after that frequency, the reduction is reduced. Ratorial means from minus VCC to plus-fold VCC or from zero-volt to VCC. No, that's wrong. Until to the real edges it will not work and how close you get to zero-volt or VCC is important to the amount of power taken at the temperature. The additional, if you have to choose between operational amplifier with the defined Ratorial or classical, the Ratorial, because of the significantly more expensive output is always less detailed, less exact than a classical one. In this graphics, you could also see quite clearly the possible output of voltage. So operational amplifiers can also be used as comparators is the next myth. It has the same symbol so they could be used interchangeably. This is what people like to do, is that allowed? No. You should really not do that because the exit stages of a comparator are completely differently built and the inputs stages as well. So every device for its own purpose, the comparator use one if you need a comparator and if you need an operational amplifier, use that. Next large category are the instrument amplifiers. And these amplify the voltage difference of the inputs by a chooseable or fixed value. Is that true? Yes well they do but there is a very important graph in the datasheet which is the diamond plot because of the shape and it says in which voltage area range the inputs can be for it to function properly and there are some restrictions and you really have to read through this carefully and take care how you use them. An analog digital converter it would be actually a topic for a separate talk of its own. SR analog digital converters are very widely spread and almost always connected the wrong way because there are no high resistance inputs here. What happens is that the sampling capacitor is switched to the input and that will then load itself up from the voltage that is actually supposed to be measured but that charge has to come from somewhere to load up the capacitor so if there are no filter capacitors used the voltage you are supposed to measure will break down and you measure less than you actually want. So always use an RC filter in front of the input of a microcontroller converter and next function is of course anti-aliasing and so on has always you have to keep to that. So some kind of product will be advertised by saying we have a 24-bit analog digital converter here hugely expensive you can actually it can well happen that a similar product which has a well adapted but only 12-bits ADC will actually provide better output than a very expensive 24-bit ADC the resolution with ADCs is only one of the important criteria it can be very elaborate and a very elaborate task to treat an ADC correctly and set it up correctly and the components around it can be used correctly these will now follow us through a certain number of slides because it's an important thing very shortly what is precision what is exactness what is stability precision was known as repetition precision I am measuring the values several times I would expect the same value to come out otherwise you have bad precision exactness I measure a value and I would expect that value to be correct but statistic tells us that you can never know the exact value you can only approach it as far as you want and the stability I will measure at different times now tomorrow the day after tomorrow I want the same value to come out well these three conditions should be exactly specified you should know what you want do you want a precise circuit do you want an exact one do you want a stable one do you want a combination of those if you want that you have to invest a lot of time and money for development the main problem with ADCs are the reference voltage sources even with very expensive reference voltage sources you will have problems for example a 16 bit ADC to supply this adequately with the reference voltage you just have to look at the specifications if the temperature changes by one degree with these well LT 1019 top of the line the normal reference voltage source but if the temperature changes by one degree the voltage will change by 10 ppm which is about as much as one bit of a 16 bit ADC so 16 bits precision it will be very hard to reach you have to use very elaborate very sophisticated reference voltage sources so don't let yourself be blinded by the bit number stated for an ADC the reference voltage the temperature dependency is not linear by the way if it were it would be easy to factor it out but it won't work that way right let's come to something different the temperature stated with lots of digits behind the decimal point well temperatures with more than 0.5 degrees precision measuring those is very very hard is actually not serious to state a temperature with several digital decimal places because that is normally not reachable very important point here temperature sensor will always measure its own temperature it will not measure the temperature that you want it will measure its own temperature that can be a different thing oscilloscope sensors are very popular source of error you have a 10 mega ohm you know what an oscilloscope has and it sounds like it's a real high resistance however it is and can sometimes that high resistance oscilloscope test tests are usually a problem with the capacity there is however an easy trick that sometimes there is something that if you have a really small signal and try to connect it with the oscilloscope just put another connection onto the same trace and look if the other is exactly the same signal and just by adding a second connection you can expect that the first connection has already made an error and you should use different methods to measure the signal don't forget the connection has to be has to be checked several times as frequently so you have to recalibrate it often the mass and the correction is really well known error measuring and you never know whether that is from the signal or somewhere else is it really there with the connection there is a small plastic bag tip there you usually lose it but the paper clip you can make a test so you have a really significantly smaller area to the ground so you have to make sure that you don't make any short circuits so make sure the electromagnetic chip it hadn't before the speed of the signal is usually absolutely irrelevant sometimes it is about the time, the rice time the rice time of 5 nanoseconds is usual for slow CMOS like nearly every microcontroller if you switch you put up CMOS with significant frequency parts far over 70 MHz so the repeat rate the frequency of the signal is not important the rice time is important however it's another huge topic and I was told I will be thrown from the stage if I'm not ready after an hour so power supplies so an output 9V device should run at 9V if they are used with little power they sometimes have significantly higher voltage and that sometimes can break your so if it's not a controlled voltage supply be careful if we have a bus converter a step up converter and it says you can do one output power well, not the output power it's not the maximum output power it's the maximum output power you can calculate with this formula and it also includes the inductive current so you also have to calculate that you should use calculational tubes for that don't use it don't calculate it by hand one other thing, step up converter have to be significantly over-dimensionated how does it work in practice how do you look at it realistic with the well-known old free additional parts step up converter are usually a big fan with problems and usually it's one of those if there's a problem so it's directly behind bypass capacitors and clearly layout it look at the components really carefully especially the loop where a lot of current is flowing it has to be minimized it isn't always easy but you should do your best to reduce that so I have seen too many projects where you layered the needle because the converter had too many problems so funny you usually need more than one voltage so you need several step up converters so sometimes there is a bit frequency effect so there are frequencies so even the same voltage the step up converters are usually not running at the same frequency they usually have in the effect slightly different frequencies and you get a bit frequency sometimes step up converters have a frequency that you can synchronize them you connect them with each other with a pin and they all run at the same frequency but that only works when they offer this option they do not offer this option you have to decouple every step up converter from every other so have significantly distance between them to have capacitive induction and make them have a large enough input capacitors and then it says yes, I don't care about the if the background converter has some problems I just put a dropout regulator in front of the small components and it will just remove the issues the problem is the it's supposed to do that theory does so in parallel projection ratio is depending on the frequency of the and how much voltage drop is accepted over it LDOs normally look like linear controls or converters but they can get unstable if they are not connected to the right capacitors at the output and interestingly LDOs need a certain amount of serial resistance to remain stable so the resistance that's built in is actually low inductivity is actually mechanical thing you can't get the polarity wrong but you can link it wrongly so beginning and end should always be where the most dirt in an electronic sense happens on the side is not filtered that's where the beginning of the coil should be that's why inductivity is marked with a dot there just a small insertion the reverse current normally takes the path of least impedance not the path of least resistance so with higher frequencies the reverse current will more and more approach the initial path is that important? well it can be very important there's the old hints there just put everything connect everything to ground and then the current will find it's the right path good idea but you should not just simply fill everything with ground but go after each signal and avoid mask peninsulas and if you just fill in with ground without care and not look at the way those areas are then shaped sometimes can couple over signals another width is that 90 degrees angles must be used on the bars that's with a lot of measurements you see there is absolutely no problem with that there and sometimes with real high frequency that's a bigger problem with high angles it may be a problem but only with production so they maybe use rectangular lines at no really it's fine so the 50 ohm regular line is a couple of millimeters or millimeters wide you have calculated if that value is really critical you should tell it to the platinum the manufacturing house because only he knows exactly how it should be if it's important or not it's about your project so a lot of components you can sometimes have problems with vibrations they fall down so you stick it but never with silicone not with hot glue it doesn't work and second and some other cyanide acrylate doesn't look nice but you have to stick it but with the right material several people think I've made this great connection nobody must rework it so I put it but usually you can just do put it with more of a patient my board is ready I have thought about that a lot and I heard it quite often but have you really thought about all components is it possible that you can get them are their fiducials are the bias close enough to the pants or do they overlap has been a problem no don't put any solder resist onto the bias that will lead to errors have you good physical connection holes the 3mm is not possible good to connect it with screws if you have on the board a plate for the serial number have you thought about that it has to be sold have you thought about rechecking it with a different program that it works so before you send it to the manufacturing house sometimes there are errors are the are there is there enough space can you really screw in the 6 without making problems so you get the device and you can't open it it doesn't run so you look at the thermal camera and you see something happened down there because 36 degrees is not the problem is it was not connected the thermal camera just was used wrong thermal cameras are really great you can have a lot of fun with them like the colleague who photographed me while soldering but you should know what you are doing and take some precautions no flux it doesn't have to be removed it's only clean that's soldering I can also talk about that that refers to no clean what does no clean no chemical aggressive or conducive so they still may be sticky so liquids dust may collect there and it leads to problems so if you have something to do with small currents or high voltages it removes the no clean the flux so crimp connections we better solder additional so that it really works yes better by a good crimping tool and the proper crimps so that it works better and if you do have to solder it it stops mechanical mechanics have no influence on electronics as soon as long as there is space there won't be a problem with mechanical things well if a current no if a tension mechanical tension is introduced it will have a certain influence particularly on highly precise components the reference voltage source that changes with a few bits of your expensive ADC if you bend your board so you should avoid that it's not very easy to use certain slits to reduce the bending to the tension you've never had an ESD problem well I've had lots of them ESD damage cumulative so they may not actually attack the chip and simply destroy it maybe just only after 10 attacks it'll get worse and then break eventually well if my circuit has 8 kV ESD rating well yes it may have that but this is after the human body model which unfortunately is not always enough the whole group of components will have to be valued with somewhat different criteria you need more protecting components over voltage protection the created diodes will not look after that because in most cases they are simply not specified the makers will not guarantee how much these will bear so as a responsible developer you should not expect that to work and add external protection components right I have kind of worked through everything last myth the classic we've always done it this way who has never heard that one right meanwhile we have new components we have price pressure we have EMP regulations so we've always done it this way simply is no argument to keep doing it this way now the new bullshit it's called right on the first try can only come from someone who's never done it these people then claim with the simulation tools we can get it right on the first try well yes it could be done if you massively over design things and do not use innovative solutions and actually it doesn't quite work so next one products are simply rebuilds of demo boards the developers simply drink coffee no they don't demo boards are quite badly suitable to be rebuilt and sold because they have a completely different purpose they are just there to present your own chip in a favorable light and not to create a product that is actually ready to be sold so some reference boards reference designs demo boards simply have errors right now I will have to thank some of my former colleagues I couldn't manage to do all mistakes myself some of my former colleagues and current colleagues Kaikad is a great tool but it needs some more development and will be very grateful for some support and I have to thank my PCB designer my graphics and any programmers are very welcome I have few interesting products to share with you so at the end don't do any stupid things with your knowledge no war tools, no toys no surveillance technology let the other ones do that thank you great I don't have to throw him off the stage any questions? yes please what is your approach if you have when you have a problem and don't know how to find it yeah, drink coffee that depends a lot on intuition is a bit steep usually you assume where the problem might be critical so if the device has error potential I always try to put in resistors in there so I can choose different parts of the device at different times so if you use a thermal camera properly it's usually quite helpful but you have to first take a filter of the unsupplied device put the other one on top of that turn it on put also the scope on it sometimes you find the errors usually you find the errors usually it's good not to tell your colleagues and just let him continue to work because looking at it from different view usually helps or a new day have it next to my workplace so are there any literature that you recommend? there is the usual literature suggestions however most of the subjects are really they are really everywhere I've always wanted to create a checklist however I have to admit that at certain areas I just don't know enough about them I don't know maybe we can do something about that if someone does have time and wants to do something like that would be a great opportunity the slides can be found the trap that I fell into but didn't really find a good way out of is where do I find for an IC the layout information if I do not yet know which maker I'm going to use in the final product so if I have an IC with a certain as N whatever I don't know where to buy it from and every maker gives you different measures for the patterns that's a significant issue or not at all the suggestions of the manufacturers will always have to be checked carefully I always have footprints created them and optimized them for how it works where I work the suggestions of the manufacturers aren't always that correct or maybe they are correct but not appropriate for your problem for example you could create it and solder it and you will notice there is a little bit too much solder or you should reduce the solder resist and you try it and look at it and see what does change and what gets better and you change that in your library and just do the average why not for the first try that's reasonable completely okay another question is creeping up I have a question about the ground areas as people say it's good to separate analog and digital parts I think it's nonsense what do you think no so semiconductors create I say ADCs and logical verse so for the mass for the analog parts and the digital parts digital and analog parts put a slit in the only connected by a small bridge as the usual yes well you can do that however usually you will get more problems than you solve by that good end is put in the slat road as if the state was there but put any lines over the slats and then put in a connected ground floor but that isn't always valid it depends on the case different from case to case basis the producers from ADCs of fast are connected so some say connect the ADCs the the ground just below this I see and if you have two ICs that say hey connected only under me you don't know what to say what you do and usually it's reasonable to just use one mass there's one ground usually there are fewer errors but sometimes it's this way sometimes usually I put one big ground but that depends with critical things it is in here where does it return do I have to put it in with to change planes doesn't have to change planes in the path back to try to not have that usually they are not critical problems you just put a bustle and you just put in parallel flop signals make them short on the back path yeah it's still quite difficult to separate analog and digital parts if the connections are not on the same side you have to look at it from the case to case basis if in doubt try it out okay any more questions right that was a great talk thank you please applaud for this great this nice talk yeah well we've struggled