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.

Hawkez's Content

There have been 7 items by Hawkez (Search limited from 29-March 23)


By content type

See this member's

Sort by                Order  

#64181 Interop To Managed Code

Posted by Hawkez on 22 September 2015 - 07:39 PM in General Discussion

So, I have been working on getting NetMF working with some C++ code.  I was successful in calling native code from the managed side.  However, I have struggled to find out how to call managed code from native code.  Has anyone had experience with this in NetMF?

 

Thank you!




#63813 USB-Serial Module

Posted by Hawkez on 07 August 2015 - 02:43 PM in Netduino 3

That said...it's totally cool to hack your board ;) If you want to open serial ports COM5-COM7 (on GoBus ports 1-3 respectively)

 

I was trying to open a GoBus COM port as you mentioned here.  Is there some trick to using these COM ports on the GoBus?  I saw that there is a TX pull-up pin coming from the micro for each of the COM ports on GoBus sockets on the Netduino 3 (pin 43 for COM7).  Does that pin need to be configured as an output and set to true?  If so, how do I get to that pin in code?

 

Thanks!




#63755 SerialPort Receive Data Corruption

Posted by Hawkez on 03 August 2015 - 06:08 PM in Netduino Plus 2 (and Netduino Plus 1)

I have finally been able to post the results of a simple loopback test on the Netduino 3.

 

See the post here: http://forums.netdui...-loopback-test/

 

This test also has interesting findings for Netduino Plus 2.




#63754 Netduino 3 Serial Port Loopback Test

Posted by Hawkez on 03 August 2015 - 06:06 PM in Netduino 3

Hello,

 

In a topic on Netduino Plus 2 I said I would run a simple test on the Netduino 3 COM2 SerialPort and post the results: http://forums.netdui...data-corruption

 

I've attached the very simple serial port loop-back program that I used to test COM2 on the Netduino 3 and Netduino Plus 2.  It has two byte arrays.  One has data in it and the other is created with the same size as the first.   I transmit the data from array 1 over the serial port and receive the data on the same serial port.  The received data is placed in the second array.  After all the data is sent the two arrays are compared.  The test passes (slow .5Hz blink of user LED) when the data is equal.  The test fails (fast 2Hz blink) if the data is not equal.

 

The test uses Request to Send flow control.

 

To set up the test I jumper D7 and D8 (COM2 RTS and CTS) together and D2 and D3 (COM2 RX and TX).  I also put an LED between GND and D13 to know when data is being received.

 

The results are a bit complex.

Running the test on a Netduino Plus 2:

In debug with an SD card in the slot the test passes.

Not in debug with an SD card in the slot the test fails.

Not in debug without an SD card in the slot the test passes.

 

When the test is run on a Netduino 3 data stops being received and the test never completes no matter if it run in debug with or without an SD card in the slot.

 

Thank you!

 

Hawkez

 

Attached File  SimpleSerialPortLoopbackTest.zip   111.47KB   19 downloads




#63681 SerialPort Receive Data Corruption

Posted by Hawkez on 28 July 2015 - 02:12 PM in Netduino Plus 2 (and Netduino Plus 1)

As a follow-up, The loop-back test with flow control was successful using the Netduino Plus 2.  I was able to loop ~18K of data over the serial port and get back exactly what I sent repeatedly.

 

However, when I tried the same test on the Netduino 3 WiFi I only got back the first two chunks of data and it stops receiving data that is sent. 

 

I'll investigate further and post something in the Netduino 3 WiFi forum when I am able to.  At that point I will post a link in this discussion.

 

Thanks!




#63624 SerialPort Receive Data Corruption

Posted by Hawkez on 23 July 2015 - 12:06 PM in Netduino Plus 2 (and Netduino Plus 1)

Hello Chris,

 

Thanks for the input.  I ran my test with flow control turned on and it worked perfectly. :)

 

I did not expect for flow control to be required because of the structure of the test: send some data and do not send more until you get back the data sent.

 

The issue that took me down the loopback test road was that I saw corruption of data when using an XBee on the SparkFun XBee shield.  I'm am excited to try that again now that I know I need to turn flow control on.

 

I appreciate the help!




#63583 SerialPort Receive Data Corruption

Posted by Hawkez on 20 July 2015 - 01:39 PM in Netduino Plus 2 (and Netduino Plus 1)

Hello,

 

I am using a Netduino Plus 2 and a Netduino 3 WiFi to interact serially.  When receiving data over a SerialPort I was having issues getting consistent data back.  So, in order to test the SerialPort functionality, I created a loop back test. that reads a file from an SD card and sends it over COM2.  I've jumpered the Tx (D3) and Rx (D2) pins on the header so that the data is then received.  I then take that data and write it to another file on the SD card.

 

A diff of original file and the newly created file reveals lots of differences no matter what baud rate is used.  Lower baud rates are worse than higher baud rates.  The Netduino 3 WiFi never completes the test due to lost data which may be a separate issue.

 

I've attached a file with the application and example data.

 

Is there something I am doing wrong?

 

I've also posted the same issue on the .NetMF codeplex site with no resolution.

https://netmf.codepl...m/workitem/2508

 

Thanks!

Attached Files





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.