Project status

Coordinator
May 4, 2011 at 4:13 PM


The output from NativeSample is now:

Bootstrap - CPU_IsMMUEnabled: 0
Bootstrap - CPU_IsMMUEnabled: 1
S3C2440_AIC_Driver::Initialize
STUB_ISR 25
.NetMF v4.1.2821.0
Micro2440SDK, Build Date:
        May  4 2011 17:59:31
GNU Compiler version 4

TEST: TimedEvent, Wrong order, Fail

TEST: USART,SUCCESS
PQRSTUVWvalidate failed, Fail

TEST: GPIO,pin unavailable, Fail

Basically there's some debug text and then NativeSample informs that all tests failed :D

Coordinator
May 29, 2011 at 9:08 PM

I made some quick hacks to TIME driver and got TimedEvent to pass. Now the output is:

.NetMF v4.1.2821.0
Micro2440SDK, Build Date:
        May  4 2011 17:59:31
GNU Compiler version 4

TEST: TimedEvent, 1 callbacks, Pass

TEST: USART,SUCCESS
PQRSTUVW            , Pass

TEST: GPIO,pin unavailable, Fail
Coordinator
Jun 10, 2011 at 2:35 PM

I committed initial GPIO driver. There is still a lot to do, but now all the tests in NativeSample pass:

U-Boot 1.3.2-mini2440 (Feb 24 2010 - 13:04:49)
...
Bytes transferred = 93656 (16dd8 hex)
## Starting application at 0x30000000 ...
...


.NetMF v4.1.2821.0
Micro2440SDK, Build Date:
        Jun 10 2011 15:59:54
GNU Compiler version 4

TEST: TimedEvent, 1 callbacks, Pass

TEST: USART,SUCCESS
PQRSTUVW            , Pass

TEST: GPIO,
All tests passed!

 


Coordinator
Jun 17, 2011 at 11:56 PM
Edited Jun 17, 2011 at 11:57 PM

Now the TinyCLR works somehow. I created planned release. You can download binaries from there.

Feb 20, 2012 at 3:59 AM

How to build bin file (tinyclr.bin)???

Coordinator
Feb 20, 2012 at 7:25 PM
Edited Feb 20, 2012 at 7:26 PM

From command line:

  • Go to directory {PORTING KIT ROOT}
  • Run setenv_gcc.cmd {tool chain path}
  • Go to directory {PORTING KIT ROOT}\Solutions\Micro2440SDK
  • Run MSBuild.exe dotNetMF.proj /p:flavor=debug;memory=ram /t:build

You should find tinyclr.bin from {PORTING KIT ROOT}\BuildOutput\ARM\GCC4.2\le\RAM\debug\Micro2440SDK\bin

Feb 21, 2012 at 1:56 AM

thank you very much!

Build Success! but it have 17 warnings.

Feb 21, 2012 at 3:07 AM
Edited Feb 21, 2012 at 3:22 AM

HI!

Can you tell about driver's speed, please?

I'm newbie. I have a Micro2440SDK board.

i'm interesting in .NET MF and i want to learn driver programming in it.

thanks in advance!

Coordinator
Feb 22, 2012 at 7:37 PM

Hi

If you are testing for example GPIO driver from managed program, you might see poor performance, because TIME driver is implemented using real time clock tick. Real time clock tick is 64 Hz.

What driver are you interested in? And how are you testing/using the driver?

 

 

Here is some information about TIME driver:

TIME driver is in {PORTING KIT ROOT}\DeviceCode\Targets\Native\S3C2440\DeviceCode\S3C2440_TIME\ 

Time driver should be implemented with timers (chapter 10 from S2C2440 user's manual). 

Example on good implementation can be found here: {PORTING KIT ROOT}\DeviceCode\Targets\Native\LPC24XX\DeviceCode\TIME\LPC24XX__TIME.cpp

Feb 23, 2012 at 3:47 AM

Thanks for reply!

I'm interested in GPIO, PWM driver. i tested on GPIO Driver by toggle on/off pin. if i modify real time clock tick, what problem is occured?

Can your GPIO Driver's speed up 20MHz?

Thanks in advance!

Coordinator
Feb 23, 2012 at 8:26 PM

Hmm.. TIME driver might not have very much effect on program that just toggles pin on/off..

You can't get 20 MHz speed with managed program toggling pin on/off using GPIO driver.

To get 20 Mhz speed you must implement PWM driver so that managed program can tell hardware to toggle pin on/off. S3C2440 has four timers that can be used for PWM. You can get PWM signal from GPB0-GPB3.

Implementing PWM driver won't be easy. There isn't interface for PWM in .NET microframework. You have to implement the managed code interface and native code logic. To implement PWM driver:

study S3C2440 user's manual chapter 9 and 10, http://www.friendlyarm.net/dl.php?file=S3C2440.pdf

study managed code and native code interoperability http://blogs.msdn.com/b/smaillet/archive/2009/04/27/using-interop-in-the-net-micro-framework-v3-0.aspx

look for example from Netduino project PWM driver

 

PS. If you are interested in playing with TIME driver, maximum frequency of real time clock tick is 64 Hz. You can make it even slower if you are interested :) change S3C2440_TIME_Driver::Initialize. You will have to change /Solutions/Micro2440SDK/platform_selector.h SLOW_CLOCKS_PER_SECOND-constant accordingly. There should not be any problems.

 

 

Coordinator
Feb 23, 2012 at 8:38 PM
Edited Feb 23, 2012 at 8:46 PM

It looks like .NET micro framework 4.2 has interface for PWM (http://netmf.codeplex.com/wikipage?title=.NET%20MF%204.2%20Roadmap). It might be much easier/elegant to switch this project to 4.2 version and then implement PWM driver.

You can just try dropping files from this project to .NET micro framework 4.2 porting kit. It might work.. :)

4.2 version contains at least one PWM example driver: 
\DeviceCode\Targets\Native\LPC24XX\DeviceCode\PWM\LPC24XX__PWM.cpp 

Feb 24, 2012 at 1:33 AM
Edited Feb 24, 2012 at 1:41 AM

Thank you very much for your help!

i will try to do it. But if i using SPI driver, will SPI driver implementation be more easy than PWM driver?

Do you have a windows application run on .Net MF? how to show GUI on LCD?