Let's not deviate from the topic, which is NMR.
This is not a deviation from the topic because I wrote a piece of software for NMR that interfaces with Itsu's equipment. I would like to finish it and when I read that you can program, I thought you might be able to help me finish it. The software would make his life easier ...and IF HE CHOOSES TO, it would allow us to do NMR experiments remotely on his equipment, such as interesting pulse sequences for spin echo experiments. I could also give Itsu remote access to my equipment and to some of you, too. The programming language used is a secondary consideration. If you ask a butcher "what knife do you use", he will tell you "the one required for the task".
Not in this case because, the part I already have is written in concrete language. For internet based applications it is often Java and JavaScript.
A necessary evil Drivers for various hardware are nowadays written in C or C++, at my time all this was written in Assembler, because it is time critical.
I think that drivers with Interrupt Service Routines should still be written in Assembler. The interrupt mechanism is always platform specific so there is no advantage in the portability of higher-level languages. A similar case can be made for code serving other hardware peripherals such as DMA, timers, UARTs, etc... Less demanding drivers can be written in C because nowadays compilers generate well optimized code. C++ is OK for non-realtime drivers, too, but its exception handling scheme is generally incompatible with SEH in kernel mode. However if one knows what's going on behind the scenes and implements all the speedups offered by it, such as R-value references then the results can be acceptable. Often the use of a certain programming language is driven by hype, like the Ada hype or Cobol in the 70ies.
I didn't know that about Cobol! I thought that in the 70s, it was all they had... I would also call Java a hype.
Oh definitely ! In my opinion any language that doesn't compile to machine code is not worth my time. All this hand-holding just takes away too much control from me as a programmer
« Last Edit: 2021-09-16, 15:22:00 by verpies »
|