Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

What IC can i program with perl?

Status
Not open for further replies.

Flex

New Member
Im an acomplished perl programer made a few perl modules that can be found on cpan.org. I have heard a few people say perl can be used to wright the programing on chips. So that got me iterested.

Although I have never wrote to an EPROM or how ever it works, i bet its not to hard.
If anyone can provide a model number and/or manufaturer, thank you.
 
You should be able to do this, so long as you can find a PIC with 2MB or more of memory for a stripped-down perl interpreter (and that's before you include any of the libraries which make it so useful). Add that on top of that fact that high-level scripting languages like perl, PHP, python, etc. trade off RAM for ease of use and high-level features for RAM and you'll have a hard time finding a PIC or AVR which can do the task. EDIT: Then you'll also need the space to run an OS underneath the perl interpreter.

In other words, not really. Even if you could, timing control would be impossible.

Your best bet would be to find a small SBC or SOM (single-board computer or system-on-module) on which you can run a small Linux distro, and run perl on that. I'd look into Gumstix or a TS-7400 or something.

In general, though, I'd consider trying to program most PICs in perl as something akin to lake fishing using an aircraft carrier: it's just the wrong tool for the job. For one thing, accurate timing (down to the processor cycle) is often required for uC programming, and there is no way you're going to get that kind of control using perl. C is a much better choice, and even then, timing issues can be confused by the compiler.

Your best bet (even though it may seem painful at the beginning) is to learn to use the right tool for the job. Learn C and assembly and you'll get a lot more done and be much happier with the results. Like 3v0 said, for somebody coming from perl, C syntax should be no problem. String handling, which is perl's main strength, however, is almost completely absent from C and you are typically responsible for handling it yourself.

Anyway, good luck, whatever you decide to try.


Torben
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top