Thanks for visiting my Blog, your comments will be appreciated! Come back soon for new interesting Posts.

martes, 13 de abril de 2010

Programming ATMEL microprocessors with LabVIEW

Sometimes, some products require to be programmed before any test can be conducted. One of the most popular microprocessor is ATMEL, the question is how can you integrate or automate this process within a regular testing process?. In my case, I require the use of a standard ISP Programmer from ATMEL called AVRISP MKII, which you can see below.
This is an USB programmer, take in consideration that this programmer does not feed +VCC to the microprocessor unless you modify it with a resistor and a diode to feed voltage, the other way is to externally power up the micro.
Click the slideshow below to view images about AVRISP MKII modification to feed power supply from computer USB. One consideration, this power supply is just to program the micro, please make sure that if you want to operate your product or experiment I will encourage you to use an external power supply. The diode is a 1N4148 and the resistor is a 47R0 Ohms.

Click to play this Smilebox slideshow: AVRISP MOD

Another way to do Power Supply modding can be found here.
Now, under ATMEL AVR Tools Folder you wil find AVR Tools HELP, select AVRISP MKII and go to "Command Line Software". Here, you are provided with instructions to make simple batch files that you can send directly from DOS or you can also send this from LabVIEW for automatic programming. An example of this will be:

C:\Program Files\Atmel\AVR Tools\STK500\STK500.exe -cUSB -dATtiny25 -e -if"Path and Filename.hex" -pf –vf

This, instructs the programmer to program via USB (where the programmer was setup) an ATtiny25 device with the Path+Filename.hex and verify that the flash memory of the device was programmed. The following VI shows how to do this.

You can add verification steps to ensure that the Flash. EEPROM, fuse and lock bits were properly programmed.

1 comentario:

Jasben Bolt dijo...

We've done a lot of pieces to tie HTML and LabVIEW together through web services and web sockets,
but obviously there is no seamless component integration and handling popups and thin client applications in parallel with labview has been a royal pain.

labview programming