littlekernel / lk

LK embedded kernel
MIT License
3.17k stars 621 forks source link

Is it possible to run lk on STM32F401CCU6 ? #244

Open zinahe opened 5 years ago

zinahe commented 5 years ago

Hi,

Sorry if this question has been already been addressed before. I would like to tinker with lk and I'm wondering if I can run it on a board with STM32F401CCU6 (256K Flash/64K RAM).

Thanks,

Zinahe A.

swetland commented 5 years ago

Looks like it mostly has been used with 32F407/417 previously (0f the F4xx sub-family) so you'll probably need to tinker with things slightly for 401 (based on a quick peek at https://github.com/littlekernel/lk/blob/master/platform/stm32f4xx/rules.mk), but it certainly should be doable.

travisg commented 5 years ago

Indeed, as swetland points out it should be runnable. It's been a while since I looked at the 400 family, but I think the 401 and 407 are fairly close. It may require an update of the STM software drop that is in the tree but those are usually quite configurable.

zinahe commented 5 years ago

Great! Thanks for the quick reply. I bought these dirt-cheap STM32F401 boards from AliExpress for less than $5 to play with. I'll report my findings here. Just in case anybody is interested, here is the shchematic

travisg commented 5 years ago

Oh that's a nice board. I should grab one too.

zinahe commented 5 years ago

@travisg, It took a little while but I was finally able to run lk on the tiny STM32F401 board. Most of my time was actually spent on trying to understand the internals of the build system; which I have to say is very well organized. I'd be happy submit a pull-request if there is any interest. Cheers,

travisg commented 5 years ago

Sure, I'll roll in the commit. Thanks!

zinahe commented 5 years ago

Thanks. Pull request is submitted. Let me know if there is any issue.