Lily Mara
Lily Mara

Reputation: 4138

D Compiler for Arduino?

I am just getting into D, and I'm trying to figure out if I can use D for programming an Arduino. I know D normally compiles to native binaries, but I haven't had any luck trying to find a D compiler for the AVR instruction set. Does anyone know of a method for compiling D code for the Arduino?

Upvotes: 2

Views: 679

Answers (2)

Henri Cavalcante
Henri Cavalcante

Reputation: 505

Arduino usually uses a 8 bit AVR chip and I have never seen a D compiler (DMD, LDC, GDC) which can generate 8 bit code.

Upvotes: 0

DejanLekic
DejanLekic

Reputation: 19822

I do not think there is a D compiler that can target ATmega328. As Adam pointed out, GDC is your best bet, but I haven't seen anyone using it for Arduino development. I am sure GDC developers will welcome contributions towards this goal.

Building GCC that targets ATmega328 is easy nowadays. You will also need avr-libc. Ask on the D forum - maybe someone was successful.

Upvotes: 3

Related Questions