You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't think the problem has anything to do with using a Mac. Looking through your error, it seems that Raspberry Pi made a change to the pico-extras repo (changed datetime_t to timespec). Everyone always says how great it is to "leverage shared open-source components". And it is, until they make a tiny change and screw you over.
An immediate but annoying solution is to checkout an older version of the pico-extras. It seems the offending change to the pico_sleep function was made on Nob 8, 2024 by peterharperuk.
Or I can figure out how to change my program to work with the new structure, but that will screw over anyone that is currently able to compile it, until they update their pico-extras to the current one.
3rd, I might be able to remove all references to pico_sleep from my program and sidestep the whole issue. (pico_sleep was used for a low-power battery mode, which doesn't work anymore anyway because of other changes I had to make to the PLL oscillator stuff).
I will push an update to the repo today that removes the pico_sleep references. Please let me know if it compiles for you. Thank you.
interesting, I updated pico-extras on my system, and I now get warnings related to the datetime_t/timespec issue, but they are only warnings, not errors.
I guess something about gcc on a Mac is more strict than on PC?
Regardless, I just pushed an update to the repo with all the sleep stuff removed (since it wasn't working anyway).
Please let me know if you can now compile it. Thanks.
Hi, I am compiling the code on a Mac Mini M1 and i get the following errors
[ 30%] Building C object CMakeFiles/pico-WSPRer.dir/WSPRbeacon/WSPRbeacon.c.o
/Users/eric/pico-WSPRer/WSPRbeacon/WSPRbeacon.c: In function 'WSPRbeaconTxScheduler':
/Users/eric/pico-WSPRer/WSPRbeacon/WSPRbeacon.c:322:48: error: passing argument 1 of 'sleep_goto_sleep_until' from incompatible pointer type [-Wincompatible-pointer-types]
322 | sleep_goto_sleep_until(&alarm_time, &sleep_callback); //blocks here during sleep perfiod
| ^~~~~~~~~~~
| |
| datetime_t *
In file included from /Users/eric/pico-WSPRer/WSPRbeacon/WSPRbeacon.c:12:
/Users/eric/pico-extras/src/rp2_common/pico_sleep/include/pico/sleep.h:77:46: note: expected 'struct timespec *' but argument is of type 'datetime_t *'
77 | void sleep_goto_sleep_until(struct timespec *ts, aon_timer_alarm_handler_t callback);
| ~~~~~~~~~~~~~~~~~^~
make[2]: *** [CMakeFiles/pico-WSPRer.dir/WSPRbeacon/WSPRbeacon.c.o] Error 1
make[1]: *** [CMakeFiles/pico-WSPRer.dir/all] Error 2
make: *** [all] Error 2
Can you advise please.
The text was updated successfully, but these errors were encountered: