-1
\$\begingroup\$

I'm really interested in getting started with embedded software development. Since I already understand OS internals and computer architecture, I'm thinking of starting with .NET MicroFramework (mf) vs arduino (C based). What I'm really interested in doing is creating a home firewall/router. So far I've figured out that I need a multi-port switch controller with MAC/PHY built-in along with ethernet magjacks. The final part is hooking the controller up with a processor (arm cortex maybe) running .net mf. What I'm Not sure about is how the router will handle layer-3 routing? is it all done by the processor? or are there microcontrollers available that have layer-3/layer-2 support built into them already? If its the later, then I should easily be able to put a system together using .NET MF and the router's performance shouldn't be affected as all the grunt work is being done by the microcontroller?

\$\endgroup\$
  • \$\begingroup\$ This question seems a bit borderline to me, it seems quite high level programming... \$\endgroup\$ – clabacchio Feb 8 '12 at 8:33
  • \$\begingroup\$ its related to microcontroller programming and hardware resource constraints...so definitely not something an ordinary developer can comment on. \$\endgroup\$ – tunafish24 Feb 8 '12 at 8:56
  • \$\begingroup\$ In fact I'm not condamning or so, just wondering who could hold the answer :) \$\endgroup\$ – clabacchio Feb 8 '12 at 8:58
  • 1
    \$\begingroup\$ Not to mention, .NET MF is not the right basis to build a router in my opinion. It's a limited API especially in the networking area is just one reason. \$\endgroup\$ – kenny Feb 8 '12 at 11:06
  • 4
    \$\begingroup\$ .NET MF will hold you back. It's a crutch to be able to continue to use .NET in a world that it's almost always not appropriate for. In fact, I believe I have ALWAYS heard of someone wanting to use .NET MF in the context of someone who doesn't know what they're doing wanting to use something familiar. I can't remember anyone actually selecting .NET MF as the correct solution for the task. While you could say the Arduino environment is a crutch as well I suppose, there's a MUCH clearer path from Arduino to professional embedded work. It prepares you in the right way, in my opinion. \$\endgroup\$ – darron Feb 8 '12 at 17:01
1
\$\begingroup\$

My experience with network processors is that you will find cores that have functionality well suited for routers but they cannot do everything without help from processor/software intervention. The best I've seen is that you can set up the streams and allow the streams to be routed autonomously but the initial setup of the stream all has to be processed in a traditional way. This is most likely due to the large number of variables about the routing/firewall configuration that just isn't feasible in an ASIC. The processor will have to look at the packet and check against any firewall rules, apply any NAT or port translations and then inform the network processing to allow the stream and what modifications to make to the packet. Once these rules are in place, a well designed network processor can manage to do near wirespeed Ethernet with no processor intervention. I know Infineon and Marvell both had asics that would do this level of work but I haven't looked at either portfolio in quite some time. I doubt you will find these features in any bare minimum hobbyist type micro though.

Edit: I managed to find an example of the kind of processor I envision you hoping to get a hold of. Here's an example of a Marvel that does both GP processing as well as has hardened support for IPV6. Marvell Avanta

\$\endgroup\$
  • \$\begingroup\$ Thanks! I've also found a few Ethernet Switch Controllers from Micrel, that require tables to be specified and they take care of 100Mbps ethernet packet management. Although they are cheap $5, they only work at L3. This one by Marvell looks interesting, but I suspect it's going to be a bit expensive. From your experience, if you attach these network processors to a slow cpu, apart from the initial lookup and table entry procedure - it shouldn't have any effect on the performance, right? \$\endgroup\$ – tunafish24 Feb 17 '12 at 21:48
  • 1
    \$\begingroup\$ From browsing Micrel's website they offer a full line as well. When you look at the basic parts they do nothing except move packets from an MII interface to a ethernet physical. The top end SOC's look comparable to to the Marvell chipset I linked but I looked on Digikey on the one I looked at was ~20$. The midline ethernet controllers will take a large amount of processing power to do any Ethernet work and with a micro ~70Mhz I wouldn't expect more than 3-4 Mbps. The higher end SOC type packages with processor + Hard IP would be able to do 90Mbps with less than a 70Mhz part with ideal streams. \$\endgroup\$ – Mark Smith Feb 18 '12 at 0:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.