EmbDev.net

Forum: ARM programming with GCC/GNU tools WinARM


von Bill (Guest)


Rate this post
useful
not useful
I too have just recently downloaded WinARM, and I am trying to get it to
work.

I had no problem unzipping it into the expected directory structure,
i.e. C:\winarm .

Programmer's Notepad works fine. I was able to completely build the
example LED blinking program for my target hardware
(at91sam7S64_Atmel_example). Which generated file is the one that the
debugger wants to see to download to my target device? I am assuming for
now that it is main.elf.

I have an AT91SAM7S-EK eval board from Atmel. I connected it to the
JTAG-to-parellel-port Wiggler clone that I just bought, and hooked the
other end up to the parallel port.

My problem is: what do I do now?

I ran arm-elf-insight.exe, but it wants to see the target device only on
com1 or com2, not on lpt1.

I tried to run ..\openocd_20060213\test.cmd (to try to run openocd). I
got:

C:\WinARM\utils\openocd\openocd_20060213>openocd.exe -d -f arm7_wig.cfg
Debug:   jtag.c:1024 jtag_init():
Error:   parport.c:397 parport_init(): can't open device "giveio"
(giveio.sys installed?)

I don't seem to be able to install giveio.sys no matter how hard I try.
When I tried, I got:

Copying the driver to the windows directory
target file: C:\WINDOWS\giveio.sys
        1 file(s) copied.
Remove a running service if needed...
'loaddrv' is not recognized as an internal or external command,
operable program or batch file.
Installing Windows NT/2k/XP driver: giveio
'loaddrv' is not recognized as an internal or external command,
operable program or batch file.
ERROR: Installation of giveio failed

None of the copies of loaddrv.exe that I could find with Google seem to
work either.

When I tried to run the version of openocd in the openocd_svn55
directory, I got:

---
ioperm.sys must be installed to use openocd with a "Wiggler"
call ./ioperm/ioperm -i with administrator-rights (only needed once)
to uninstall the driver call ioperm -u
---

C:\WinARM\utils\openocd\openocd_svn55>openocd.exe -d -f arm7_wig.cfg
Debug:   jtag.c:1145 jtag_init():
Error:   parport.c:289 parport_init(): missing privileges for direct i/o

I have administrative rights, so I tried to correct this problem by
installing ioperm.sys, this is what happened:

C:\WinARM\utils\openocd\openocd_svn55\ioperm>ioperm -i
ioperm.sys is already installed.
StartService function call failed.

and openocd still fails (in exactly the same way). I could not find
ioperm in my list of system services when I tried to start it manually.

I am getting VERY frustrated with this. What should I do?

Also, when I do get the source-level debugging working, how do I
integrate it into Programmer's Notepad?

Thanks,

Bill

von Mh T. (lpc2103)


Rate this post
useful
not useful
Umm...
May be Eclipse+GCC is more suitable for you.
(Though I removed my Eclipse and switched to WinARM.)
Go Yahoo LPC2100 group and look for a tutorial.
Might help.    Regards

von Martin Thomas (Guest)


Rate this post
useful
not useful
Bill wrote:

> Which generated file is the one that the
> debugger wants to see to download to my target device? I am assuming for
> now that it is main.elf.

Yes, "debuggers" like (Inishgt)-gdb or Keil's uVision work with
elf-files. Verify that debug-symbols are enabled (i.e. dwarf-2), see the
makefiles from the examples

> I ran arm-elf-insight.exe, but it wants to see the target device only on
> com1 or com2, not on lpt1.

Usualy the "gdb-servers" (like openocd, ocdremote, etc) which are the
interface between the debugger (gdb) and the Hardware (Wiggler) are
accessed thru TCP/IP.

> Copying the driver to the windows directory
> target file: C:\WINDOWS\giveio.sys
>         1 file(s) copied.
> Remove a running service if needed...
> 'loaddrv' is not recognized as an internal or external command,
> operable program or batch file.
> Installing Windows NT/2k/XP driver: giveio
> 'loaddrv' is not recognized as an internal or external command,
> operable program or batch file.
> ERROR: Installation of giveio failed
>
> None of the copies of loaddrv.exe that I could find with Google seem to
> work either.

Michael Fischer has written a useful tutorial and provides his own
modified openocd-version. http://www.usbdip.de/en/armdev/index.html .
Follow his method since he has tested it. He also uses insight from
gnuarm not the insight-gdb from devkitpro as in WinARM.

