Does anybody know where i can get an app note for MSP430 (UART) communication with PC(RS-232).
Thanks,
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Does anybody know where i can get an app note for MSP430 (UART) communication with PC(RS-232).
Thanks,
As far as the MSP430 is concerned, it is entirely irrelevant what device is connected - it makes absolutely no difference whatsoever if it is a PC, a terminal, another MSP430, or whatever.
The MSP430 just sends bytes out from its UART, and receives bytes into its UART - it neither knows nor cares where the transmitted bytes go to, nor where the received bytes come from.
Similarly, a PC application just writes bytes out to a COM port, and/or reads bytes in from a COM port - it neither knows nor cares where the transmitted bytes go to, nor where the received bytes come from.
hi,
you may found some help typing "MSP430 code example" into google, choose the first link, and select your MSP sample codes. There are not libraries, but sample codes. You may also try a research "MSP430 uart example" and you should find a link to Configuring and Using the MSP430 UART | Gustavo Litovsky, then have a look at the tuto (this link)
Hope this helps.
Yoann Hilairet
Yoann Hilairet said:"MSP430 uart example" and you should find a link to
Yoann, thank a lot for this link, I am not new to MSP but is a good document on how to start using and I have to learn from, sure i pass to my colleague.
Regards
Roberto
HEllo,
if you want to communicate with an PC you will need to have some kind of language, like a protocoll, i for example try to use Modbus, to communicate MSP430 to PC, but you could also use youre own made language, which for example simply states that a high signal means start something and low means stop something, and this can be build up to infinite complexity :)
Or like all common Busprotocolls do, is filled up with error checks like CRC or LRC or Parity checking, etc...
The benefit of using some already establishes protocoll is, that you likely find some already made c-implementations and can adapt this code to youre device.
Hope this could also help.
Seb
Hi abhishek Sabnis,
What kind of doubts do you have? Hardware or firmware ones?
In the first case you should watch an application note for the max232 (or any equivalent chip). In the second case you could use an example code and change it according to your own needs (microcontroller, pin to be used, other functionalities, etc).
Please tell us then we could point you in the right direction.
Sincerely,
Juan M.
seb said:if you want to communicate with an PC
Again, whether it's specifically a PC or not is entirely irrelevant - whatever devices as used, they have to have a common "language" that they understand.
The "language" (or "protocol") could be as simple as just plain text strings
Andy Neil said:Again, whether it's specifically a PC or not is entirely irrelevant - whatever devices as used, they have to have a common "language" that they understand.
Andy Neil is right, there are only few things you have to consider when communicating two devices with success such as the baud rate (9600, 115200, etc) the amount of bits (8, 9) the flow control and the parity. The default configuration in the most of devices (and an easy start point) is 9600 bauds, 8bits, no flow control and no parity. You just configure your microcontroller with those parameters, open a terminal (hyperterminal, hercules, etc) also set the same parameters, connect both devices (with the interface in the middle) and I'm pretty sure you will have success.
Regards,
Juan Morant
Thanks Juan.
One question. what hardware interface do i need to have for communication?
Thanks,
Abhishek
For communication with a PC you typically need something like the MAX232, which basically transforms your 0 or 3 Volts level into the smaller than -3V and greater than 3V levels used for the RS232 interface.
Another possibilty is to use something like a virtual COM port device for a USB interface like the Silabs CP210x devices.
Bernhard Weller is right.
I suggest you to use the MAX232. You could find information about the connections you will need in the page 7 of the datasheet . The EIA-232 pins should be connected to the db9 connector to your computer, and the CMOS or TTL connectors should be connected to your microcontroller.
Regards,
Juan Morant
Hi Andy and thanks for noting my mistake.
If you are using a 3V or 3.3V device and you dont want to use aditional hardware to adapt the signals you could use a device like the max3232 (I havent used it yet) take a look in the datasheet.
Juan Morant
**Attention** This is a public forum