LabVIEW Embedded

cancel
Showing results for 
Search instead for 
Did you mean: 

stm32f103rb Target Files

Hi Everyone,

I'm back working on trying to get the STM32F103RB chip to work with Arm embedded without out much success. I have read through much of the threads and although they have a good lot of help none of them are helping me.

What I want to know is has anyone managed to fully port all the files to enable programming  of this chip through Keil and downloaded to the target successfully?

 

If so has anyone got the target files, for this Chip which they could post?

 

The target files I have which I got from this forum seem to cause me a bit of a headache, at the moment I'm getting the following error while building a project

.\Obj\LabVIEW.axf: Error: L6218E: Undefined symbol File_Init (referred from posixfiles.o).

.\Obj\LabVIEW.axf: Error: L6218E: Undefined symbol File_Verify_SPI (referred from posixfiles.o).

 

Does anyone have a clue why I'm getting theses errors?

 

Thanks in advance

Ollie

 

LV 2011, Keil version 4.11

0 Kudos
Message 1 of 12
(7,385 Views)

Ollie,

 

Thank you for posting this on the forums.  It would appear that your chip is a Tier 2 device ( http://www.ni.com/white-paper/7066/en#toc2 ), and porting to a Tier 2 ARM device is not an easy process and is not directly supported. The Online porting guide will help you ( http://www.ni.com/white-paper/6994/en ) but being a Tier 2 device SPI communication is not supported by default.

 

Have you had SPI working correctly before on a non-Tier 1 device?

 

Regards,

 

 

 

 

Robert Ward
Applications Engineer, NI
0 Kudos
Message 2 of 12
(7,364 Views)

Dear Ollie,

 

Have you been able to make any progress with the issue you have been having?

 

Kind Regards,

Robert Ward
Applications Engineer, NI
0 Kudos
Message 3 of 12
(7,310 Views)

Hi Robert,

 

I have managed to compile the files for the STM32F103RB and run programs with success. I have have never managed to get the SPI to work on tier 2 boards so this is what I'm working on now. Being a relative newbie to LV Im assuming that some sort of C calling is needed but not sure how to accomplish this yet, if you have any pointers I would appreciate them.

 

Cheers

0 Kudos
Message 4 of 12
(7,304 Views)

Dear Ollie,

 

The Microprocessor SDK includes the LabVIEW C Code Generator, which generates C code based on the block diagram when you build an embedded VI into an embedded application.  Next, the C code is passed with any external C code and the LabVIEW C Code Run-Time Library through your third-party cross-compiler to create an executable file. This executable file is saved on the host computer.

 

If you have blocks of C code that you cannot easily implement in VIs, you can use the Call Library Function Node.  This may be for if you want to add external C files, such as existing libraries, or the C code you want to add is complicated or large.  There also exists the Inline C Node in the Structures Palette (provided you have the Microprocessor SDK Module) which you can use for low-level programming without the overhead of a function call. (see http://zone.ni.com/reference/en-XX/help/372822A-01/inlinecnode/inline_c_node/ ).

 

So in short; you don't need to use C code.  If you have existing libraries then you can call them inside LabVIEW without having to reprogram altogether and if you are a native C coder you can use Inline C Nodes to do low-level programming inside LabVIEW if you prefer.

 

Hope this information helps.


Kind Regards,

Robert Ward
Applications Engineer, NI
0 Kudos
Message 5 of 12
(7,277 Views)

Hi Ollie,

How do you manage to solve these errors:

 

.\Obj\LabVIEW.axf: Error: L6218E: Undefined symbol File_Init (referred from posixfiles.o).

.\Obj\LabVIEW.axf: Error: L6218E: Undefined symbol File_Verify_SPI (referred from posixfiles.o).

 

I also got the following error while building a project.

 

Could you tell your solutions?

 

Thank you very much~

 

0 Kudos
Message 6 of 12
(7,228 Views)

Hi

 

Try adding the following lines of code at line 43 to the TargetInit.c file

 

void File_Init()

{

 // we initialize in TargetInit.c on this target

}

void File_Verify_SPI()

{

  // this target needn't do a thing

}

 

Also bring the Heap size down to 0.

 

Let me now how you get on.

 

Ollie

0 Kudos
Message 7 of 12
(7,203 Views)

That's Ok!Thank you very much!

Could you tell me weather your programe running on all STM3210X target and Keil simulator? 

0 Kudos
Message 8 of 12
(7,200 Views)

Hi

 

Only tested on 103RB. Can't remember if it worked on Keil sim, I will test if you want in a day or so.

 

Did your program compile with no errors?

 

Ollie

0 Kudos
Message 9 of 12
(7,197 Views)

Hi Ollie,

Thank you for reply!

 

I compiled without error,could you send me your STM32F103RB target source code for comparing?

My email:Dianling.Wang@ni.com

 

I have a try to running this code on Keil Simulator and the programe halt on the address 0X00800032E.

0 Kudos
Message 10 of 12
(7,194 Views)