LabVIEW Embedded

cancel
Showing results for 
Search instead for 
Did you mean: 

Accessing the serial port of the ADSP-BF537 EZ-KIT Lite using the LabVIEW Embedded Module for Blackfin Processors

Hi Macbeth,

Thank you very much.

So to access UART 0 of the BF537 evaluation board you have the port number as 0, right?

To write:
If i want to use the Serial Write.vi would would just connect the UART Ref out indicator to the port number of the Serial Write .vi correct? And i would just add a string constant to its input?

To Read:
First i have to use the Bytes At Serial Port.vi to be able to get the byte count needed for the Serial Read.vi, right? To do that I connect the UART Ref out to the input (port number) of the Bytes At Serial Port.vi and finally connect the byte count output to the  requested byte count input of the Serial Write.vi and use the UART Ref out again for the same vi's port number. Am i okay with that?

I can see that you know a lot about Embedded programming and the BF537 processor..... :0
Is it possible if i do a loopback scheme using my bf537 processor? What i wanted to do was to open the UART 0 port of my bf537 evaluation board, Write a string message (say my name "Jorge"), send it through the RS232 port (which is the UART 0 port right?), then the same data sent will loopback to the same RS232 port (UART 0) right after the transmitting the data, then finally displayng the data to an indicator.

How do i do this?
I tried doing it with what you gave me in your previous mesage but i don't know if i did okay... 🙂 - because i am not gettiing any loopback.
Should i short (with a wire) the transmit and receive pins of UART 0 for me to have a loopback? (just like the Basic Serial Write and Read.vi found in the Example Finder)
If i should which pins should it be? pins 2 and 3?

Thank you very much Macbeth... Smiley Happy

0 Kudos
Message 11 of 22
(6,114 Views)
I believe you have it , Jorge.Although I'm not sure about the loopback test. It's true that you simply short pins 2&3 together, however, I've never tried it on embedded code. I simply use a cable  to connect to my host (PC via hyperterminal or a regular LabVIEW application)

"I can see that you know a lot about Embedded programming and the BF537 processor....."
Hardly... no love for this stuff at all. 
Lots of frustration......be sure to write down everything you do.
Report back if the loopback  works for you. Maybe I'll try it on my end, too.
Good Luck.



0 Kudos
Message 12 of 22
(6,089 Views)
Hey,
did you success to use the UART connection of your board ? I have a bf533 ez kit, and the exemple I found doens't work....
Best regards,
V-F
0 Kudos
Message 13 of 22
(6,069 Views)
hi MacBeth,

I didn't have the time to test the loopback procedure i was asking you before because i run out of time. Smiley Happy So I can't say if it's not working or not.

Altough i was able o establich communication between the UART 0 port of the blackfin processor with my PC's RS232 port. That's enough for now. Smiley Happy

Thanks a lot for your help. I could not have done it with the information you gave me.

Thank you! Smiley Happy

Sincerly Yours,

Jorge
0 Kudos
Message 14 of 22
(6,055 Views)
ramses64,

Yes, i was succesful with cummunication. Try the UART VI's. That's what i used.

Jorge
0 Kudos
Message 15 of 22
(6,053 Views)
Hey,
thanks for your answer.
I tried the UART echo.vi (see attached file), but nothing happened ! I think my problem comes from the callback VI reference that I should link, but I don't know how ! It is written that the BF UART OPEN has to be put as interrupt in the build specification, and it what I've done, but no echo on my serial port !!
Could you help me ?
thanks,
vincent
V-F
0 Kudos
Message 16 of 22
(6,048 Views)

Hi ramses64,

I would suggest doing the following two things to make the loopback work.

1) Provide a Call Back VI (BF UART Get Callback Arguments.vi ) for BF UART Open

2) Use BF Device Enable.vi after opening and configuring the port.

Hope this helps.

0 Kudos
Message 17 of 22
(6,022 Views)
Hi Nitin T,
I've done what you said (see attached file .jpeg), but nothing happend ! My question is the interrupt vi (in the build properties window), when I choose the BF UART Get Callback Arguments.vi  as interrupt vi, there is an error, whithout arguments...  Smiley Sad If i remove the vi, no error, but nothing on my serial port...
Thanks for your help,

V-F
0 Kudos
Message 18 of 22
(6,008 Views)
Hi every one!
I have a ADSP BF537 EZ kit lite and i would control RF receiver by UART 0. when i program for PC to driver it,  everything is OK. and i have checked TX and RX pulse at pin 2 and pin3 of DB9 connector, these pulses were smooth.
 But when i try driving by ADSP BF537 EZ kit lite using UART 0 with labview embedded for blackfin by using BF UART open VI and BF UART control VI anf BF UART write VI for on/off power only( just send H101) but nothing happened!.
 I have checked TX pin, it has output pulse but these pulse are very distort .
Anybody can help me to solve this problem
thank you very much !
 
0 Kudos
Message 19 of 22
(5,319 Views)
Hello!

I'm also having some problems with the UART of the BF537. I have two serial ports on my hardware, one (Serial Port 0) is connected to the PC, the other one (Serial Port 1) is connected to a uBlox GPS. For the start I just want to read the data from the GPS and forward it to the PC (later this functionality has to be included in a larger software which is already reading a lot of sensors).

The program works without problems when I use "BF UART Control", "BF UART Open", "BF Device Enable" and "BF UART Read" for Serial Port 1 (receiving GPS data) and "Serial Port Init" and "Serial Port Write" for Serial Port 0 (sending to the PC). However since "BF UART Read" blocks when there is nothing to read, this is not usable for the larger software block.

When I change it to use the generic methods for reading on Serial Port 1 ("Serial Port Init", "Bytes at Serial Port" and "Serial Port Read") the program doesn't work. The configuration for "Serial Port Init" is done using the same values as "BF UART Control", so I think it should work, especially since "Serial Port Write" works on Port 0 (however I haven't tested this on Port 1).

Is there any difference in the numbering scheme of the generic serial methods and the BF UART methods? Is there anything else why this doesn't work? Is there any example how receiving serial data works with interrupts (in the case that the generic methods really don't work)?

thanks & best regards,
Markus Schabel
0 Kudos
Message 20 of 22
(5,063 Views)