I am using the tms570 HDK. I have configured the LIN module in sci mode. The baudrate is set to 9600. I have a usb to serial converter that I am trying to use to send data to the board. When I measure the output of the usb-to-serial converter before it is connected to the board, I can see all the uart messages being sent out. However, once I connect the board to the converter and try to see the messages, I find that the line (TX from usb-to-serial, LINRX on board) seems to be pulled high the entire time. Any ideas?
Did you check this other thread talking about SCI?
Please have a look and let me know if this will help.
Also, are you using HalCoGen to generate your startup and driver code? If yes, can you share the configuration file so I can try to reproduce your issue on my setup?
If my reply answers your question please click on the green button "Verify Answer".
Yes sir. I actually did look at that post when I was debugging my code yesterday. I am using an RTOS (uc/OS-II to be exact) in combination with Halcogen to generate some of the driver code. Since I posted this yesterday, I have moved over to trying to use the LIN module (configured in SCI mode) in interrupt mode. I have physically connected the LINTX to the LINRX and then I send out a char and see if the interrupt gets triggered. Alas, I am still having issues because it still does not seem to be working. I have attached a copy of my sci.c file, as well as the receive_data_task, which is the uC/OS-II task that is responsible for sending out a test character. This task also has the sciNotification() callback function, which, if I understood correctly from the documentation, is used to place the code that once wishes to execute upon an interrupt, correct? I simply increment an integer every time the RX interrupt occurs. However, when i pause the debugger after a while, I see that the integer is still equal to 1. Any help would be appreciated.4863.sci.c3225.receive_data_task.c
I've create a quick project using HalCogen to configure SCI2 with receive and transmit interrupt.
I did not check this code on hardware, I will do that tomorrow, but this should give you a starting point.
The SCI2 is setup has 9600 Baud, 8 bits, 2 stops.On the HDK board this sci is connected to an FTDI chip that performs a serial port emulation over usb.So when your board is connected to a PC, you will have a serial/USB com port available. You can use any Windows terminal emulator on this port to receive and send data. There is no hardware to add or signal to connect.
Please let me know if this help.
Here is the project....
Thank you for the code. I will look it over. I have, in the past, been able to get the SCI module to work perfectly. Unfortunately, I am not having as much luck configuring the LIN Module to support SCI. Would you be able to possibly look at my code and see if there are any noticeable errors. Also, was I correct when I thought sciNotification() is used to contain the code that is called upon the RX interrupt?
The last thing that I wanted to check was if I had all the correct source files in my project. As I mentioned I am using uC/OS-II as my main project, and then I used Halcogen and manually imported some of the files. I have only used Halcogen to generate the code for the LIN/SCI module. The source files that I have from halcogen, are sci.c, sci.h, gio.h, and sys_common.h. Do I need any other Halcogen files if I am to use the RX interrupt.
Thanks for your help so far.
Which device are you using? Is it a RM48 or TMS570LS3137.
On Micrium website, they have port for UC.OS-II for both devices (one is big endian the other is little endian)
I can download one of their port and make a try.If you can share your project it will be even easier for me. If you don't want to share on the forum, I can send you my email address.
Please let me know.
I would very much appreciate if you could send me your email address. Also, I am using the TMS570 HDK (LS3137).
I have sent the code to your email address. Thank you very much for your help so far; I greatly appreciate it.
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.