Giter Club home page Giter Club logo

Comments (9)

stephenhensley avatar stephenhensley commented on September 3, 2024 2

@MarianoDesivo hmm, I'm not able to replicate this on my end.

The daisy_seed.h file should be located at libdaisy/src/daisy_seed.h. Can you confirm that it is in that location.

Can you also check if the libdaisy/build folder has a file called, "libdaisy.a"

One other thing that you can try that would help me assist further is to navigate to your DaisyExamples folder in git-bash and do the following:

./ci/build_libs.sh
cd seed/Blink
make 

That first command may take a few minutes to run, but only needs to be run after cloning the repository or when updating files within libdaisy or DaisySP.

Hope that helps! Let me know how that goes and I can try to help more.

from daisywiki.

stephenhensley avatar stephenhensley commented on September 3, 2024 1

@MarianoDesivo

Well, the fact that you're able to build the file from the command line is promising.

I'm now wondering whether the your libdaisy or DaisyExamples repositories are possibly out of date.

To verify everything as the most recent commit you should be able to run git checkout master && git pull from DaisyExamples, libdaisy, and DaisySP folders.

After doing this, if there are any changes, you will need to rebuild the libraries before you'll be able to build one of the examples. You can reverify that things are buildable by building via the command line before reattempting to open them in VS Code.

If you're still getting the same error after that I would have to assume that either the c_cpp_properties.json file is missing from the .vscode / directory, or possibly the Cortex-Debug extension is not installed (though, I suspect it would still compile the code without that).

from daisywiki.

stephenhensley avatar stephenhensley commented on September 3, 2024 1

Wonderful, I'm glad we got it sorted out! 馃槃

I've noticed those warnings occasionally, but from what I've seen they tend to go away after running the build command.

Since it was most likely the repos just being out of sync with each other I don't think I need any additional information.

from daisywiki.

stephenhensley avatar stephenhensley commented on September 3, 2024

Sorry to hear you had an issue. We are trying to consolidate our documentation, and especially the getting started section to be as simple as possible, and then adding more descriptive, and CLI-based workflows back in.

To clarify are you using VS or VS Code? And at which point in the new guide are you first experiencing the error?

My first instincts would be that when you cloned/downloaded the DaisyExamples you did not use the --recurse-submodules flag. If this is the case your libdaisy folder withing DaisyExamples would still be empty.

To remedy this after the fact, you can run:

git submodule update --init

As before, you should still be able to run the ./rebuild_all.sh command from git bash. Depending on if that gives you any errors that may also help us figure out what's causing your issue.

from daisywiki.

MarianoDesivo avatar MarianoDesivo commented on September 3, 2024

I am using VS code, I followed the link from https://github.com/electro-smith/DaisyWiki/wiki/1.-Setting-Up-Your-Development-Environment

I copied this "git clone --recurse-submodules https://github.com/electro-smith/DaisyExamples ~/Desktop/DaisyExamples" from the same page, so that is no the problem

I think the problem is from VS code, I don't know if I installed the libraries correctly, as that is not explained on the tutorial

from daisywiki.

stephenhensley avatar stephenhensley commented on September 3, 2024

The libraries don't need to be installed, they get cloned along with all of the examples.

Despite the apparent warning that it can't find the file, are you able to build the example from VS Code or does building it throw the error as well? You can do this by doing ctrl+shift+b, or by going to Terminal-> Run Build Task.

It could be just an issue with VS Code not knowing where the files are before it tries to build.

If the terminal reads:

arm-none-eabi-size build/Blink.elf
   text    data     bss     dec     hex filename
  23608     704   19072   43384    a978 build/Blink.elf
arm-none-eabi-objcopy -O ihex build/Blink.elf build/Blink.hex
arm-none-eabi-objcopy -O binary -S build/Blink.elf build/Blink.bin

then it successfully built.

If you still have issues, can you check if the Desktop\DaisyExamples\libdaisy folder has any contents since that would be my next guess if it can't find daisy_seed.h.

from daisywiki.

MarianoDesivo avatar MarianoDesivo commented on September 3, 2024

I opened blink.cpp with vs code, ctrl+shift+b gives me:

Executing task: C/C++: arm-none-eabi-g++.exe compilar archivo activo 