> C:\WinARM\utils\openocd\openocd_svn55\ioperm>ioperm -i
> ioperm.sys is already installed.
> StartService function call failed.

Use ioperm_install.bat. You must be "Administrator" for the
installation.

> Also, when I do get the source-level debugging working, how do I
> integrate it into Programmer's Notepad?

No, Programmers Notepad does not offer a gdb-interface. Use insight-gdb
or the already mentioned Eclipse (or Dev-C++). Please test with the
gnuarm-version of insight, I'm not realy sure if the insight-gdb from
devkitpro as in WinARM works as expected (there are at least some
mentioned issues about thumb/interwork).

Having all this written: I currently do not use (insight-gdb). See
Michael Fischer's page for "first-hand-information".

Martin Thomas

von Guest (Guest)


Rate this post
useful
not useful
Bill wrote:
> I too have just recently downloaded WinARM, and I am trying to get it to
> work.
>
> I had no problem unzipping it into the expected directory structure,
> i.e. C:\winarm .
>
> Programmer's Notepad works fine. I was able to completely build the
> example LED blinking program for my target hardware
> (at91sam7S64_Atmel_example). Which generated file is the one that the
> debugger wants to see to download to my target device? I am assuming for
> now that it is main.elf.
>
> I have an AT91SAM7S-EK eval board from Atmel. I connected it to the
> JTAG-to-parellel-port Wiggler clone that I just bought, and hooked the
> other end up to the parallel port.
>
> My problem is: what do I do now?
>
> I ran arm-elf-insight.exe, but it wants to see the target device only on
> com1 or com2, not on lpt1.
>
> I tried to run ..\openocd_20060213\test.cmd (to try to run openocd). I
> got:
>
> C:\WinARM\utils\openocd\openocd_20060213>openocd.exe -d -f arm7_wig.cfg
> Debug:   jtag.c:1024 jtag_init():
> Error:   parport.c:397 parport_init(): can't open device "giveio"
> (giveio.sys installed?)
>
> I don't seem to be able to install giveio.sys no matter how hard I try.
> When I tried, I got:
>
> Copying the driver to the windows directory
> target file: C:\WINDOWS\giveio.sys
>         1 file(s) copied.
> Remove a running service if needed...
> 'loaddrv' is not recognized as an internal or external command,
> operable program or batch file.
> Installing Windows NT/2k/XP driver: giveio
> 'loaddrv' is not recognized as an internal or external command,
> operable program or batch file.
> ERROR: Installation of giveio failed
>
> None of the copies of loaddrv.exe that I could find with Google seem to
> work either.
>
> When I tried to run the version of openocd in the openocd_svn55
> directory, I got:
>
> ---
> ioperm.sys must be installed to use openocd with a "Wiggler"
> call ./ioperm/ioperm -i with administrator-rights (only needed once)
> to uninstall the driver call ioperm -u
> ---
>
> C:\WinARM\utils\openocd\openocd_svn55>openocd.exe -d -f arm7_wig.cfg
> Debug:   jtag.c:1145 jtag_init():
> Error:   parport.c:289 parport_init(): missing privileges for direct i/o
>
> I have administrative rights, so I tried to correct this problem by
> installing ioperm.sys, this is what happened:
>
> C:\WinARM\utils\openocd\openocd_svn55\ioperm>ioperm -i
> ioperm.sys is already installed.
> StartService function call failed.
>
> and openocd still fails (in exactly the same way). I could not find
> ioperm in my list of system services when I tried to start it manually.
>
> I am getting VERY frustrated with this. What should I do?
>
> Also, when I do get the source-level debugging working, how do I
> integrate it into Programmer's Notepad?
>
> Thanks,
>
> Bill


You have to try the JTAGkey from http://www.amontec.com/jtagkey.shtml
instead any Wiggler or clones, and instead getting frustraded with
parallel port permission ...
The JTAGkey is a USB to JTAG probe coming with the easy use and
plug&play of any modern USB products.
The main advantage of the JTAGkey is you do not need to play with giveio
or ioperm ... It comes with its own USB drivers and is fully integrated
in OpenOCD.
Also, JTAGkey can be plug to any USB HUB and may upload flash 5x faster
than a Wiggler.

Laurent

Please log in before posting. Registration is free and takes only a minute.
Existing account
Do you have a Google/GoogleMail account? No registration required!
Log in with Google account
No account? Register here.