Jump to content
Sign in to follow this  
piZviZ

Reading HEX file into LabVIEW...

Recommended Posts

I am able to read HEX file into Labview using read from Text file..I am getting data into labview in terms of string.

 

Problem =>  Now i want to load this HEX file into microcontroller using VISA-rs232 .Is it require to further conversion or i can load HEX file(in form of string) directly into microcontroller ?

rs232.vi

Share this post


Link to post
Share on other sites

You'll need to provide a lot more information about the microcontroller and how to program it before we can answer that question.

Share this post


Link to post
Share on other sites

One thing that might help as a start, is the fact that the ECU Measurement and Calibration toolkit has an example for programming an ECU using an S file or HEX file.  Now the actual data going down is specific to the device and interface being used.  But the example shows how to parse a HEX or S file into an array of chunks to be sent down.  This toolkit is not free, but if you install the trial, these VIs are part of the example, and parsing the HEX file can be done without needing a license.  The license in this case allows you to program an ECU over a CAN interface.

Share this post


Link to post
Share on other sites

I am using Atmega8 microcontroller.And i want to program it from Labview(Load Hex file).

I want to use RS232  protocol to load program into microcontroller.

 

 

 

I heard that it is required to have bootloader program in controller for doing this thing.. 

Share this post


Link to post
Share on other sites

XLoader can be used to load HEX files to arduinos over serial.  This likely uses a stripped down version of AVRdude and that is a command line program that could be used from LabVIEW.

  • Like 1

Share this post


Link to post
Share on other sites

If you want to program your device through a direct serial connection to the microcontroller, then yes, the microcontroller needs to be running some code (a bootloader) that knows how to interpret the data it receives and write it to the appropriate memory locations. Getting that bootloader code installed in the first place requires the use of an external programmer (another hardware device). Whether you need to do any additional processing of the hex file before sending it depends on the bootloader. If the bootloader knows how to interpret the hex file format, then you don't need to do anything. However, if the bootloader expects data in some other format, then you'll need code to do that conversion.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Similar Content

    • By govindsankarmr
      Hi, 
      I am looking for a paid or free course online for LabVIEW instrument control that covers topic like  communication protocols, RS232. GPIB etc. Can anyone suggest a good one. Thank You.
      Govind
    • By Randy_S
      Good morning,
      I have a DLL I created (in Labview)  that takes in string information, does some magic crunching on it to create a password that is passed out as a string.  This DLL will be called from CVI and probably from a C# application.
      This should be so simple, however I cannot figure out how to pass the string in and get the modified string out of my DLL.
      I've had no luck at all getting this DLL to work by trying many different things.  It crashes LV, returns and error, or simply passes nothing out during my trials.
      I've included the project (its small) in zipped format.  Can one of you kind souls take a look at my code and tell me what I'm doing wrong, or what I need to do correctly to both, configure the DLL and then call it from LabVIEW?
       
      Thank you!
       
      Randy
      Password Generator.7z
    • By Bill Gilbert
      For years now in the student labs we've used firewire video cams and the IMAQ 1394 driver to create AVI files which then get read and converted to intensity arrays for motion analysis in a Labview app. The cheap cams are going extinct, and they want to use I-pads to create the videos which are MOV Quicktime format. So far it looks like the I-pad app they want to use can't be made to spit out an uncompressed AVI. So now I need to find out if I can either:
      1) automate conversion of an MOV to uncompressed AVI and continue to use our LV analysis app as-is, or
      2) find a way to parse a compressed MOV video to a frame-by-frame intensity array, and build that into our LV analysis app.
      I am starting to search, but is anybody aware of an existing library or methods so I don't reinvent the wheel?
      Thanks,
      BG
    • By awang_synovus
      Name: RCF LVS Conversion Toolkit
      Submitter: awang_synovus
      Submitted: 20 Mar 2015
      Category: *Uncertified*
      LabVIEW Version: 2009License Type: BSD (Most common)



      Hi Everyone,
       
      We have recently developed a toolkit that allows you to use Quick Drop plugins in Right Click Framework or LabVIEW Speak platforms.
       
      Named RCF LVS Conversion Toolkit, this toolkit provides an easy solution for JKI Right Click Framework (RCF) and LabVIEW Speak (LVS) lovers who want to use a quick drop plugin in RCF or LVS.  Now, you wont be disappointed when you see a useful plugin not written in your favorite platform's plugin format.
       

       
      Procedures are simple:
       Open the toolkit by going to Tools Menu >> Synovus >> RCF LVS Conversion Toolkit...  Select the target Quick Drop plugin VI  Type the command name in Right Click Framework or LabVIEW Speak  Click OK  
      Now you can use the Quick Drop plugin in Right Click Framework or LabVIEW Speak platform
       
      Features:
       Automatically converts a QD plugin to RCF or LVS plugin format  Warns the user if repetitive commands are installed.  Provides an instruction as user clicks help button.  Helps the user navigate to the plugin folders (LVS, QD and RCF)  Modifying the functionality in Quick Drop VI will automatically update the functionality in Right Click Framework or LabVIEW Speak  
      Please let me know if you have any questions. Suggestions and comments are welcome 
       
      Note: RCF and LVS only update their lists of commands at startup. If you use the RCF LVS Conversion Toolkit when RCF and LVS are open, please restart these platforms.

      Click here to download this file

    • By Manudelavega
      As far as I now there is 2 way to define how to format a numeric into a string using the floating point representation (%f):
       
      - Setting the number of significant digits (%_2f)
      - Setting the number of digits or precision (%.2f)
       
      However I often find myself in the need of a way to define the width of the string. For example I always want 3 digits maximum. Using significant digits won't work if the number is 0.0012 since this only has 2 significant digits, so the string will be 0.0012 even though I would like to see 0.00 (so 0 if we hide trailing zeros).
       
      On the other hand, using digits of precision won't work if I have a number like 123.45 since it has 2 digits of precision, so the string will be 123.45 even though I would like to see 123.
       
      Now the obvious brutal way would be to use a string subset and only keep the first 3 digits (I guarantee that my number is never bigger than 999). But I really hope there is a more elegant way. I can't imagine that nobody has run into this requirement before. How did you tackle it?
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.