Code Monkey home page Code Monkey logo

Comments (12)

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

Hi Bob,

Are you using st-util?

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

I am using st-util. I don't see a command line option to get st-util to give me its version number, but it should be pretty new.

I was able to compile, load, and run the accelerometer demo, and both of the hello_world demos. Using those some procedures on the filesystem demo gives me the results above.

Do I need to put that disk_8_partitions.img file anywhere special?

The board is an stm32F407G discovery, the numbers in the upper right corner say M8997D.

TNX
Bob

from ada_drivers_library.

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

This example requires semi hosting support from st-util which I added to the official repo a few weeks ago. In other words, you need a fresh version of st-util and you need to start st-util with the --semihosting option.

I'm sorry this should be documented.

Also, for the example to succeed, you have to copy the disk_8_partitions.img in /tmp/.

We can keep the issue open until this is properly documented.

Regards,

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

Thanks for the tips. I got my st-util executable from st.com. I found your code updates in texane, I downloaded the code and will see if I can build a windows .exe unless there's already one out there. I didn't see one.

With that in mind, I have a machine running Fedora 24. The native linux GPS works fine but the ARM version wouldn't run. Different thread, but have you heard anyone else report that?

tnx
Bob

from ada_drivers_library.

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

I don't remember any problem on Linux. Do you have separate installation directories for native and arm ?

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

I wiped off all of the gps stuff and reinstalled the 64 bit 2016 linux version of the arm-elf. When I run gps I get...
[bob@localhost lib]$ gps
/usr/gnat/bin/gps: /usr/gnat/bin/gps_exe: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory

For completeness...
[bob@localhost lib]$ uname -a
Linux localhost.localdomain 4.7.2-201.fc24.x86_64 #1 SMP Fri Aug 26 15:58:40 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

Same result using the gnat 2015 arm-elf and 2014 as well, so I think I have an issue with Fedora.

Couldn't get st-util to build on Windows, so I'll start an issue with Texane and open beer!

from ada_drivers_library.

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

There is no 64bit release of GNAT GPL for arm. This error is because gnat arm-elf is a 32bit executable and it cannot find its dependencies in 32bit. I think that's the problem, have a look at your distrib documentation/forums to know how to run 32bit executables.

Regards,

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

Yes, that did it. GPS runs now, however stm32f407_discovery.gpr fails with an unknown attribute "runtime" message. I think I'll put a 32 bit Fedora on a virtual_box and see if I can get that to work.

Bob

from ada_drivers_library.

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

Can you show me the "runtime" error message ?

Did you clone with the --recursive option as shown in at the beginning of the README ?

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

I did to the --recursive option. I wiped it out and reloaded... Here's what I did this morning. Also, I only have the arm-elf environment available. The native linux is not installed.

[bob@localhost ~]$ cd Desktop/
[bob@localhost Desktop]$ ls
Ada_Drivers_Library
[bob@localhost Desktop]$ git clone --recursive https://github.com/AdaCore/Ada_Drivers_Library.git
Cloning into 'Ada_Drivers_Library'...
remote: Counting objects: 9750, done.
remote: Total 9750 (delta 0), reused 0 (delta 0), pack-reused 9750
Receiving objects: 100% (9750/9750), 3.36 MiB | 3.28 MiB/s, done.
Resolving deltas: 100% (6230/6230), done.
Checking connectivity... done.
Submodule 'embedded-runtimes' (https://github.com/AdaCore/embedded-runtimes.git) registered for path 'embedded-runtimes'
Cloning into 'embedded-runtimes'...
remote: Counting objects: 1229, done.
remote: Total 1229 (delta 0), reused 0 (delta 0), pack-reused 1229
Receiving objects: 100% (1229/1229), 1.26 MiB | 0 bytes/s, done.
Resolving deltas: 100% (813/813), done.
Checking connectivity... done.
Submodule path 'embedded-runtimes': checked out '5cca89013958a14831ac029c60636c7c56bf8f5f'
[bob@localhost Desktop]$ gps
Gtk-Message: Failed to load module "pk-gtk-module"
Gtk-Message: Failed to load module "canberra-gtk-module"
Fontconfig error: Cannot load default config file

Then when I load the hello_world_tasking example project. ...

Project
/home/bob/Desktop/Ada_Drivers_Library/boards/stm32f407_discovery.gpr
14:14 undefined attribute "runtime"
16:14 undefined attribute "runtime"
/home/bob/Desktop/Ada_Drivers_Library/examples/hello_world_tasking/hello_world_tasking_f4disco.gpr
5:7 undefined attribute "runtime"

Same result if I load other examples. This works just fine on my Windows machine so I think there's an issue with my linux configuration.

Thanks for you help!

Bob

from ada_drivers_library.

plestedr avatar plestedr commented on September 24, 2024

Fabien -

I got everything to work on a native 32 bit Fedora 24 environment running under an Oracle Virtualbox. I don't know why I'm having problems with the embedded runtimes under the 64 bit environment, but they all loaded and compiled just fine in 32 bits.

The filesystem demo ran with your instructions from above. I did clone the stlink package and built it. The demo ends a bit ungracefully, but I think that is by design.

I'll see if I can document all of this and maybe we can close out the issue.

Bob

BTW, I left the 2014 GPS in place on the 64 bit machine, that was causing the problem with runtimes. So that is solved now with the 2016 GPS.

from ada_drivers_library.

Fabien-Chouteau avatar Fabien-Chouteau commented on September 24, 2024

Thanks Bob!

Yeah the example is not very friendly :)
It's more a test for a few features I added. I hope that we will be able to add the FATfs driver at some point.

from ada_drivers_library.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.