
- Mattster likes this
![]() |
  | |||||||||||||
![]() |
|
![]() |
||||||||||||
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.
Community Stats
13
Good
User ToolsFriendsFred hasn't added any friends yet. #29099 Prototype module prototyped on a prototype Protomodule
Let's not forget that with a lot of hobby projects it's the journey not the destination that's the important bit.
Maybe Aaron and Dan aren't making the protomodule because it fills a gap that other existing tools don't support, but because they want to and are having fun.
![]()
#26311 Redacted 00101100
So - who here is pretty sure that they'll be ordering one no matter what it turns out to be? Probably quite a few of us.
![]()
#12119 Getting Started Hardware
#1 thing you'll need is an idea for a project. It doesn't have to be anything complex (and probably best it isn't) and will give you a focus and a clearer idea of what you'll need.
I have to disagree on the oscilloscope. It's a great bit of kit but not cheap and you may never need it. Buy one if you find you need one, not before. A logic analyser is cheaper and more likely to be used, but also not essential to start. I'd say the starter kit would be:
Then just start tinkering. Get an external LED under Netduino control (via a transistor and current limiting resistor). Get some device working - a serial LCD display might be easiest. And just keep going from there.
#11655 Netduino Mini based GPS puzzle box
Well, I finally completed my first Netduino Mini project - a GPS-based puzzle box for my nephew's 8th birthday. It's inspired by a couple of project I'd seen - a reverse geocache box and a steampunk compass. I'd also done a standard netduino based box similar to the reverse geocache for a friend, but I wanted to do a little better and the Mini was just perfect for it.
The plan was to take my nephew via a few locations and perhaps involve a bit more than just the GPS. In the end he had to do 6 challenges. The first 5 were to find a certain point. He had a descriptive clue and sometimes wither a distance countdown or an arrow pointing in the right direction. The final challenge was to find some magnetic ball bearings and put them on the lid, operating a reed switch and unlocking it. It all went well with only a couple of minor hitches. Some photos Link to full size ones. Source code Attached as ZIP. The components
Things that worked well
Things I'd do differently if I did it again
Things I would have improved given more time
The result It worked really well. As his favourite thing at the moment is the film "How to train your dragon" it had a Viking theme. He pretty soon sussed out that I'd made the box and it hadn't been "left with me by some Viking who'd knocked at the door", but he played along. ![]() The arrow went crazy at one point and pointed completely the wrong direction. Probably a bug in my code, but was conveniently blamed on crafty dragons that were trying to fool him. I wish I could use that sort of excuse at work! The second coordinate where the arrow was used it worked fine. All up, it was weeks of effort and a far more expensive than the present it contained, but great fun to do. Attached Files
#8689 NEWBIE ON DIGITAL INPUT
Debounce is a very common problem when dealing with the switches. Here's some code I used recently that does a couple of things.
1. Debounces by ignoring any further interrupts within 500ms. (Tune this if you need to catch quicker presses.) 2. Adds two events OnPress and OnLongPress. For long press it checks every 500ms and if the button's still down after 3s it fires OnLongPress. using System; using Microsoft.SPOT; using Microsoft.SPOT.Hardware; using System.Threading; namespace Fred.Useful { /// <summary> /// A debounced button wired to an input pin. /// </summary> /// <remarks> /// Ignores clicks within 200ms /// Has simple OnPress and OnLongPress events (3s) /// /// </remarks> public class DebouncedButton { const int DEBOUNCE_TIME = 200; const int HOLD_SAMPLE_TIME = 500; const int HOLD_COUNT = 6; InterruptPort _button; DateTime _lastButtonPress = DateTime.Now; Timer _timer; public delegate void PressedDelegate(); int _holdCounter; public DebouncedButton(Cpu.Pin pin) { _button = new InterruptPort(pin, true, Port.ResistorMode.PullUp, Port.InterruptMode.InterruptEdgeLow); _button.OnInterrupt += button_Pressed; _timer = new Timer(timer_Fired, null, Timeout.Infinite, Timeout.Infinite); } public PressedDelegate OnPress; public PressedDelegate OnLongPress; private void button_Pressed(uint data1, uint data2, DateTime time) { // Debounce - ignore multiple presses within 200ms if (time < _lastButtonPress.AddMilliseconds(DEBOUNCE_TIME)) return; _lastButtonPress = time; _holdCounter = 0; // Set up timer for OnLongPress if (OnLongPress != null) _timer.Change(HOLD_SAMPLE_TIME, HOLD_SAMPLE_TIME); // Fire event if (OnPress != null) OnPress(); } /// <summary> /// Check whether the button's still being held down /// </summary> /// <param name="state"></param> public void timer_Fired(object state) { if (_button.Read()) { // Button released _timer.Change(Timeout.Infinite, Timeout.Infinite); return; } Debug.Print("Holding x" + _holdCounter.ToString()); // Keep sampling. Button's not been held downlong enough if (++_holdCounter < HOLD_COUNT) return; // Fire event if (OnLongPress != null) OnLongPress(); // Stop timer _timer.Change(Timeout.Infinite, Timeout.Infinite); } } }
#7291 AT Commands and RS232
I just happen to have a Sony Ericsson lying around, so may well look at doing this sort of thing when I get a chance.
A quick google around suggests that the communication with the phone could be either 0-3.3V or 0-5V (depending on model) rather that +/-12V RS232 levels. You may find the SE data cable is dropping the +/-12V from the PC down to these levels at the phone end. If you investigate a bit further it might be possible to avoid the need for a RS232 shield. I could well be wrong though.
#6206 Save Custom Settings
Option 3 sounds good. If you could allocate some of that 8K block to the user and allow easy C# access I'm sure it would be really useful.
Anything more than that really should be on an SD card or EEPROM, but when you just need somewhere to stick a few bytes of config that seems like overkill.
#6119 Save Custom Settings
A little bit of digging on this forum and it seems EWR is not supported on the Netduino range as it would take up 16KB of valuable code space. In my case I could probably spare the space, but quite understand that Secret Labs are putting effort into supporting more useful stuff that creating a seperate firmware build that includes EWR.
http://forums.netdui...reference-work/
#5416 Updated web server
I'll post the code later in the weekend but I'm so excited I had to let you know that I've now got the Netduino Plus webserver handing out files from the SD card. To be honest it isn't tricky, just a File.Exists() and a looped FileStream.Read / Socket.Send. However, there is something magical about seeing XML, XSL, CSS and JPG files being dished out by this tiny device and forming a (small) working web application.
![]()
#4246 Updated web server
An updated simple web server for the Netduino Plus. Obviously based on the SocketServer .NET framework example and code posted here by oz-solutions and hari.
Some slight tweaks to headers should help prevent lost requests when using IE9 beta.
Has a Request object to help with parsing the incoming request.
Threaded so your code can get on with whatever it's doing and still respond to a http request.
[30/11/2010 - project updated]
Attached Files
#1895 Netduino Without Headers
I got one of those. Voice controlled too. Works really well, but she does make me put up shelves and dispose of spiders.
#1737 Arduino shield compatability list
Maybe I missed it, but is there a list of Arduino shields that have been verified as compatable? If not, can I suggest one of the forum moderators adds one (and makes it a sticky).
Not got a Netduino yet, but I'm probably about to jump in - just checking a few things like this out first.
| ||||||||||||||
![]() |
||||||||||||||
![]() |
|
![]() |
||||||||||||
![]() |
This webpage is licensed under a Creative Commons Attribution-ShareAlike License. | ![]() |
||||||||||||
![]() |