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

Recompiling the firmware and accessing and changing register values from C#


  • Please log in to reply
5 replies to this topic

#1 kennethone

kennethone

    New Member

  • Members
  • Pip
  • 4 posts

Posted 27 March 2013 - 08:33 PM

Good afternoon,

 

Unfortunately, I was not able to find any documentation on low-level programming of the NetDuino and I have to ask a few questions in order go beyond building standard applications for the NetDuino. I fully understand that this render my device useless and I am willing to take the risk. Also I understand that NetDuino is an open source firmware and hardware platform and modifying/recompiling the firmware is allowed under the license, please correct me if I am wrong.

 

 
  • I am trying to write directly to registers from C#, but I cannot find if this functionality is available in the C# language wrapper for NetDuino. I need this for several purposes, to enable some modules on the AT91 that are not available through the Netduino firmware. Particularly, right now I am trying to enable PCK1 and PCK2 to get two additional PWM outputs (I need 6 total).

 

What is the best possible option for me to access registers directly from C#? If this functionality is not available for some reason, what is the best recommendation? modify the firmware and perform this in C++?

 

 

  • I am new to working with .net micro framework  and I wanted to ask some questions about how the compiler works

 

I understand that there are 2 components that compile into the firmware:

  • TinyBootLoader
  • C++ Device Code which is: TinyCLR, .net Micro SPOT .net micro libraries, and SecretLab.MF.Hardware libraries.

Is this correct?

 

 

  • If I wanted to recompile and re-flash the firmware for NetDuino, is this the correct procedure?
  • Build a project file in an IDE such as eclipse with an Arm7 compiler such as Yagarto using the netduino firmware with the 3 libraries above.?
  • Get .net Micro Porting kit 4.1
  • Get Microsoft SDK 7.1
  • Get .net Micro Firmware 4.1
  • Copy contents of firmware to .net PK directory
  • Run msbuild to compile for Arm 7
  • Flash it using the SAM-BA tool from Atmel  MFDeploy tool 

I'm still waiting on Windows SDK download. Does msbuild have a toolchain for ARM7? Are there any specific instructions on builidng the firmware?

 

Thanks,

 

 

  • What exactly is the TinyBooterDecompressor? How is this different from TinyBootLoader?

 

 

Thank you all for your responses. If there is an easier way to achieve what I need without modifying the firmware, that would be great, but I am still very interested in learning how to work with ARM devices and expanding my understanding beyond what is provided for general use of the Netduino platform.

 

 

Thank you,



#2 kennethone

kennethone

    New Member

  • Members
  • Pip
  • 4 posts

Posted 03 April 2013 - 10:02 PM

Is there a chance someone may take a look at some of my questions? Thanks,



#3 knutolai

knutolai

    Advanced Member

  • Members
  • PipPipPip
  • 36 posts

Posted 10 April 2013 - 04:03 PM

I'm also interested in programming my NetDuino using native code (for sound DSP use). 

I haven't either been able to find any good resources though I found this thread where they speak about native coding as being not too difficult to achieve:

http://forums.netdui...l=+sound +input

 

[color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;] I fully understand that this render my device useless and I am willing to take the risk.[/color]

Why would this render the device useless? (I'm fairly new to MCUs)



#4 knutolai

knutolai

    Advanced Member

  • Members
  • PipPipPip
  • 36 posts

Posted 10 April 2013 - 04:08 PM

Update:

Thought these sources could be interesting to you:

http://forums.adafru...php?f=8&t=19953

http://www.freertos.org/



#5 knutolai

knutolai

    Advanced Member

  • Members
  • PipPipPip
  • 36 posts

Posted 10 April 2013 - 04:18 PM

Also:

http://forums.netdui...-c-on-netduino/ (sorry for repostig instead of modifying earlier posts, Im new and need approval from a moderator to have my posts shown)

 

This should cover everything you need to know:

http://wiki.netduino...-resources.ashx



#6 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 10 April 2013 - 11:14 PM

Hi kennethone, Because Netduino is open source and you can erase and reflash the firmware anytime, you can always switch back to traditional NETMF at any time. Native code hacking shouldn't render your Netduino useless at all :) They're actually designed to encourage native code hacking! That is...as long as you don't do anything to intentionally disable your microcontroller (like putting it into permanent read protection mode by setting the RDP option byte). Chris




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.