Richard-Gemmell / teensy4_i2c

An I2C library for the Teensy 4. Provides slave and master mode.
MIT License
94 stars 21 forks source link

Simple platformio build gives: "undefined reference to `loop'" #39

Open pitosalas opened 3 months ago

pitosalas commented 3 months ago

When I platformio "build" I get this error:

Screenshot 2024-07-08 at 3 44 42 PM

Note that this is after I changed this in platformio.ini:

[env:teensy40]
platform = teensy
board = teensy40
;board = teensy41
framework = arduino

On GitHub, the teensy 40 is commented out and 41 is active.

Do you have any suggestions on how I can get this to build?

Thanks!

Richard-Gemmell commented 3 months ago

Hi,

I suspect the problem is that setup() and loop() aren't defined. I usually just copy one of the example .ino files into the src directory and rename it main.cpp. raw_find_slaves.ino is a good one to start with.

I don't have this project setup at the moment so I can't check my answer. Please let me know if this helps.

cheers, Richard