Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

RS232 Shield Not receiving data


  • Please log in to reply
7 replies to this topic

#1 WahidM

WahidM

    New Member

  • Members
  • Pip
  • 9 posts

Posted 18 January 2012 - 10:01 AM

Hi, I have managed to wire up an RS232 shield (http://www.sparkfun.com/products/449) to my Netduino by doing the following: 3.3V - VCC GND - GND D0 - TX0 D1 - RXI I am using a RS232 cable from my computer (connected to COM port 3) and using Hari's code on the netduino side(http://forums.netdui...rt-code-review/) Data is being sent from the Netduino to my PC fine but when I send it back nothing gets received on the Netduino side. I am using the same serial settings on both sides as well ( baud rate=9600, Parity = None, data bits= 8, Stop Bits =1) Does anyone know why data isnt being received on the Netduino side? Thanks

#2 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 18 January 2012 - 10:06 AM

Hi WahidM, Does both LEDs light up when you are sending and receiving data (i.e. one when sending, one when receiving)? Also--try creating a small snippet of code (just reading data from the SerialPort) and see if you get anything. It might be useful to have a simple test case to work from. Chris

#3 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 18 January 2012 - 12:37 PM

Ignoring any possible issues in the Netduino,

Your PC software may not be sending due to its flow control settings.
That could explain receive working from netduino, but sending to Netduino failing.
Check that you have "flow control - none" setup for the PC com port.
If it is set to "hardware" or "xon/xoff" the PC may refuse to send any data to the Netduino.

Hope this helps - Paul

#4 WahidM

WahidM

    New Member

  • Members
  • Pip
  • 9 posts

Posted 18 January 2012 - 01:52 PM

Thanks for your response guys. The RX light flashes when sending data from Netduino to PC however the TX light doesnt flash when sending from PC. I have also checked the flow control and its set to none (using Tera Term software aswell). I created a test app on the PC side to see when the data gets sent but still nothing happens at the netduino side. I even tried it on another Netduino board! It does look like the data is getting out of my PC as the Tx light isnt flashing, but not sure what other settings I could change PC side. Is there a way of using different Pins to represent a different COM port on the netduino to see if thats an issue?

#5 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 18 January 2012 - 03:27 PM

Might be worth trying to loop back the PC serial data back to itself. e.g. connect pin 2 and pin 3 on the back of the PC together and then type something in your terminal program and see if you get an echo...

#6 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 18 January 2012 - 06:04 PM

... and try the same thing at the Netduino. Disconnect the RS232 break out board, and then connect D0 to D1. That will allow you to verify the Netduino's serial code.

#7 WahidM

WahidM

    New Member

  • Members
  • Pip
  • 9 posts

Posted 25 February 2012 - 10:22 AM

... and try the same thing at the Netduino. Disconnect the RS232 break out board, and then connect D0 to D1.
That will allow you to verify the Netduino's serial code.


Sorry for the late reply on this.

I swapped over the PINS and it seems the netduino isnt receiving any data, although the TX light flashes on the serial shield to indicate activity. Could this be something to do with my Netduino?

#8 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 25 February 2012 - 03:46 PM

Hi there, The results seem a bit odd. Would be good to go back to basics: Try disconnecting the shield completely (and any other shields), then connect the tx and rx pins on the Netduino board and try sending from the Netduino back to itself again. This will rule out any issue with the shield's rx circuit. If it works without the shield - there is an issue with the shield. If it fails, there is either: - an issue with the Netduino hardware, (in which case, try using the rx pin as a gpio to check it works as an input) - or an issue with the software (in which case I can't help, I have not yet used the Netduino UART). Paul




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.