Skip to content
New issue

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

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

Already on GitHub? # to your account

stm32: add new device package #379

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from
Open

Conversation

deadprogram
Copy link
Member

This PR switches all references to device/stm32 over to the tinygo.org/x/device package repo location.

Signed-off-by: deadprogram <ron@hybridgroup.com>
Signed-off-by: deadprogram <ron@hybridgroup.com>
@deadprogram deadprogram requested a review from sago35 February 19, 2022 10:46
@deadprogram
Copy link
Member Author

Got past the original error, but now hit a different one:

tinygo build -size short -o ./build/test.hex -target=nucleo-wl55jc ./examples/sx126x/lora_rxtx/
error: Linking globals named 'WWDG_IRQHandler': symbol multiply defined!

I am able to reproduce this on my local machine as well with the latest dev build.

@aykevl can you please help out here?

@sago35
Copy link
Member

sago35 commented Feb 19, 2022

I think export has been executed multiple times.
Is there something that needs to be changed in tinygo?

https://github.com/tinygo-org/device/blob/main/stm32/stm32wle5.go
line 197

//export WWDG_IRQHandler
func interruptWWDG() {
	callHandlers(IRQ_WWDG)
}

@aykevl
Copy link
Member

aykevl commented Feb 19, 2022

@deadprogram my guess is that you still have a device/stm32 import somewhere. You could remove src/device/stm32 to check for this.

@deadprogram
Copy link
Member Author

I had removed that directory from my local TinyGo (TINYGOROOT) install even before that error.

@aykevl
Copy link
Member

aykevl commented Feb 19, 2022

Huh. Weird. It is defined in two packages: tinygo.org/x/device/stm32 and vendor/tinygo.org/x/device/stm32. That's not something that should happen.

@aykevl
Copy link
Member

aykevl commented Feb 19, 2022

This might be intended behavior of the Go toolchain (go list). In which case I would really need to rethink how to implement this feature.

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

Successfully merging this pull request may close these issues.

3 participants