Iniciando la compilaci贸n...
"C:\Program Files (x86)\GNU Arm Embedded Toolchain\10 2020-q4-major\bin\arm-none-eabi-g++.exe" -g C:\Users\MARIANO\Desktop\DaisyExamples\seed\Blink\Blink.cpp -o C:\Users\MARIANO\Desktop\DaisyExamples\seed\Blink\Blink.exe -fno-exceptions -fno-rtti -std=gnu++14 -std=gnu11 -Wall -Wno-attributes -Wno-strict-aliasing -Wno-maybe-uninitialized -mcpu=cortex-m7 -mfpu=fpv5-d16 -mfloat-abi=hard -mthumb
cc1plus.exe: warning: command-line option '-std=gnu11' is valid for C/ObjC but not for C++
C:\Users\MARIANO\Desktop\DaisyExamples\seed\Blink\Blink.cpp:1:10: fatal error: daisy_seed.h: No such file or directory
   1 | #include "daisy_seed.h"
     |          ^~~~~~~~~~~~~~
compilation terminated.

La compilaci贸n finaliz贸 con errores.
The terminal process failed to launch (exit code: -1).

Terminal will be reused by tasks, press any key to close it.

Desktop\DaisyExamples\libdaisy Has content, 50.1 MB

from daisywiki.

MarianoDesivo avatar MarianoDesivo commented on September 3, 2024

Yep, daysi_seed.h is right there. It was the first thing I checked

I don't have the folder Desktop/DaysiExamples/libdaisy/build ... give me a second...

Ok, now I got "libdaisy.a" using "./ci/build_libs.sh"

Using:
cd seed/Blink
make

Works, it gives me:
arm-none-eabi-g++ -c -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard -DUSE_HAL_DRIVER -DSTM32H750xx -DHSE_VALUE=16000000 -DCORE_CM7 -DSTM32H750IB -DARM_MATH_CM7 -DUSE_FULL_LL_DRIVER -include stm32h7xx.h -I../../libdaisy -I../../libdaisy/src/ -I../../libdaisy/src/sys -I../../libdaisy/src/usbd -I../../libdaisy/Drivers/CMSIS/Include/ -I../../libdaisy/Drivers/CMSIS/DSP/Include -I../../libdaisy/Drivers/CMSIS/Device/ST/STM32H7xx/Include -I../../libdaisy/Drivers/STM32H7xx_HAL_Driver/Inc/ -I../../libdaisy/Middlewares/ST/STM32_USB_Device_Library/Core/Inc -I../../libdaisy/core/ -I../../DaisySP/Source -O2 -Wall -Wno-missing-attributes -fasm -fdata-sections -ffunction-sections -MMD -MP -MF"build/Blink.d" -fno-exceptions -fasm -finline -finline-functions-called-once -fshort-enums -fno-move-loop-invariants -fno-unwind-tables -std=gnu++14 -Wa,-a,-ad,-alms=build/Blink.lst Blink.cpp -o build/Blink.o arm-none-eabi-g++ build/startup_stm32h750xx.o build/Blink.o -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard --specs=nano.specs --specs=nosys.specs -T../../libdaisy/core/STM32H750IB_flash.lds -L../../libdaisy/build -L ../../DaisySP/build -ldaisy -lc -lm -lnosys -ldaisysp -Wl,-Map=build/Blink.map,--cref -Wl,--gc-sections -o build/Blink.elf arm-none-eabi-size build/Blink.elf text data bss dec hex filename 23384 704 19072 43160 a898 build/Blink.elf arm-none-eabi-objcopy -O ihex build/Blink.elf build/Blink.hex arm-none-eabi-objcopy -O binary -S build/Blink.elf build/Blink.bin

But ctrl+shift+b still don't work, and I see #include "daisy_seed.h" in red colour, with the message "no such file or directory"

from daisywiki.

MarianoDesivo avatar MarianoDesivo commented on September 3, 2024

I used git checkout master && git pull on the 3 folders. It updated some things

Build again with ./ci/build_libs.sh

Then blink example worked again with:

cd seed/Blink
make 

Then I opened Visual Stuidio Code and the errors where gone, it has some warnings about some files/directories that "could not be found" but it seems to work fine

Thank you for your time

You can close the issue. Tell me if you need some data for me to copy here

from daisywiki.

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.