Electronics > Microcontrollers

Which programming language?

(1/13) > >>

Hi all

Not exactly a microcontroller question but it is sort of related..

For university I have used both Assembly and C18 to program PIC microcontrollers and also some VHDL for cpld.

Currently none of the projects I have worked on involved interfacing with a PC so this summer to better prepare myself for further projects I would like to learn a bit more regarding controlling/communicating with a PC.

My ultimate aim is to be able to cobble together some PC software with gui that can send commands to or recieve
data from the microcontroller via either rs232 or usb.

Obviously I need to learn a PC language but there are so many to choose from!
So I'm hoping some of you more experienced engineers can give me some advice on which to pick. I imediately thought C as thats what I use for the PIC but it seems its rarely mentioned as a language to learn for programming window gui type applications.
I have read that C++ can be difficult and that C# or Java may be easier.

Which languages do you use and what language would you say is good to learn to compliment microcontrollers on the PC?

For PC programming the choice isnt so much what language to use, it's what development environment to pick.

I still use Delphi, and despite what some people say, it's still alive and kicking.
The same company also make "C++ builder", which is identical to Delphi but you program in C instead of pascal.

I just love the speed at which ya can get something done using delphi/c++builder.

However, ive not used the competing products, such as Microsoft visual studio for ages, so i cant really say which is best overall or for specific tasks.

With regard to building gui apps to talk to microcontollers, most of the time this is just serial port comms, be it true rs232 or a usb-rs232 bridge doesn't really matter. From the apps point of view its just a com port. Any language worth anything will allow com port access. With delphi at least, you just pick/install one of the many available com port components, slap it on your form and start coding something to interpret the stream of data for display or resending. The component takes care of all the windows API calls to open the port and presents you with a nice interface to set baud rates etc.. and receive or send data.

I'm a big fan of Python, as it is very fast to implement code in, and has vast libraries for doing different things.  GUI is a little harder than Delphi or MS Visual Studio or the like.  

What you get is cross platform for free, if you use a supported library.  That may or may not be useful, depending on application.

Best bet is probably free version of Visual Studio and C#.NET.  That seems to be the norm for windows any more.

during my early age, i've tried all delphi/C++builder/msvstudio. in the end i stick to ms visual studio. thats personal preference, i dont say delphi & borland c++ builder are bad, indeed c++ builder combine the power of gui easiness and c language efficiency. but nothing beat visual basic in term of rapid gui environment, and i dont have to type the nonsense ; and : in every line and declaration. but with drawback that basic is among the most nonefficient languange, no worry, cpu power doubled every year. and whenever i need the speed, i'll couple it with ms visual C++, usually for dll making only. gui with ms vc++? mfc? a big SUX! i cannot get in my head. i'm a classic style programmer, so i dont like highly embedded classing/templating into the language. but if you still dont have side, maybe C# and vb.net is the way to go, thats the modern standard i think. tried it before, but it worst than MFC imo, i just cant get that!

Some good responses so far guys thanks, I haven't thought of visual basic but this is maybe worth considering.

@Psi, Thanks for pointing this out development enviroment is important, for now as this is learning not a buisiness venture free tools are a requirement. Also somthing self contained would be preferble as a pose to seperate text editors, command line tools etc..

@sacherjj,  I have also read that Python is the language of choice for many developers nowdays, what development tools could I use for Python? Is there an all in one IDE? or is it more text editor and command line compiling?

@Mechatrommer, thanks I hadn't considered visual basic and your thoughts seem to mirror what others have said regarding VisualC++ and a beginner on other forums.

I am aware thought that if I choose C# or VB that its a microsoft thing and I am essentially learning somthing windows only.
Java would seem to fit the bill as it seems similar to C# but is cross platform?

I will buy some books once I have decided which to go for which is why I am trying to pick one.


[0] Message Index

[#] Next page

There was an error while thanking
Go to full version