Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blink Example setup/loop not working as part of larger project (for Teensy 3.1) #70

Open
chlirre opened this issue Jan 8, 2021 · 4 comments

Comments

@chlirre
Copy link

chlirre commented Jan 8, 2021

Background

I am currently attempting to port the firmware for synth module Ornament & Crime to PlatformIO to be able to develop under later OS X versions.

In addition to being written for Teensy 3.1, the O & C project has some restrictions in terms of compiler.

gcc 4.8

Which is enforced by stating the toolchain-gccarmnoneeabi version.

I am specifically porting the alternative firmware Hemisphere.

I'm on OS X 10.13.2, running PlatformIO IDE (with PlatformIO Core, version 5.0.4).

I tried the suggestions found at platformio/platformio-core#566, without success. I tried prepending As & Zs to the main file without luck.

I cannot tell if the issue lies within PlatformIO, this platform or elsewhere. All I know is https://github.com/Chysn/O_C-HemisphereSuite builds, uploads and runs fine with the Arduino IDE and that I've made as little changes as possible to that code.

The issue

The project is in a state where everything builds just fine (apart from some warnings).
Uploading/programming (with both teensy-cli and teensy-gui) seems to work just fine.

But beyond that point, there is no indication of the firmware running.
As in:

  • no serial output.
  • Nothing showing on the screen.
  • the case of borrowing the "main/loop" file from the led blink example, the LED is not blinking.

Not working (not blinking)

Loop/setup

https://github.com/chlirre/O_C-HemisphereSuite/blob/blink-loop/software/src/Main.cpp
Note that the the only difference is the OC::CORE::ticks initialization which I had to leave in there to avoid linker errors.

Env/platform

https://github.com/chlirre/O_C-HemisphereSuite/blob/blink-loop/software/platformio.ini

Working (blinking)

Loop/setup

https://github.com/chlirre/platform-teensy/blob/o_c-platform/examples/arduino-blink/src/Blink.cpp

Env/platform

https://github.com/chlirre/platform-teensy/blob/o_c-platform/examples/arduino-blink/platformio.ini

@maxgerhardt
Copy link

@valeros
Copy link
Member

valeros commented Jan 11, 2021

Hi @chlirre ! There might be plenty of reasons. First, you need to make sure that the package versions are identical (toolchain, framework, libs, etc). I also noticed you use -O2 optimization. Have you tried other levels?

BTW, this line [email protected] seems invalid to me, probably should be something like toolchain-gccarmnoneeabi@~1.40804.0

@chlirre
Copy link
Author

chlirre commented Jan 21, 2021

@valeros I tried a few different optimizations, but the instructions for compiling the original project explicitly state 4) select Faster (= o2) in Tools > Optimize (teensyduino 1.34 and 1.35) (https://ornament-and-cri.me/firmware/) so I stuck with that.

@valeros
Copy link
Member

valeros commented Jan 21, 2021

Could you please try to compile your project in verbose mode and attach the log here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants