简体   繁体   English

如何开始使用olimex sam7-p256

[英]How to start with olimex sam7-p256

I have bought a olimex sam7-p256 development board. 我已经购买了olimex sam7-p256开发板。 Can anyone guide me to a website or tutorial that gives an idea as to how to install the tools and start using it? 谁能引导我进入提供有关如何安装工具并开始使用的想法的网站或教程? I am using ubuntu 9.10. 我正在使用ubuntu 9.10。 Though I have got a windows OS, I would prefer to use it under linux. 尽管我有Windows OS,但我更愿意在Linux下使用它。 Any help on the good starting point in windows / linux will be good. 在Windows / linux的良好起点上的任何帮助都会很好。 Thank you. 谢谢。

Krish. Krish。

I may edit this a few times before it is over. 在结束之前,我可能会编辑几次。

Start by getting the code sourcery lite tools. 首先获取代码源精简版工具。 That or embdebian, but code sourcery is better and easier. 那个或Embdebian,但是代码源变得越来越好。 the linux gnueabi are fine because you dont need/wont use the linux calls you just need a generic gcc cross compiler. linux gnueabi很好,因为您不需要/不想使用linux调用,您只需要一个通用的gcc交叉编译器。 llvm is an alternative that might be even easier to install, but less people know how to use it at the moment (need the base llvm plus clang, I normally build from sources but that takes forever). llvm是一种可能更易于安装的替代方法,但是目前很少人知道如何使用它(需要基本的llvm和clang,我通常从源代码构建,但这需要永远的时间)。

Try for a blinking led thing first. 首先尝试使指示灯闪烁。 following the olimex link in JB's comment above. 按照上面JB评论中的olimex链接。 lpcstuff.blogspot.com, lmistuff.blogspot.com may give you an idea on how to get started note that the formerly luminary micro stellaris now texas instruments stellaris is a cortex m3 which is a thumb(2) only machine and boots differently than the arm7 in the sam7. lpcstuff.blogspot.com,lmistuff.blogspot.com可能会让您了解入门方法,请注意,以前是发光的微型恒星,现在德州仪器stellaris是皮质m3,仅拇指(2)的机器和靴子与SAM7中的arm7。

I dont have a sam7-p256 but have the more boring sam7-h64 or h256 something like that header board. 我没有sam7-p256,但更无聊的sam7-h64或h256之类的插头板。 Surprised I dont have a sam7stuff blog with blinky leds examples and jtag examples. 感到惊讶的是,我没有sam7stuff博客,上面有眨眼的led示例和jtag示例。 I remember being quite pleased with the sam7 board incorporated it into a few projects. 我记得对sam7板将其合并到几个项目中感到非常满意。 Jtag was not required. 不需要Jtag。

I have but have not used an olimex usb wiggler, have been using the amontec jtag-tiny and have been quite pleased, other than over seas shipping cost/time. 我已经使用过olimex usb wiggler,但还没有使用过,一直在使用amontec jtag-tiny,并且非常满意,除了海运成本/时间以外。 sparkfun has a recent link to an article using the ftdi ft232r which could probably be used as a wiggler as well, and a little easier to come by in the usa, although you would need to do some soldering to cable up to the jtag connector. sparkfun最近链接到使用ftdi ft232r的文章,该文章可能也可以用作摆动器,并且在美国更容易使用,尽管您需要进行一些焊接才能将电缆连接到jtag连接器。

http://www.sparkfun.com/commerce/news.php?id=386 http://www.sparkfun.com/commerce/news.php?id=386

some notes on cross compiling, also in the blogs above 有关交叉编译的一些注意事项,也在上面的博客中

ARMGNU = arm-none-linux-gnueabi ARMGNU = arm-none-linux-gnueabi

AOPS = --warn --fatal-warnings AOPS =-警告-致命警告

COPS = -Wall -Werror -O2 -nostdlib -nostartfiles -ffreestanding COPS =-墙-Werror -O2 -nostdlib -nostartfiles -ffreestanding

$(ARMGNU)-gcc -c $(COPS) somefile.c -o somefile.o $(ARMGNU)-gcc -c $(COPS)somefile.c -o somefile.o

$(ARMGNU)-as $(AOPS) vectors.s -o vectors.o $(ARMGNU)-作为$(AOPS)vectors.s -o vectors.o

$(ARMGNU)-ld -T memmap vectors.s somefile.o -o someprog.elf $(ARMGNU)-ld -T memmap vectors.s somefile.o -o someprog.elf

$(ARMGNU)-objdump -D someprog.elf > somefile.list $(ARMGNU)-objdump -D someprog.elf> somefile.list

$(ARMGNU)-objcopy diags.elf -O binary somefile.bin $(ARMGNU)-objcopy diags.elf -O二进制somefile.bin

look at my blogs for memmap formats and match that to your device addresses. 在我的博客中查找memmap格式,并将其与您的设备地址匹配。 if at all possible start with ram-only programs then try to figure out the .text and .data split for rom and ram. 如果可能的话,只能使用仅RAM的程序,则尝试找出rom和ram的.text和.data拆分。

I highly recommend disassembling your binary to make sure your linker script (memmap in my example) worked right. 我强烈建议拆解您的二进制文件,以确保您的链接器脚本(在我的示例中为memmap)工作正常。 you may not need the .bin file depending on how you load. 您可能不需要.bin文件,具体取决于您的加载方式。 if you have any non-zero data in .data (very bad embedded programming) that .bin file can be not at all what you expected, so be very careful, elfs are preferred (trivial to write an elf parser, I have probably provided one or several variations over the years). 如果您在.data中有任何非零数据(非常糟糕的嵌入式编程),那么.bin文件可能根本达不到您的预期,因此请非常小心,最好使用elf(编写一个elf解析器很简单,我可能已经提供了多年来的一种或几种变化)。

good luck, have fun. 祝你好运,玩得开心。

EDIT: 编辑:

I dont have the same board, but here is a page that walks you through the first embedded program (blinking an led) for the simpler sam7-h64 board. 我没有同一块板,但是下面的页面将引导您完成更简单的sam7-h64板的第一个嵌入式程序(闪烁LED)。 Your led might be on another pin and you can easily adjust the example for that, otherwise this should work for your board too. 您的LED可能在另一个引脚上,您可以轻松地调整示例,否则这对您的电路板也适用。

http://sam7stuff.blogspot.com/ http://sam7stuff.blogspot.com/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM