Shop OBEX P1 Docs P2 Docs Learn Events
SimpleIDE Ports for ARM Computers CuBox-i & Utilite — Parallax Forums

SimpleIDE Ports for ARM Computers CuBox-i & Utilite

hassellbearhassellbear Posts: 8
edited 2014-11-11 23:48 in Propeller 1
Hello,

I am posting this thread at the suggestion of Jeff Martin of Parallax.

I use the Solid Run CuBox-i Pro and Compulab Utilite Pro Arm Cortex A9 computers - both of which utilize the quad-core Freescale i.MX6 processor. I run Linaro 11.10, kernel 3.0.35 on the CuBox-i Pro and Ubuntu 12.04, kernel 3.0.35 on the Utilite Pro.

http://www.solid-run.com/products/cubox-i-mini-computer/

http://www.compulab.co.il/utilite-computer/web/home


I have had good success using these 2 computers with Arduino and the Arduino IDE. I would now like to advance to the Parallax Propeller ecosystem and use SimpleIDE on both the CuBox-i and Utilite. Unfortunately, there does not seem to be a Linux port of SimpleIDE suitable for ARM systems, other than the Raspberry Pi version found here:

http://learn.parallax.com/propeller-c-set-simpleide/raspberrypi

I was hopeful the Raspberry Pi version would run on my Cortex A9 systems (as some other RPi software does), but I have been unsuccessful to this point. The installation seems to work ok, but when I execute simpleide I get the following error.

utilite@utilite-desktop:~/Programs/SimpleIDE-0-9-45$ simpleide

/usr/bin/simpleide: 4: /usr/bin/simpleide: /opt/simpleide/bin/SimpleIDE: not found

When I navigate to the indicated directories, the files listed are present. However, the system does not recognize their presence. Does anyone have any suggestions, or know of another SimpleIDE port that may work?

Any assistance will be greatly appreciated.


Best Regards,

