S
S
Sergey Doronovych2016-11-10 16:34:28
Microcontrollers
Sergey Doronovych, 2016-11-10 16:34:28

Is it possible to write firmware for a microcontroller in C++?

Good day, I would like to try my hand at programming microcontrollers, I know C ++ and python from programming languages, but after searching the Internet I found only information on programming in C, and then the question arose whether it was really possible to write a program for a microcontroller in C ++, if yes, then you can have some books or articles - where to start and where to dig.

Answer the question

In order to leave comments, you need to log in

9 answer(s)
E
evgeniy_lm, 2016-11-11
@SergeyDoronovych

Can. Atmel Studio for example. But it's easier for a beginner to start with Arduino, it's not quite C++, but almost. You also need to understand that microcontrollers are only half programming. the other half is electronics.

A
Armenian Radio, 2016-11-10
@gbg

Arduino library is C++

M
Maria Maltseva, 2016-11-11
@Moriam

It is possible, but the problem is that C++ chips eat up a lot of memory - for desktop applications, for example, a couple of kilobytes may not be critical, but on microcontrollers every byte is valued.

T
TyzhSysAdmin, 2016-11-10
@POS_troi

Is it possible to write firmware for a microcontroller in C++?

It is possible, but not necessary. And again, what kind of architecture do you want to use - ARM * / AVR / PIC, you can play around with armies in c ++, since there are a ton of flash)
Well, at the expense of literature, etc., let me give you two
easyelectronics links. ru
radiokot.ru
I think the links to these two sites can't be called advertising :)

F
freeExec, 2016-11-10
@freeExec

Realistically, why not. Another thing is that usually in such tasks there is no abstraction for abstraction and monstrous patterns. Here it is much more difficult to write without new :)

A
Alexander, 2016-11-10
@NeiroNx

First you need to choose a microcontroller - preferably one of the popular ones so that there are no problems with the availability of free software for development.
In general, one of the simple ones is to buy a scarf with STM32 or simpler
Download CoIDE or assemble it yourself on the basis of Eclipse

S
sitev_ru, 2016-11-10
@sitev_ru

searching for information on the Internet, I found only information on programming in C
Even in this case, if we consider C++ as a special case of C, then we can )

R
Rou1997, 2016-11-10
@Rou1997

It is possible if there is a C ++ compiler to an assembler of a suitable architecture.
Start unequivocally with the choice of a microcontroller depending on the tasks, otherwise it may be visually possible to program for some solution from Siemens, but it costs $ 1000, and its GPIO terminals are so huge that you cannot clamp the LED leads in them, it will fall out , and it will also need 3 phases to power it :)

R
Rsa97, 2017-02-02
@Qairat

OLD cannot be changed, this is the contents of the line before the change. You can only change NEW, what will be written to the line when changed.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question