Hello, How to deploy user application (without os) to the NAND Flash? I have succesfully deployed it to NOR using JTAG (and it's working as expected), but the same method doesn't work with NAND. It looks like the app is starting up but hangs immediately. Any suggestions?
User app starting up from NAND
Hi, Sorry, I don't know the answer for Your question yet, but I noticed that You're writing about user app and I'm courious if You have an absolute user app that can be compiled with GCC ? Because I'm trying to find one since I bought the micro2440 board but with no success. I'm starting to worry that I will have to write linker script and startup.s all by myself. BR, Damian
I had to use ADS in order to compile the code. Only assembler files (like 2440init.s) are incompatible with GCC, the rest goes fine. I would even pay someone to convert the assembler files to GCC, as the ADS compiler is quite expensive.
Things that goes fine are only headers and source files, You are still missing linker script and makefile while porting to GCC (not mention about incompatible assembler). I found an ADS1.2 asm manual and in case I won't find gcc project to start from I will translate it to gcc arm (in act of desperation) - then the last thing to do will be liker script. There are two GCC projects available: Rockbox and RT Thread. Both are quite big and complicated, but You can find few linker scripts and *.S files there. I don't know if they are complete and universal. Anyway I believe it can be use as a base for final versions. Regards, Damian
Dejet The reason it runs in NOR and not NAND is that code cannot be executed in NAND. When the board "boots" in NAND it actually copies the first 4k of NAND into ram within the s3c2440 chip, this is a steppingstone boot. This code is then executed to bring in the boot from NAND to the system ram where the system boot is executed. So you will need to do this, see 2440init.s to see how it's done. Phil
Hello, If this is the issue then how come 2440test-20090717 project from DVD works fine in NAND flash,the 2440init.s file is same my application also.
Hi vikas NAND cannot execute program code except for the first 4k on boot-up, I haven't looked at the 2440test project but it must transfer the code to system ram to execute it. Its best to think of the NAND as storage, you can read and write to it but you can't execute code directly from it. But it should not be difficult to copy/modify the 2440test project to boot strap your NAND code into ram, just make sure boot strap is not bigger than 4k. Phil
Dear Phil, Thanks Phil, I have developed application using 244otest project itself added my code to it. but It hangs up in LCD Code. but If I remove that code then it works fine..... Not getting what exactlly the issue.
Vikas, is your application size going above 4K? Are you handling bootstrap loader part inside your application? Is your application giving errors when running from memory this time? (last time u had problem running it from NAND) Did you try to debug it thru ADS? You should use that debugger in non-os environment.
still I had same problem one one thing that it works fine when LCD code is removed.... but my application which uses more GLCD...
2 Dejet > I would even pay someone to convert the assembler files > to GCC, as the ADS compiler is quite expensive. Really it is no so hard to convert assembler files. In fact they differ almost only in section's defines and linkers stuff. 99% of code independent from used compiler. I am make my own startup and bootloader code for the IAR EWARM.