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

Phony Scope


  • Please log in to reply
2 replies to this topic

#1 willgeorge

willgeorge

    Member

  • Members
  • PipPip
  • 25 posts

Posted 30 November 2011 - 11:23 AM

My gift for the holidays.. I call this project Phony Scope because traces drawn in the windows form are not by sampling of data from the Netduino. Traces are drawn from textBox(s), preset data, and trackBar values. The application is, in a way, pointless (never stopped me!) but the code may have some value to others to 'play with'. I was using a 'basic' Netduino with XBee's for communication. As to pointless.. The windows form sends messages to the Netduino telling it what to do such as set two PWM ports from the data messages sent. I already know what the data is but I have the Netduino return the message sent to it. At the form, the returned message is parsed for the Period and Duration data of the PWM signal. This returned data is then scaled for display in a pictureBox on the form. The code is far from 'perfect' but seems to work OK. There is one known issue. On rare occasions, the message string sent to the Netduino for setting the PWM has missing data. The Netduino will return a message informing you of the problem. To be blunt, I have no idea why, but at least it does not happen very often. I live near the BIG Chicago airport and I have issues with electronic items in the home at times. I 'think' it is from aircraft transmissions of some sort. Anyway, a plane is usually flying over and then have strange thing happen around here. Like hear voices on the TV and FM radio. There are some additional methods such as reading the XBee RSSI values (Now if I only knew which XBee I'm reading the RSSI from?) and for sending a 'test' square wave over the XBee serial port. The 'test square wave' is the ASCII upper case character 'U' which is binary 01010101... Yes, a square wave! (adjustable interval). Setting the PWM is provided by several options on the form. Be aware that, while some error checking is performed in the code, I did not attempt to make it 'bullet proof'. EDIT: I forgot.. I had to remove the EXE files from the form so the zip was small enought to download. You will have to compile the Form code.. Have a GREAT holiday ALL!

Attached Files



#2 Chris Seto

Chris Seto

    Advanced Member

  • Members
  • PipPipPip
  • 405 posts

Posted 30 November 2011 - 02:26 PM

I very highly doubt the issue is due to air based transmissions interfering with XBees. XBees frequency hop on 2.4G, which is not a frequency that is very close to anything air based. Review the tower/ground/approach/departure/ATIS/ILS, etc, etc frequencies for the airport near you, and you will find they are all low frequency, nowhere near the multi-gigahertz bands required to even be in the realm of possibly interfering with the XBees. You can use airnav.com to find that freq list. It should be under "Airport Communications" after you enter the ICAO of your airport. Of course, you could even test to make sure that there isn't something getting in through the communications channel by just listening to the output from the XBee you already have connected to your computer. If you get interference on one XBee, you should get it on both as they will both follow the same frequency hopping sequence.

#3 JonnyBoats

JonnyBoats

    Advanced Member

  • Members
  • PipPipPip
  • 155 posts
  • LocationPhillips, ME

Posted 30 November 2011 - 04:58 PM


The code is far from 'perfect' but seems to work OK. There is one known issue. On rare occasions, the message string sent to the Netduino for setting the PWM has missing data. The Netduino will return a message informing you of the problem. To be blunt, I have no idea why, but at least it does not happen very often. I live near the BIG Chicago airport and I have issues with electronic items in the home at times. I 'think' it is from aircraft transmissions of some sort. Anyway, a plane is usually flying over and then have strange thing happen around here. Like hear voices on the TV and FM radio.


The usual way to handle situations like this, (namely sending data over noisy communications channels where the message can be garbled) is to include a checksum ( http://en.wikipedia.org/wiki/Checksum) with the message.

Basicly the sender computes the checksum and includes it with the message. The receiver then gets the message and re-computes the checksum to confirm that the computed value matches the checkum received. If they do not then the receiver knows the message has been corrupted and treats it accordingly. (One standard practice is to simply ask the sender to re-send the message).

This may or may not be overkill for your purposes.




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.