Usage example:

#include "print.h"

int main() {
print("number:", 25,
"fractional number:", 1.2345,
"expression:", (2.0 + 5) / 3
);
}
number: 25 fractional number: 1.2345 expression: 2.33333 Generic calls are not only easier to type than standard printf (), but there will be no more compiler warnings that the format character after% "is of the wrong type.

Genericprint, can print all major C types, integers, signed and unsigned, floating point and pointers:

char *s = "abc";
void *p = main;
long l = 1234567890123456789;
unsigned char byte = 222;
char ch = 'A';
print("string:", s, "pointer:", p, "long:", l);
print(byte, ch)
string: "abc" pointer: 0x402330 long: 1234567890123456789
222 <0xDE> 'A'65
Different types are displayed in different colors, the palette can be customized, or the color can be turned off altogether.
Tags: printf
Papay 10 march 2021, 16:00

imageGALILEO by Intel®. Honestly taken from here (https://www.ema-eda.com/sites/ema/files/Constraint%20Management.zip) and maintenance of the developed electronic product.

There will be no secret knowledge or revelations. I will just describe a number of tricks that help save a little time on debugging and a little more of your own nerves. All this separately, obviously, can be found on the net in one form or another.
All of the following is by no means the ultimate truth, but just the private professional opinion of the author.

And further. If you recognize only EPSN-40, solid rosin and soldering fat, apply sealant sausages with your hands and trace in the sprintlayout, most likely some tips and ideas will not work for you, so feel free to skip them and do not waste your time and nerves on proving that that everything works anyway.
Tags: chip
MeLavi 9 march 2021, 14:19

image

In the early 1960s, the world was dominated by Fortran (IBM's John Backus) for scientific and Cobol (IBM's Jean Summet and Department of Defense) for commercial use. Programs were written on paper, then perforated on cards, after which the results of their execution were waited for the whole day. Programming languages were considered important assistants and accelerators of the programming process.

In 1960, an international committee published the Algol 601 language specification. For the first time, a language was defined by well-defined constructs and a precise, formal syntax. Two years later, it became clear that some fixes and improvements were required. However, the main task was to expand the range of applications, since ALGOL 60 was intended only for scientific computing (computational mathematics). To work on this project, a Working Group (WG 2.1) was assembled under the auspices of the International Federation for Information Processing (IFIP).
KlauS 9 march 2021, 14:17

image

Finally, in the topic of navigation interference, we got to the coolest and most interesting. Moreover, this interesting turned out to be not so difficult technically.

This is interesting - spatial processing of signals from antenna arrays. In ordinary, especially amateur, radio communication and radio navigation practice, this is still rare. This is due to the additional multiple costs for the number of radio paths. But sometimes this is perfectly acceptable. For example, in mobile communications. Spatial processing, MIMO, is widely used here. Even a regular WiFi hotspot has had it for a long time.
Papay 5 march 2021, 22:03

image
“What's wrong with the computer - it has an nvme drive installed, but opening the explorer, if you haven't done it for a long time, takes about 10 seconds, opening the .zip file on the desktop takes about a minute, and when you press the“ Start ”key, you need to wait about 20 seconds? "

Around the end of January, I was shown a Twitter post in which a Windows user with a powerful machine talks about random freezes in Explorer. Many unscientific theories have been proposed. I don’t usually do the analysis of performance problems with strangers, but this case seemed interesting, so I decided to study it.
KlauS 5 march 2021, 22:00

In numerous popular videos and texts explaining how cryptocurrencies work, this explanation is usually given using the example of Bitcoin, the first of the cryptocurrencies. Bitcoin is actually a clean and understandable implementation of the principles necessary for a cryptocurrency: open history of transactions, the ability to check the source of money along the chain, clear rules for the appearance of money, clear rules for creating new transactions. New coins appear only as a result of mining new blocks, and the mining reward gradually decreases according to the logarithmic law, as a result of which the total amount of issued bitcoins will never exceed the limit (21 million). Any waste of money (transaction input) must match the output of another transaction, money cannot come from anywhere. To spend, you need to sign the transaction with a private key. A simple scripting language allows you to do multisig and all sorts of other useful things, including creating new currencies (tokens) based on the bitcoin blockchain (omni layer, that's how USDT lives). There is no central node, the new block is determined by the consensus of all nodes - if there are several options, they accept the branch in which the maximum number of calculations was done, this is a formal criterion that does not allow for discrepancies. Any user can run its own node, the source code is open.
MeLavi 3 march 2021, 19:57

About ten days ago, when I started updating apps in the App Store on my Mac, I ran into a curious error.

image

The internet is filled with stories of people whose Google accounts were blocked for unexplained reasons, which caused them to lose all their data, including years of e-mails, so I was quite worried. But I had never heard of such cases with Apple services and would not have expected such behavior from a company as loyal to consumers as Apple, so I decided it was a glitch and decided to try it later.
Skull 3 march 2021, 19:56

image

Today, when astronomy has returned to the school curriculum, any high school student (well, in theory, anyone) should know: the distance from our planet to the Sun is approximately 149.5 million kilometers. This distance is also called an astronomical unit.
But, it is clear that this answer somehow had to be obtained and astronomers took several steps to do this, stretching out for more than one millennium. Below - more about each step.
xially 2 march 2021, 19:26

I have been living in Germany since 2014.

Some aspects of the country are still in awe. Others want to climb on the wall and howl "why so?" I will try to reveal both those and others - and to reveal why I will stay here, most likely, until the end of my life.

imageHeidelberg - medieval Germany remained here in its original form
Programmer salaries
Well, how can you do without it? I decided to take the issue of payment to the very beginning, because if it disappoints you, then your interest in the country may immediately fade away.

Guys. Stop looking at average salaries on Glassdoor. They are always and everywhere underestimated by 20-30 percent. I know the market realities and I will name the numbers that should be guided by in 2020.
Skull 2 march 2021, 19:21

image

Not so long ago, my baby son asked me - what experiment do I consider the most important one conducted in the 20th century? He needed it for a school essay.

This simple question put me into a stupor for several hours. Because the choice was really difficult. With the nineteenth century it is easier - there it is immediately clear that the double-slit experiment *.

And with the twentieth?

Of course, if you choose by significance, then everything is simple. This "Trinity" - the world's first nuclear weapons test, which took place on July 16, 1945. Without exaggerating at all, we can say that after this test the world woke up different.

But, for all the significance of this experiment, it did not bring new knowledge. Before that, everyone knew that the bomb would explode. The experiment did not add any new knowledge.

On reflection, I decided that I should choose one of the social experiments - in the twentieth century, scientists first turned their attention to themselves - starting to study human behavior. For a person, understanding his nature is much more significant than understanding the structure of the atom.

Having considered the Stanford Prison Experiment, Milgram's experiment and Universe-25, aka Rat Paradise, I chose an experiment to breed the friendly fox of the Soviet scientist, Academician Dmitry Belyaev.
Tags: foxes
xially 28 february 2021, 12:23
... 4 5 6 7 8 9 10 11 12 ...