Getting started in KEIL
Posted: Thu May 19, 2016 8:36 pm
Hey all,
I'm new to chibiOS. I've been looking for a way to escape the bare-metal super loop on the STM32 for awhile now, and I've long since decided to land on chibiOS. It's a really great looking project, and I look forward to learning from all the talented developers here.
I've been looking to setup with KEIL or Embitz- since I can't stand Eclipse for debugging. No problem, right?
I thought I would start with Embitz, since it's free and GCC based. But, the primary developer had given up on adding support for any new STM32 hardware. I think he assumes that all new chips are "locked" into ST's HAL.
This has resulted in failed integration of the F446, which does in-fact have SPL support. So Embitz is out, since it doesn't build for my target.
Keil is pretty great for debugging though, so in setting up for the first time, I noticed that the integration guides are simply out of date.
Maybe this is not such a huge deal on it's own, but it's causing my integration in Keil fail all the time. Here's what I mean.
https://www.youtube.com/watch?v=12TcH09OHmc
This youtube video some guy posted not only looks bad, but it seems like his chibiOS examples in his demo folder include Keil projects already built. But all I have are generic .project files in my 16.1.4 version. I don't even know what program works with such a generic .project filetype.
Fine, so I'll go straight to the integration guide.
http://wiki.chibios.org/dokuwiki/doku.p ... tion_guide
What can I say, it's no longer relevant to the way the project is setup now. ChibiOS is now under a different directory structure with different names and file paths. Now I keep adding tons of files without really knowing those are the actual headers that the guide is trying to describe to me.
So then, how about the guide on the wiki made for KEIL users?
http://wiki.chibios.org/dokuwiki/doku.p ... _rt_how-to
Looks great (at first). But there is no mention of WHY we edit the IRAM2 text field. (Because that's just what you do apparently). Also, the guide tells me to enter in a giant string into the C/C++ custom definitions field:
__heap_base__=Image$$RW_IRAM1$$ZI$$Limit__heap_end__=Image$$RW_IRAM2$$Base
What is this anyway? Again, there is no mention describing WHY we have to do this. But, it doesn't matter. My KEIL installation, (which is NOT 4 years old) claims this string to contain a syntax error. And how could I not agree with it? Who wants to enter in such a cryptic set of $$ signs and underscores just to get a basic build going?
Well, there is only one build option left then. I'll have to use an example build I found somewhere in the middle of github.
https://github.com/GunterO/Keil_ChibiOS_Template
So why does this project present me with 143 build errors? Don't know. I think that's just what you get for trying to use a project someone else built.
Is there anyway to update the integration guide that reflects the current directory structure of chibiOS 16.1.4?
Or does someone know of a KEIL + ChibiOS tutorial that doesn't rely on 4 year-old IDEs and older versions of the RTOS?
If you have a more general comment or suggestion for me at this point, I'm all ears - seriously. I've been trying to get the basic single-thread example up and running on a basic nucleo board for 3 weeks now, with no success.
What should I try next? Thanks guys!
I'm new to chibiOS. I've been looking for a way to escape the bare-metal super loop on the STM32 for awhile now, and I've long since decided to land on chibiOS. It's a really great looking project, and I look forward to learning from all the talented developers here.
I've been looking to setup with KEIL or Embitz- since I can't stand Eclipse for debugging. No problem, right?
I thought I would start with Embitz, since it's free and GCC based. But, the primary developer had given up on adding support for any new STM32 hardware. I think he assumes that all new chips are "locked" into ST's HAL.
This has resulted in failed integration of the F446, which does in-fact have SPL support. So Embitz is out, since it doesn't build for my target.
Keil is pretty great for debugging though, so in setting up for the first time, I noticed that the integration guides are simply out of date.
Maybe this is not such a huge deal on it's own, but it's causing my integration in Keil fail all the time. Here's what I mean.
https://www.youtube.com/watch?v=12TcH09OHmc
This youtube video some guy posted not only looks bad, but it seems like his chibiOS examples in his demo folder include Keil projects already built. But all I have are generic .project files in my 16.1.4 version. I don't even know what program works with such a generic .project filetype.
Fine, so I'll go straight to the integration guide.
http://wiki.chibios.org/dokuwiki/doku.p ... tion_guide
What can I say, it's no longer relevant to the way the project is setup now. ChibiOS is now under a different directory structure with different names and file paths. Now I keep adding tons of files without really knowing those are the actual headers that the guide is trying to describe to me.
So then, how about the guide on the wiki made for KEIL users?
http://wiki.chibios.org/dokuwiki/doku.p ... _rt_how-to
Looks great (at first). But there is no mention of WHY we edit the IRAM2 text field. (Because that's just what you do apparently). Also, the guide tells me to enter in a giant string into the C/C++ custom definitions field:
__heap_base__=Image$$RW_IRAM1$$ZI$$Limit__heap_end__=Image$$RW_IRAM2$$Base
What is this anyway? Again, there is no mention describing WHY we have to do this. But, it doesn't matter. My KEIL installation, (which is NOT 4 years old) claims this string to contain a syntax error. And how could I not agree with it? Who wants to enter in such a cryptic set of $$ signs and underscores just to get a basic build going?
Well, there is only one build option left then. I'll have to use an example build I found somewhere in the middle of github.
https://github.com/GunterO/Keil_ChibiOS_Template
So why does this project present me with 143 build errors? Don't know. I think that's just what you get for trying to use a project someone else built.
Is there anyway to update the integration guide that reflects the current directory structure of chibiOS 16.1.4?
Or does someone know of a KEIL + ChibiOS tutorial that doesn't rely on 4 year-old IDEs and older versions of the RTOS?
If you have a more general comment or suggestion for me at this point, I'm all ears - seriously. I've been trying to get the basic single-thread example up and running on a basic nucleo board for 3 weeks now, with no success.
What should I try next? Thanks guys!