Blogger Carl Cheo, who maintains a website providing numbered lists of tips for maximizing online productivity, has pulled together an easy-to-follow graphic answering the newbie question "What programming language should I learn first?" (pdf here). Cheo chose nine commercially viable languages as possible destinations as the viewer navigates the flow chart. Further down the page, there are tabs with annotated links to educational resources for each language. So what's in it for Soylentils, most of whom I'm guessing were programming newbies in the previous millenium? Well, maybe you have nephews or nieces who chose the wrong major in college. Besides, the graphic is amusing and clever, though probably not the last word on the subject.
(Score: 1) by That_Dude on Saturday January 24 2015, @09:07AM
First of all - I couldn't program my way out of a wet paper bag!
I am nearing the point where I need to pick up a programming language at my University.
I would like to choose something that would enable me to interact with various sensors, in a remote/unattended device, and the data those sensors collect.
I would like to automate some processes based on positive signals.
I would like to send collected data, images and device condition data periodically.
Power consumption is at a premium - batteries only.
When the power dies, I need for the device to pick up where it left off.
What would you suggest?
(Score: 1) by Jesus_666 on Saturday January 24 2015, @12:38PM
Pretty much everything else falls under either "you have to write that yourself" or "there might be a library for that". Sending data through a wireless modem should fall into the latter category while talking to your sensors or recovering from power failure probably fall into the former.
Hardware choice is also highly relevant. Is your hardware an embedded general purpose computer with the sensors being USB devices? Or are your sensors just hardware components that you have to wire up to something? In the latter case you might want to (for example) stick a couple sensors and a GSM modem onto an Arduino, which forces your programming language to be Arduino's dialect of C/C++. Or you work with some other platform which informs your language choice.
In general, C/C++ are somewhat difficult to pick up but teach you a lot about the underlying technology. You need to worry about things like the size of a variable in memory, safely handling pointers and freeing memory after you use it. That makes them cumbersome but at the same time they teach you valuable lessons about how a computer works. Plus, they're fast because you don't have as big a layer between you and the machine.
Java is kinda similar but takes away a lot of the low-level stuff. You don't need to worry about memory management or making sure that your strings end with a null byte. The emphasis is more on objects and their interaction. Java is verbose and somewhat bureaucratic but also has the advantage of running everywhere you can find a Java runtime. It's not terribly slow either but on embedded systems a JRE might not be available or might pose too big an overhead.
In general I'd probably recommend C or C++ if you expect to work with embedded systems. They're difficult to learn but should work pretty much everywhere, whether you're working with a small device like an Arduino or a full-featured powerhouse like a Raspberry Pi.
(Score: 1) by That_Dude on Saturday January 24 2015, @05:36PM
Thank you, it looks like I will delve into C++ since it is being offered and I don't mind the extra learning effort.
(Score: 2) by RamiK on Saturday January 24 2015, @12:54PM
For a battery powered device it depends on the Microcontroller but it's hopefully C. If you're not lucky it's either Verilog or VHDL variant or maybe even some assembly language.
For the workstation it's likely C for collecting the data, doing any live, time-sensitive processing on it, and then storing it - likely in a tabular text file - for later usage (usually importing the file into Excel).
compiling...
(Score: 1) by gnuman on Saturday January 24 2015, @05:58PM
Get together with other people in department and hire a real programmer. Ideally, one that has at least a BS in your field (or at least practical hard science field) you work in so they know WTF is happening. They'll be able to provide much better feedback about your ideas and you will not have to spend years learning things you clearly do not really care to learn anyway.
For example, a good programmer for a science lab is as important as a good machinist. But then maybe I'm a little biased here. In the end, I've seen some terrible code written by researchers where they have literally wasted away years trying to implement.
(Score: 0) by Anonymous Coward on Sunday January 25 2015, @08:02AM
i would recommend learning at least some assembly for embedded applications, since its a good way to learn about the hardware so you can get the most out of it