From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22043 invoked by alias); 25 Oct 2009 13:20:33 -0000 Received: (qmail 22031 invoked by uid 22791); 25 Oct 2009 13:20:28 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail-fx0-f223.google.com (HELO mail-fx0-f223.google.com) (209.85.220.223) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 25 Oct 2009 13:20:16 +0000 Received: by fxm23 with SMTP id 23so12342024fxm.30 for ; Sun, 25 Oct 2009 06:20:13 -0700 (PDT) Received: by 10.204.33.194 with SMTP id i2mr2850857bkd.146.1256476813172; Sun, 25 Oct 2009 06:20:13 -0700 (PDT) Received: from localhost ([93.85.202.104]) by mx.google.com with ESMTPS id 16sm562950bwz.7.2009.10.25.06.20.10 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 25 Oct 2009 06:20:11 -0700 (PDT) Date: Sun, 25 Oct 2009 13:20:00 -0000 From: Sergei Gavrikov To: peter_lanius@yahoo.com.au Cc: eCos discuss-list Message-ID: <20091025132007.GA4436@sg-laptop> Mail-Followup-To: peter_lanius@yahoo.com.au, eCos discuss-list References: <471205.59207.qm@web51906.mail.re2.yahoo.com> <20091019104557.GA19013@sg-ubuntu.local> <964415.68782.qm@web51911.mail.re2.yahoo.com> <20091019135211.GA17646@sg-ubuntu.local> <404723.91676.qm@web51903.mail.re2.yahoo.com> <20091024123837.GA3998@sg-laptop> <738229.12555.qm@web51906.mail.re2.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <738229.12555.qm@web51906.mail.re2.yahoo.com> User-Agent: Mutt/1.5.18 (2008-05-17) X-IsSubscribed: yes Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: Re: [ECOS] RedBoot loading eCOS examples causes PC reboot X-SW-Source: 2009-10/txt/msg00156.txt.bz2 Please keep your replies on the mailing list so that all may benefit. Peter wrote: > Hi Sergei > > thank you for being so helpful. I understand that what I reported > isn't an eCOS issue and rather has to do with > Windows/Hyperterminal/FTDI drivers. > > I am happy to switch to Linux as I had several problems with the > FTDI drivers under Windows. I would appreciate a few pointers > regarding the selection of tools you recommend. I have installed > openSUSE 11.1 and added obvious things like Eclipse, mercurial, > python. Hi Peter, That's great. I hope that you will get a success with the target under Linux more that you are unix veteran as I knew and I hope you will get an enjoy with the modern unix-like environment (Linux) and open source OS for embedded (eCos). I used Slackware a couple years ago and now beeing no geek anymore :-) I use Ubuntu, but, openSUSE it is the great distribution too! So, my proposals would be an apt-centric, but your system is zypper-centric. Hope, someone will fix my faults. > What I would like to know is: > 1. Which GNU ARM toolchain do I install? Sourcery G++ Lite for ARM > EABI? That toolchain is built against newlib libc and eCos has own libc implementation. There is ready-to-use eCos toolchain for ARM (and other) targets on the eCosCentric FTP site: ftp://ecoscentric.com/pub/ecos/gnutools/ You have to install this toolchain for the target ftp://ecoscentric.com/pub/ecos/gnutools/i386linux/ecoscentric-gnutools-arm-eabi-20081213-sw.i386linux.tar.bz2 The toolchain is based on GCC 4.3 on it is well tested toolchain for eCos v3_0/CVS. But, more proper way to install eCos is to use these official proposals and eCos install script. Look here, please http://ecos.sourceware.org/getstart.html So, you have to install Tcl to get the stuff. On Ubuntu it's need to install {tcl,tk}-dev packages with apt-get, and Google told me that you need to do $ sudo zypper install tcl tk tcl-devel tk-devel and then run `sh ecos-install.tcl' as root (sudo sh) and you will get eCos v3_0, configtool and the selected gnu toolchain(s) under /opt. And how to install eCos from HG I wrote you a couple days ago. So, may be you need only arm-eabi toolchain only from their FTP. > 2. Where do I get the FTDI driver for the Olimex ARM-USB-OCD JTAG > for Linux? How do I install it? The below is the FTDI board related (no OpenOCD USB JTAG). The modern Linux kernels have modules to manage FTDI devices. Just plug in your board to USB port and then look on `dmesg' output. $ gmesg | tail and you'll get it. or use lsusb utility $ lsusb | grep -i future Bus 005 Device 002: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC and at the end you should see new character device (on my Ubuntu that will be ttyUSB0, I hope on openSUSE that will be the same) $ ls -l /dev/ttyUSB0 crw-rw---- 1 root dialout 188, 0 2009-10-25 13:01 /dev/ttyUSB0 And this character device can be used to interact with RedBoot on the board via terminal program. As you can see I should belong `dialout' group, but on SUSE that may be something another. > 3. Do I need to install OpenOCD? If yes, which version? Do I need to > build it? Peter, nowadays I do not use OpenOCD with the board, it's enougth for me to use the pair RedBoot+GDB for that target (your target has 1M RAM and that is good amount of memory to use RedBoot), but, in a past I had success with Olimex parallel JTAG wiggler and OpenOCD on Linux box (well that openocd was built from sources). Today eCos/Redboot has not native support for OpenOCD debugger. So, I would say, it is may be odd to use JTAG for _your_ target. Seek on the list on the subject and you will know about OpenOCD+eCos a bit more. I live without JTAG because I can burn ROM images using own Expect script, i.e. program on-chip LPC flash using LPC ISP commands via... /dev/ttyUSB0, e.g. $ prog_lpc2xxx -file install/bin/redboot.bin -port /dev/ttyUSB0 Since I've used RedBoot I does not need JTAG/OpenOCD. If you want I can put that script on bitbucket. > Anything else you recommend? I haven't done development on Unix > since 1992, so my knowledge is rather obsolete... Perhaps, you need to install `minicom' (instead hyperterm) and may be `lrzsz' package (x,y,zmodems utilities). $ sudo zypper install minicom Then prepare minicom rc script for the target $ cat > ~/.minirc.olimex << EOF pu port /dev/ttyUSB0 pu baudrate 38400 pu bits 8 pu parity N pu stopbits 1 pu rtscts No EOF And use `minicom' with the board (~ HyperTerm), `man minicom'. $ minicom -o olimex ;# run then press RST on the board. Eclipse... I'm sorry, I do not use this IDE. The gdb, gdb-tui is enough for me, this is a good intro http://beej.us/guide/bggdb/ To develop on Linux you need to have more stuff is got with zypper, i.e. to install some host's development tools, gcc, g++, autotools, etc. if you plan to use eCos from CVS/HG and build the latest eCos host tools from the sources. Wellcome to Open Source World! Well, on Ubuntu that's easy enough $ sudo apt-get install build-essential What's I found for openSUSE http://forums.opensuse.org/applications/413553-build-essential.html $ zypper se -t pattern devel and it seems for me those `devel_basic', `devel_C_C++' will be good choices for start. But, may be you have those packages installed. Peter, and at the end, all eCos/RedBoot documentation is your friend http://ecos.sourceware.org/docs-latest/ and sure the eCos mailing list archives (it is searchable stuff) http://ecos.sourceware.org/intouch.html and Google as well are too. HIH Sergei > Thanks > Peter [snip] -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss