Hacker News new | past | comments | ask | show | jobs | submit login

Hey so can I write a device driver in JavaScript and is it a good language for that? How about my dma controller and python? What am I reading here. Not a comp sci major eh? Pass me something by reference in JavaScript, please



Anything is a “good language for that” if it meets your needs. If you can run the js VM in 128KB of RAM and have decent performance, why not? I guess you would be ok with a Lisp in a microcontroller even though it would also run a VM?

Do you think Arduino would have had any success at all if you had to write C or Assembly to use it?


What's your point, exactly? You can write a driver in practically any language.

> Not a comp sci major eh?

I guess you're a comp sci major.


I was a comp sci major.

Do you know what a Pointer is?

Do you know what passing by reference means?

Do you know what a heap allocation is vs pushing something into the stack?

Do you know what code and bss segments are and what they are for?

This is not about being right or wrong, I just can’t stand to watch total nonsense go unchallenged.

No, you cannot write a hardware device driver in a dynamic language, which is not to preclude code generation approaches, but to point out what low level hardware programming actually consists of: manipulating memory, registers included




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: