Anyone wants to share an interesting/cool embedded Pascal project? lazarus / 77-Embedded ---------------------------------------------------------------------- ccrause · 2022-02-26 12:30 The list of simple but interesting Arduino based projects are near infinite.  Where are the cool embedded Pascal projects hiding? Please feel free to share! ---------------------------------------------------------------------- MarkMLl · 2022-02-26 20:31 I think that the real problem is that the value of the Arduino infrastructure is the libraries it's accumulated, which generally speaking assume C++ calling conventions and name mnagling. MarkMLl ---------------------------------------------------------------------- trev · 2022-02-26 21:19 See the Wiki: AVR Embedded Tutorials. ---------------------------------------------------------------------- ccrause · 2022-02-26 21:30 @Mark, yes the Arduino library ecosystem is very handy, but a lot of things like flashing an LED, reading a pin, using timers and so forth is easy enough to code from scratch in Pascal. This should be enough to tackle simple projects. ---------------------------------------------------------------------- ccrause · 2022-02-26 21:44 Quote from: trev on February 26, 2022, 10:19:37 pmSee the Wiki: AVR Embedded Tutorials. The tutorial section is a good reference, but not what I think will inspire people to tackle some embedded idea in Pascal. I'm hoping to see projects like a line following robot or drone control firmware, written in Pascal... ---------------------------------------------------------------------- MarkMLl · 2022-02-27 08:36 Quote from: ccrause on February 26, 2022, 10:30:32 pm@Mark, yes the Arduino library ecosystem is very handy, but a lot of things like flashing an LED, reading a pin, using timers and so forth is easy enough to code from scratch in Pascal. This should be enough to tackle simple projects. Agreed. That's /particularly/ the case when one follows through the code to read or change the state of a bit: Arduino (and others that I've looked at) try to make this general but the result is a sequence of complex function calls that the compiler can't optimise... the collective developers appear either unconcerned or unaware. But unfortunately, no matter how we loathe them, some things we're stuck with :-( https://imgs.xkcd.com/comics/new_pet.png MarkMLl ---------------------------------------------------------------------- PascalDragon · 2022-02-27 10:39 Quote from: MarkMLl on February 26, 2022, 09:31:58 pmI think that the real problem is that the value of the Arduino infrastructure is the libraries it's accumulated, which generally speaking assume C++ calling conventions and name mnagling. Which is not necessarily a problem. ---------------------------------------------------------------------- MarkMLl · 2022-02-27 10:55 Quote from: PascalDragon on February 27, 2022, 11:39:36 amQuote from: MarkMLl on February 26, 2022, 09:31:58 pmI think that the real problem is that the value of the Arduino infrastructure is the libraries it's accumulated, which generally speaking assume C++ calling conventions and name mnagling. Which is not necessarily a problem. So to what extent can interaction between FPC and C++ be promoted? The risk is that problems would cause vexation to both the FPC and embedded communities: and as a minor player FPC can't IMO afford to be vexatious. MarkMLl ---------------------------------------------------------------------- PascalDragon · 2022-02-27 11:02 Quote from: MarkMLl on February 27, 2022, 11:55:36 amQuote from: PascalDragon on February 27, 2022, 11:39:36 amQuote from: MarkMLl on February 26, 2022, 09:31:58 pmI think that the real problem is that the value of the Arduino infrastructure is the libraries it's accumulated, which generally speaking assume C++ calling conventions and name mnagling. Which is not necessarily a problem. So to what extent can interaction between FPC and C++ be promoted? The risk is that problems would cause vexation to both the FPC and embedded communities: and as a minor player FPC can't IMO afford to be vexatious. cppclass doesn't handle all types yet (e.g. signed char), so declarations might fail because the wrong mangled name is generated, and there's no way to deal with operator overloads (if any) yet. So right now I'd advertise it as “experimental” at most.