Hi friends please help me on the following problem.
Problem:
Needs to communicate with UART of MSP430 and PC serial port using printf(), scanf().
Controller used: MSP430F169
Compiler used: Code composer Essentials V2.0
-
I wrote a program which has printf (“Hello World\n”); statement. I have included necessary header files. Selected the CIO functions and put heap size and stack size as 300. The program is Compiled and loaded to the microcontroller. I have opened the Hyper terminal and set the baud rate=19200 as per my UART settings and put flow control=none. Then I reset the microcontroller. I couldn’t get data to the hyper terminal. When I simulated the code I couldn’t get any thing on the UART0 transmit buffer [in the compiler register] also. Please help me to make my program working. Whether I need to change the files in the rtssrc.zip folder to retarget each character to the MSP430’s UART transmit buffer. Can u give me a modified file with necessary steps. I have very limited knowledge in embedded C. Please help me it is very urgent.
-
I am really confused whether I need to change the files in the rtssrc.zip folder. I am not able to understand the program flow of printf.c in the rtssrc.zip folder.
-
As an experiment I have done the following,
a. I have unzipped the rtssrc.zip and modified the printf.c and put a putchar function in it [ putchar (*buf) ].This putchar() function is made by me and here, each character will go to the UART0 transmit buffer. I have deleted the standard putchar() in the rtssrc.zip and placed my putchar() there. Now I have zipped the file back and compiled my project files. I simulated it in the CC Essential and I found nothing is coming to the UART0 transmit buffer.
b. I thought the rtssrc.zip was not compiled and so I read the slau132a.pdf users guide and tried to do gmake.
c. I have copied the gmake to the same folder where the rtssrc.zip is located. Then using the command promt I reached upto the parent folder of rtssrc.zip [ie. Lib folder] and tried gmake. Then I got a message saying that “nothing to do”. I don’t understand about the gmake, so I may be done wrong with gmake please clarify me.
d. Also I tried mk430 and ar430 commands but I couldn’t get any understandable comments.
Please tell me how i can make the code working.