hassellbear

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2014-11-07 08:31
    According to Jeff you're trying to get SimpleIDE to run on an Arm Cortex A9 computer. I moved your message from the general forum to here in the Propeller forum where someone might be able to help you on this.
  • Heater.Heater. Posts: 21,230
    edited 2014-11-07 08:46
    hassellbear,

    Welcome to the forums.

    The "SimpleIDE: not found" error sounds very familiar to me. It has happened to me after building SimpleIDE and trying to run the resulting binary. It's a very strange error which does not give much clue as to what is going on.

    I don't recall the details but I seem to remember that basically it was down to an issue with incompatible library versions. That is to say the libraries assumed during build time were not the same as the libraries used at run time.

    I think the thing to do is get the source code for SimpleIDE and compile it.

    Somewhere I have some instructions for building SimpleIDE on the Raspberry Pi which should be applicable.

    SimpleIDE is a C/C++ development system so you would need to get the sources for propgcc and build the C compiler as well.

    This does take a long time on the Pi. 20 hours or so. Should be a lot faster on the machines you have in mind.

    If you are interested in building SimpleIDE yourself let us know and I will dig out the instructions I have.
  • Cluso99Cluso99 Posts: 18,069
    edited 2014-11-07 13:16
    Welcome to the forum hassellbear.
    You are in good hands here although I cannot help you with this.
  • avsa242avsa242 Posts: 452
    edited 2014-11-07 14:13
    hassellbear,

    Welcome to the forum.

    Would you please try the following:


    ls -l /usr/bin/simpleide
    ls -l /opt/simpleide/bin/SimpleIDE


    and paste the output here?

    and also the output of:

    file /usr/bin/simpleide
    file /opt/simpleide/bin/SimpleIDE

    Thanks,
    Jesse
  • hassellbearhassellbear Posts: 8
    edited 2014-11-07 17:48
    Thanks everyone for the welcome, interest, and assistance.

    Here's some further information.


    - strace returns the following info when the Raspberry Pi version of Simpleide is executed on Utilite
    utilite@utilite-desktop:~/Programs/SimpleIDE-0-9-45$ strace -e open simpleide
    open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
    open("/lib/arm-linux-gnueabi/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
    open("/usr/bin/simpleide", O_RDONLY) = 3
    /usr/bin/simpleide: 4: /usr/bin/simpleide: /opt/simpleide/bin/SimpleIDE: not found
    --- SIGCHLD (Child exited) @ 0 (0) ---


    - The commands suggested by Jesse return the following:
    utilite@utilite-desktop:~$ ls -l /usr/bin/simpleide
    -rwxr-xr-x 1 root root 84 Nov 7 17:27 /usr/bin/simpleide


    utilite@utilite-desktop:~$ ls -l /opt/simpleide/bin/SimpleIDE
    -rwxr-xr-x 1 root root 2312869 Nov 7 17:26 /opt/simpleide/bin/SimpleIDE


    utilite@utilite-desktop:~$ file /usr/bin/simpleide
    /usr/bin/simpleide: POSIX shell script, ASCII text executable


    utilite@utilite-desktop:~$ file /opt/simpleide/bin/SimpleIDE
    /opt/simpleide/bin/SimpleIDE: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0x9a99c067a49f3db5946017e400aa6a9365005495, not stripped

    - A fellow CuBox-i and Utilite user and Arch Linux Developer, pepedog, suspects the Raspberry Pi version of SimpleIDE is specific to ARMv6 and thus not applicable to Cortex A9/ARMv7 systems. If this is the case, it will be necessary to port to/compile for Cortex A9/ARMv7.


    - A listing of the steps used in porting to Raspberry Pi along with a list of the dependencies would be very helpful - Thanks Heater


    Best Regards,

    Darryl Hassell
  • hassellbearhassellbear Posts: 8
    edited 2014-11-08 08:41
    The commands suggested by Jesse produce the following results.

    utilite@utilite-desktop:~$ ls -l /usr/bin/simpleide
    -rwxr-xr-x 1 root root 84 Nov 7 17:27 /usr/bin/simpleide

    utilite@utilite-desktop:~$ ls -l /opt/simpleide/bin/SimpleIDE
    -rwxr-xr-x 1 root root 2312869 Nov 7 17:26 /opt/simpleide/bin/SimpleIDE

    utilite@utilite-desktop:~$ file /usr/bin/simpleide
    /usr/bin/simpleide: POSIX shell script, ASCII text executable

    utilite@utilite-desktop:~$ file /opt/simpleide/bin/SimpleIDE
    /opt/simpleide/bin/SimpleIDE: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0x9a99c067a49f3db5946017e400aa6a9365005495, not stripped
  • hassellbearhassellbear Posts: 8
    edited 2014-11-08 09:47
    Hello All,

    Thank you for the warm welcome and interest in my project.

    My overly long posts keep getting delayed for moderator review, so going forward I will respond using multiple, small posts.

    Best Regards,

    Darryl Hassell
  • PublisonPublison Posts: 12,366
    edited 2014-11-08 09:52
    Hello All,

    Thank you for the warm welcome and interest in my project.

    My overly long posts keep getting delayed for moderator review, so going forward I will respond using multiple, small posts.

    Best Regards,

    Darryl Hassell

    Darryl,

    Welcome to the forums!

    I find no moderator reviews in order. I'm going to try something, ( move to a new thread, and then back), let me know if that works.

    Jim\
  • PublisonPublison Posts: 12,366
    edited 2014-11-08 09:56
    Moves done. Does this work?
  • hassellbearhassellbear Posts: 8
    edited 2014-11-08 10:13
    Didn't work. Everything disappeared.
  • PublisonPublison Posts: 12,366
    edited 2014-11-08 10:24
    Didn't work. Everything disappeared.

    Sorry, This workaround has worked in the past.Your particular problem has not come up in the past.

    In the mean time, people can still respond to your thread. We will have to get Parallax personnel to look at it on Monday.
  • Cluso99Cluso99 Posts: 18,069
    edited 2014-11-08 13:02
    hassellbear,
    What OS and browser are you using and rev levels?
    I am on Windows7 32bit and IE10 and cannot post attachments (files or images). I use Firefox 31.0 to add (edit) them to a post. However, with Firefox I have no cursor so it makes posting text a pain. So I am stuck with using 2 browsers. Windows 8.1 64bit is even worse!
  • Bill HenningBill Henning Posts: 6,445
    edited 2014-11-08 13:07
    Welcome hassellbear!

    I suspect that you will need to re-build SimpleIDE from the sources, as heater suggested.

    I do have a couple of i.MX boards here, and will eventually need to bring up SimpleIDE on them - unforunately it will probably be 3-5 weeks before I have time to try.

    I'll keep an eye on this thread though :)
  • hassellbearhassellbear Posts: 8
    edited 2014-11-08 15:57
    Well, here goes one more attempt at a successful posting on this forum. I have been using Firefox 32.0.3 on an ARM Cortex A9 Utilite Computer running Ubuntu 12.04. This time, I am using IE11 on a Windows 7 machine.


    I have come to agree with Heater and Bill Henning that it will be necessary to compile/port Propeller GCC and SimpleIDE for the CuBox-I and Utilite platforms. An Arch Linux developer/fellow CuBox-I and Utilite user, pepedog, took a look at the issue yesterday and concluded that the Raspberry Pi version is specialized for ARMv6. Therefore, it is incompatible with CuBox-I and Utilite which are Cortex A9/ARMv7. That being said, I'm not sure I am up to the task, but I will try.

    Heater's listing of the build steps for the Raspberry Pi version as well as a listing of known dependencies would be greatly appreciated.

    In the mean time, my Propeller Quickstart Breadboard is assembled and awaiting service.
  • hassellbearhassellbear Posts: 8
    edited 2014-11-11 21:48
    Hello,

    I attempted to build Propeller GCC in Ubuntu on my ARM Cortex A9 Utilite using the instructions on the following wiki page:

    https://code.google.com/p/propgcc/wiki/PropGccBuild

    I installed all prerequisites listed.


    After a prolonged build, I ended up with the following:
    root@utilite-desktop:/opt/parallax/bin# dir
    propeller-elf-addr2line propeller-elf-gcc propeller-elf-objdump
    propeller-elf-ar propeller-elf-gcc-4.6.1 propeller-elf-ranlib
    propeller-elf-as propeller-elf-gcov propeller-elf-readelf
    propeller-elf-c++ propeller-elf-gprof propeller-elf-size
    propeller-elf-c++filt propeller-elf-ld propeller-elf-strings
    propeller-elf-cpp propeller-elf-ld.bfd propeller-elf-strip
    propeller-elf-elfedit propeller-elf-nm
    propeller-elf-g++ propeller-elf-objcopy

    Unfortunately, there is no propeller-elf-gdb or propeller-loader

    After the build, I found the following webpage which suggests there is problem with ARM where you do not get the gdb or the loader.

    http://gpio.kaltpost.de/?page_id=1378

    Does anyone have any suggestions?

    Best Regards,

    hassellbear
  • Heater.Heater. Posts: 21,230
    edited 2014-11-11 23:25
    hasselbear,

    As usual those instructions you linked to are a bit out of date. It says "This is because the propeller-loader tool relays on the bstc Linux binary which is a Intel binary." This is no longer true.

    Looks like you are building from old propgcc source because the loader now uses the open source spin compiler to build the Spin parts.
    https://github.com/parallaxinc/OpenSpin. You should fetch, build and install that before building propgcc I believe.

    Don't forget there are various branches of propgcc, "default", "releseas_1_0"...I think I have normally built from the default branch.

    What we need here is to see the error message where building propgcc failed on the loader and or gdb.
  • Heater.Heater. Posts: 21,230
    edited 2014-11-11 23:45
    OK, here is the problem as far as I see it today.

    If you check out the latest propgcc "release_1_0" branch, you will find you have a "release" directory. In there it has a copy of the bstc Spin compiler. A binary executable used to build parts of the loader. This of course does not work on ARM.

    So, checkout the "default" branch. In the release directory you will see that bstc has been removed and now openspin is used.

    But of course those binaries, openspin.linux, are no use on ARM either.

    The fundamental problem is that building the loader has a dependency on the openspin tool and that is provided as a binary. Certainly such things should not be included in a source code repository.

    The solution is to download, build and install openspin first.

    Then copy the openspin executable into the propgcc/release directory as openspin.linux.

    Then build propgcc.

    I'm not sure about gdb. Mostly I don't use it and have not missed it.
  • Heater.Heater. Posts: 21,230
    edited 2014-11-11 23:48
    I was slightly wrong above, the release_1_0 branch has indeed been changed to use openspin instead of bstc.

    Still the problem remains. The openspin binary provided won't run on ARM and you have to provide your own.
Sign In or Register to comment.