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.

Mark H's Content

There have been 70 items by Mark H (Search limited from 24-April 23)


By content type

See this member's


Sort by                Order  

#15623 Happy Birthday to Chris Walker

Posted by Mark H on 18 July 2011 - 09:02 AM in General Discussion

Happy Birthday Chris!



#14414 .NET Micro Framework minimun requirements

Posted by Mark H on 17 June 2011 - 04:05 AM in Netduino 2 (and Netduino 1)

WPF in NetMF and WPF on the PC are vastly different, there is pretty much no similarity. The NetMF guys have not understood what WPF is all about and pretty much just created winforms.... Don't be too impressed.



#14412 Power Netduino (Linksys WRT-54Gl)

Posted by Mark H on 17 June 2011 - 04:00 AM in Netduino 2 (and Netduino 1)

There shouldn't be a problem, just keep an eye on the temperature of the power adapter. The netduino doesn't consume much power, however if it's already getting pretty warm running the router then you might not want to put more strain on it.



#14411 Beginner advice netduino vs arduino

Posted by Mark H on 17 June 2011 - 03:57 AM in Netduino 2 (and Netduino 1)

I think you'll find NetMF far easier and much less frustrating to learn on. The interactive debugging in NetMF makes it worth it alone! You can see where your error is and step through the method to see whats going wrong. On ardiuno you cannot do this so what might take 5 minutes to debug on NetMF could take a day on Arduino if you're unlucky. Being high level languages, C# and VB take care of pretty much all the hard stuff for you, meaning you can just write the code. The libraries are simple and well named making it fast and easy to develop. All in all, you can't go wrong with Netduino :)



#14269 Servos and batteries

Posted by Mark H on 13 June 2011 - 07:32 AM in Netduino Mini

What sort of battery are you using? Can it supply enough current?



#14268 Silverlight Client and Server for Netduino Plus

Posted by Mark H on 13 June 2011 - 07:30 AM in Project Showcase

Nevyn, it appears you've deleted the images from your server? Do you have them hosted elsewhere?



#14267 OK this is not Netduino, but it could be!

Posted by Mark H on 13 June 2011 - 07:26 AM in Project Showcase

It seems like a nice idea at first, but I have a feeling it would be considered a hazard/nuisance by most security and police, especially if it's able to go milling about in traffic or where people are walking. I realise they have someone watching over it, but in a busy pedestrian area it could easily fall victim to someone talking on their phone and not looking down, as well as generally being annoying saying "hello" if nobody donates lol.



#14262 Measuring temperatures

Posted by Mark H on 13 June 2011 - 07:05 AM in Netduino 2 (and Netduino 1)

National also make the LM60 (and similar) series of sensors. They are extremely easy to use and reasonably accurate.




With 6.25mv/C, and a 424mv offset to 0C... you just need to take the ADC port value in milivolts (3300/ADC value) and subtract 424, then divide by 6.25f to get your reading in celcius.

// gain = 6.25 mV/Deg C 
            int mv = sensor.Read() - 424; // 424mv = 0 

            return mv / 6.25f;



#14261 LCD works on USB but not wall adapter

Posted by Mark H on 13 June 2011 - 06:00 AM in General Discussion

It sounds like you could have a dodgey power pack, or you're overloading the regulator on the netduino. Is the voltage regulator getting really hot? The 9v in with your current draw may be putting it into thermal shutdown. What happens if you supply 5v to the 5v pin on the netduino from an external source (such as a lab supply)?



#14260 PCB design and manufacturing

Posted by Mark H on 13 June 2011 - 05:58 AM in General Discussion

I've not heard good things about them. They don't run flying probe checks and such on their boards such as PCBCart do, nor do they check sanity of the design. BatchPCB isn't much better but they are a lot cheaper. They don't do sanity checks on their boards either, and their boards are made with similarly poor tolerances/quality. As far as I'm concerned, PCBCart is the only option for getting PCB's made. They have flying probe checks, they will check your PCB to make sure you have a copper layer (saw one at a engineering get together the other day from BatchPCB that had no copper hahaha), run a probe test over it and manufacture to excellent quality standards.



#14259 GPS - with Sirf Star III module

Posted by Mark H on 13 June 2011 - 05:43 AM in General Discussion

