Вопрос

I was working with .NET Framework using C# language (WinForms, Web, WPF). Now I need to complete my university task. It should be simple program for an embedded device like microcontroller or something similar. I have no basic knowledge of digital electronics at all but i do have a little bit knowledge about C. I have a lot of time to study these things (about half year or more). So what should I do? What will be better for me?

  1. Can you suggest some books or training courses to get start with embedded systems?

  2. I heard something about .NET Micro Framework. Is it the best solution for my problem? And what device should i buy to learn programming (there are a lot of devices on eBay).

  3. Also there are many suggestions to use PIC microcontrollers and C language to program them. So i ask again about what device I need and what IDE?

P.S. Sorry for bad English.

Это было полезно?

Решение

It is quite hard to answer your question because you don't mention what you want to do. I'm familiar with microchip microcontrollers (PIC), they have a good range of development boards at reasonable price and you can get the IDE and the compilers for free from their webpage (The IDE is called MPLAB and the compiler depends on the device you use). However starting to develop for microcontrollers can sometimes be a bit frustrating if you come from the pc world. The tools have their quirks and you have to get use to them.

Another alternative to your problem may be arduino boards, they are quite cheap (in the order of $20-25) and they are easy to program and you don't need any extra device to program them. (The boards plug directly to USB). You can also get all the development tools for free from the arduino website.

The main difference I see between Arduino and PIC is that Arduino is a bit like a toy for hobbist while programming Pics in C gives you a better idea of how embedded software is developed. The good thing about pic compared to other microcontrollers is that they are quite popular amongst hobbist which means that there are plenty of books for beginners.

Depending how seriously you want to learn embedded software, I would chose Arduino if it is just for a nice and easy project and never see microcontrollers again, however if you want to really learn to write embedded software I would chose a fairly powerful development board, which would allow you in the future to run an RTOS. Depending on the development board you might or might not need an external programmer (many development board have a USB programmer onboard)

I just had a quick look of what was the .net microframework, and aparently it has only been ported to ARM cores and requires a fair amount of memory to run, so unless you get a board developed to run with .net micro framework (just came across something called netduino) I wouldn't consider it.

Другие советы

  1. Embedded systems are mostly programmed in C, with some part of the software in assembly. Therefore I wouldn't consider programming embedded systems without a good knowledge of C (how the stack works, how to modify the content of the memory at a given address ...) and a good knowledge of computer architecture (what is an interrupt, what is a backside cache, how a processor boot ...). There is a lot of excellent literature about these, you can start with Wikipedia.

  2. I don't know much about .NET Micro Framework, and I don't know anybody who works with it. For beginning in embedded systems, you should just consider another device, see 3.

  3. As praemdonck said, Microchip dsPIC with an MPLAB debug probe is probably the most affordable solution, and you can actually do a lot of things with these microcontrollers. I wouldn’t consider solutions based on embedded Linux, because you won’t go deep enough in the low-level layers to understand what embedded programming really is.

1) Can you suggest some books or training courses to get start with embedded systems?

Here is a nice online book. It is based on an obsolete micro called 68HC12, though the topics discussed are universal to all micros, particularly the pars about embedded C programming.

(68HC12 was developed by Motorola mid-90s and became obsolete around 2002. It is replaced by the modern HCS12, which is instruction compatible. For reference, 68HC12 is regarded as an old, obsolete MCU, yet it was designed 20 years after the first PIC. Just for reference of how outdated PIC really is.)

2) I heard something about .NET Micro Framework. Is it the best solution for my problem? And what device I should buy to programming for (there are a lot of things on eBay).

I work exclusively with embedded systems and I have never heard of it. So no... it is probably not a good idea, sounds like yet another desperate attempt by Microsoft to get involved in embedded systems. If I know them, it is merely going to be another flavour of a PC.

3) Also I see many suggestions to use PIC microcontrollers and C language to programming for them. Again what device do I need and what IDE?

Others have answered that. C language is definitely what you need for embedded systems. If you are a beginner at C language in general, and embedded C in particular, I would strongly suggest picking a platform with a compiler well-known for its C standard compliance. Any platform using GCC would probably be a wise choice for a beginner.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top