You'll need a PCB for that module stan4th, however in the eBay listing there isn't a land pattern so you have a fairly low chance of being able to make one easily. Being that GPS is operating in the 1.5GHz band, you're going to need to be extremely specific with the RF traces on the board. These will have to have the correct impedance, you probably also want a SAW filter at the very least in there. SAW filters for GPS units are typically not something that anything but 0201 capable machines can place (due to the very small package and very small pads). I would highly recommend buying a premade board with antenna (or at least an antenna connector) on it as well as all the pins broken out, relevant passive components and such on there. The SkyTraq boards that Chris has mentioned are very good.



#12635 Designing PCBs - what tools are you using?

Posted by Mark H on 29 April 2011 - 10:59 AM in Netduino 2 (and Netduino 1)

You can find Design Spark (quite new, i haven't yet tried it though) here: http://www.designspark.com/pcb




Eagle is at http://www.cadsoftusa.com




The nice thing about design spark is there are no limits, like eagle has. Eagle limits board size and layer count like crazy, even on paid versions!



#10183 GPIO speed (MHz)

Posted by Mark H on 25 February 2011 - 12:50 PM in Netduino 2 (and Netduino 1)

Dirty Bits, NetMF isn't designed as a real time, high speed pin toggler, it's designed to make complex high level code simple and fast to write. If you need ultra high speed, very tight timings, get an Arm Cortex chip and program it in C. If you want to implement complex functionality that is not time sensitive (ie: a few milliseconds don't matter) then NetMF is going to get you where you want to go ultra fast. If you want to dump data out really fast, you can abuse some bitshifters and SPI to do it insanely fast - this is going to require some very good programming skills and a good level of electronics expertise however.



#9750 while(true)

Posted by Mark H on 18 February 2011 - 07:18 AM in General Discussion

It actually does delay other threads, try it :) Other threads will wait up to 5ms depending on their thread priority.



#9739 while(true)

Posted by Mark H on 18 February 2011 - 01:58 AM in General Discussion

while (true) is bad to use (Thread.Sleep is the correct way) because it is basically keeping the CPU doing something constantly. This makes it so that other threads may be delayed in getting access to processor time giving you a slow response and also doesn't let the chip go into a power saving mode.



#9303 Quad.Net Quadrocopter for .NETMF

Posted by Mark H on 11 February 2011 - 03:31 AM in Project Showcase

ESC's dont care if they dont have a signal when they turn on. They need to cater for there being no R/C signal when someone plugs in the plane first then realises their transmitter is off. Once they start getting PWM they will use that - and usually not the first packet either, they typically have hysteresis in them to require a stable time on the PWM. I wouldn't worry about the minuscule boot-up time. Just go with it. I regularly turn on my planes without the TX on (I know, I'm naughty).



#8868 Quad.Net Quadrocopter for .NETMF

Posted by Mark H on 02 February 2011 - 06:38 AM in Project Showcase

If you want to spend that much money on a frame Brandon, why not get a Gaui? In my opinion, they look a lot more solid and are cheaper. The copters at the link you sent look like they are just a moulded stick design for 400-800euro. To start with, why not get a basic stick armed quad? If mine works out i can put up the design files for printing and then cutting the carbon.



#8865 Quad.Net Quadrocopter for .NETMF

Posted by Mark H on 02 February 2011 - 05:44 AM in Project Showcase

Ok well i purchased:

4x TURNIGY Sentry 25amp Speed Controller

4x Turnigy 2217 20turn 860kv 22A Outrunner

2x Woven Carbon Fiber Sheet 300x100 (2.0MM Thick)

2x Carbon Fiber Square Tube 750x10.5mm

to build a quadcopter from.

I only really need one CF sheet, however the second gives me spares lol.



#8649 Class Library

Posted by Mark H on 29 January 2011 - 02:40 AM in General Discussion

I built a library for working with Aerocomm modules on netmf, and in testing used a PC to talk to the NetMF device via the radio - 3 projects in the solution, 1 for netmf, one for the rf library, one for the PC. I set dual startup projects, with the netmf coming first. Once the netmf app is deployed, it starts the PC app. Whilst debugging, if you pause one project (or hit a breakpoint/exception) the other project also pauses which means you dont get a flood of serial data coming through unprocessed.



#8609 Class Library

Posted by Mark H on 28 January 2011 - 07:47 AM in General Discussion

Just create your library targeting the microframework, then use it with the full framework. The micro framework is less featured, hence why you target that. There is a warning on the reference in your project, but just ignore that. The other option is to have two project files in the same folder - using the same class files. One targets net4, one targets netmf.



#8603 OutOfMemoryException [UPDATE]

Posted by Mark H on 28 January 2011 - 04:54 AM in Netduino Plus 2 (and Netduino Plus 1)

Your stream buffers may be using too much memory - i've had this problem with not clearing the buffer from a serial port fast enough. Try calling .Flush() on your stream occasionally to force the data out - especially if you have just sent a large amount of data to it.



#8602 Coding style discussion

Posted by Mark H on 28 January 2011 - 04:51 AM in General Discussion

Mark,
Thank you for your comments, this forum has truly tested my ability to hold my tongue and be professional.
I will try to make a point of not posting questions that expose you to my "amateur / ignorant" coding techniques shared by ms mvps and the ms clr team.


Great community we have here.

Brandon, I think you're reading my comments in the wrong tone - i meant them as a general comment, not targeted at anyone specific. I'm an Aussie, we're pretty layed back and chill - if in doubt, just read my post as a layed back view point :)

Please feel free to take a look at these links:
IDesign have an exceptional coding standard for C#, which a lot of companies I know of base their standards on. These are basically an expansion of Microsoft's:
http://www.idesign.n...ng Standard.zip - zip with PDF.


This is what Microsoft use internally: http://blogs.msdn.co.../26/361363.aspx

The guideline for creating class libraries is a rather informative read: http://msdn.microsof...y/ms229042.aspx

And this is the book I mentioned (which I recommend every developer - professional, amatuer and enthisuast alike read) - http://www.amazon.com/dp/0321545613/ - on on Book Depository if you're not in the USA (free shipping! woo) http://www.bookdepos...sign-Guidelines



#8596 Quad.Net Quadrocopter for .NETMF

Posted by Mark H on 28 January 2011 - 03:55 AM in Project Showcase

Whoa a month, i guess i need to stop procrastinating......

heres my ideas hardware wise, would like some opinions, you mentioned using a better BEC, so I have taken it off the list open for your suggestions, keeping in mind i am trying to be very modular is the reason for the component shield

Motor	6     $6.00      $36.00 	http://www.hobbyking.com/hobbycity/store/uh_viewItem.asp?idProduct=5354&aff=104834
ESC	6     $9.23      $55.38 	http://www.hobbyking.com/hobbycity/store/uh_viewItem.asp?idProduct=6458&Product_Name=Hobbyking_SS_Series_25-30A_ESC_%28card_programmable%29&aff=104834
Props	8     $4.00      $32.00 	https://www.mikrocontroller.com/index.php?main_page=product_info&cPath=75&products_id=256&zenid=43fb24fa5fbee9bca99cea5ee6462e48
Battery	3     $19.00      $57.00 	http://hobbycity.com/hobbyking/store/uh_viewItem.asp?idProduct=7634
Battery Charger	1     $25.00      $25.00 	http://www.hobbyking.com/hobbyking/store/uh_viewitem.asp?idproduct=2055 
Frame	1     $90.00      $90.00 	http://quadframe.com/html/quad002.html
RC Transmitter	1     $60.00      $60.00 	http://hobbyking.com/hobbyking/store/uh_viewItem.asp?idProduct=8992
ITG3200/ADXL345	1     $65.00      $65.00 	http://www.sparkfun.com/products/10321
Component Shield	1     $22.00      $22.00 	http://www.robotshop.ca/ghi-component-shield-v2.html
JST Sensor Cable	20     $1.76      $35.20 	http://www.robotshop.ca/inex-jst3aa-sensor-cable.html


Sorry for the double post - however my other post is so off topic it's not funny, and I worried you wouldn't read to this part.

I'd like to make a few suggestions to you - I've been flying for 15 years, and worked for several years in a hobby shop for fun as a second job. These are of course just suggestions.

For your charger, get one of these: http://www.hobbyking...=7028&aff=19701
This will give you far more options for charging batteries, which is safer - and more versatile. I bought one of these for my father-in-law-to-be for christmas. This will let you charge many different types of battery and also discharge/cycle batteries as well which can be very handy.


For your transmitter, if you don't need 9 channels get one of these: http://www.hobbyking...=9041&aff=19701 with http://www.hobbyking...idProduct=9043. This is the basic 6ch tx and usb cable. The USB cable is just a SiLabs VCP. The controller can then be programmed by software on a PC. The software is rather ugly and not very good, but it works and will save you a bunch of money.

I assume you're getting 2 motors as spares? Those are pretty crappy and you in my experience you may have a dud in the 6, so that's a good idea.

ESC's - I'd suggest http://www.hobbyking...=4312&aff=19701 - I don't trust any ESC's except Turnigy Plush/Sentry honestly. I've had a couple of planes go down in a ball of smoke (or fire) because an ESC failed and caught fire - or the PCB turned to ash from the heat. I have pictures somewhere at home heh. Your motors max draw is only 14.5A, so 30A esc's are just extra weight. A Turnigy 18A plush has Fairchild HEXFET's rated to about 22A.

Battery should be fine, that will allow you 20A/motor in a quad copter. If you're building a Hexcopter you'll need a bigger battery, or higher C rating.

Frame: That looks pretty darn tacky for $90 - i'd want a lot more for my $90 than that. I've seen similar to that for about $40. Chris Seto can probably point you at a couple of basic stick type ones for cheap, i know he did a lot of research into them a couple of months back. Personally, I'd go for something like: http://www.foxtechfp...rame-p-196.html - these are plywood which is easy to repair and it's built extremely strong - they'll take some pretty big crashes :)



#8595 Coding style discussion

Posted by Mark H on 28 January 2011 - 03:34 AM in General Discussion

_ and m_ are all well and good for C/C++ however for C# they are redundant with the IDE making everything extremely visible. There is a reason for microsoft's best practices, I'd be happy to go through them all if you wish, however it's going to be a huge post and this thread is not the right place for it. Microsoft's best practices, or some very close semblance of are used in almost every company that develops C# software that I have seen/worked with/worked at. The only people I don't see following them are: Recent converts from C/C++, Amateurs following other amateurs bad examples, total beginners who are porting tArduino code over verbatim, and finally, people who think it makes them look cool/experienced to write code like you would in C/C++.If you're basing your best practices on a forum full of (no offence intended to anyone) relatively beginner/amateur developers with only a few professionals.. well, that's up to you I guess. Most code I've seen around Netduino/GHI/netmf and especially the SFE/Arduino forums would get you reprimanded in a corporate/company environment. Just because other people do it badly (mostly through ignorance as they are beginners) is absolutely no reason to as well. Having written best practices for companies in the past, and having reviewed hundreds of best practice documents I can confidently say that Microsoft's best practices are well adhered to in the corporate world. I've looked a Philips, GE, several mining companies, banks and many other large organisations, as well as dozens of smaller companies. Best practices are there for code readability, usability, ease of maintenance and the fact that most of it is common sense. To anyone who wants to know more about C# coding conventions, I highly recommend you pick up a copy of Framework Design Guidelines, by Krzysztof Cwalina and Brad Abrams. This is an exceptional book that is very insightful on design libraries, classes, interfaces, naming patters, etc.



#8543 Quad.Net Quadrocopter for .NETMF

Posted by Mark H on 27 January 2011 - 09:16 AM in Project Showcase

Thanks Mark that makes sense, we need to just concentrate on throttle and throttle alone.
Chris thank you for the forum etiquette reminder. The posts were fast given we we had discovered the algo at the exact same time i replied and implemented it in code, i've attached our algo. i think you might be on to something as far as making it a scaling variable that can change as the flight conditions change.

using System;
namespace Quad.Net.Commons.Utilities
{
    public class Scale
    {
        private readonly double[] _coefficients;
        private readonly double _offset;

        public Scale(double offset, params double[] coefficients)
        {
            _coefficients = coefficients;
            _offset = offset;
        }

        public double Calculate(double value)
        {
            double output = 0;

            for (int i = 0; i < _coefficients.Length; i++)
            {
                output += Math.Pow(value + _offset, i) * _coefficients[_coefficients.Length - i - 1];
            }
            return output;
        }
    }
}
namespace Quad.Net.Tests
{
    [TestFixture]
    public class ScaleTests
    {
        [Test]
        public void TestQuadratics()
        {
            Scale scale = new Scale(-1500, 0.0000008, 0, 0, 0);
            Assert.AreEqual(scale.Calculate(1000),-100);
        }
    }
}


Move your _coefficients.Length statement to it's own local variable, before you loop and then reference that. It's much faster in netMF than referencing the property.

Also, underscores are against most best practices for .Net :)




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.