Hello,
It seems that the latest ChibiOS/RT version does not support STM8 any more. Which was the latest release still supporting that platform? I want to try get it compiled with SDCC (Small Device C Compiler)...
regards
STM8 support dropped?
Moderators: RoccoMarco, lbednarz, utzig, tfAteba, barthess
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: STM8 support dropped?
Hi,
The STM8 support is present in 2.4.x and is still present in 2.6.x but untested.
The problem are the compilers:
1) Raisonance: works but the generated code could be better.
2) Cosmic: has bugs preventing the test suite execution completion.
3) IAR: limited to 8k does not allow testing.
When the STM8 support will be released officially in SDCC probably I will give it another try, probably I would also drop all the other compilers. You may definitely try a port for SDCC, it should not be difficult.
Giovanni
The STM8 support is present in 2.4.x and is still present in 2.6.x but untested.
The problem are the compilers:
1) Raisonance: works but the generated code could be better.
2) Cosmic: has bugs preventing the test suite execution completion.
3) IAR: limited to 8k does not allow testing.
When the STM8 support will be released officially in SDCC probably I will give it another try, probably I would also drop all the other compilers. You may definitely try a port for SDCC, it should not be difficult.
Giovanni
Re: STM8 support dropped?
Thanks Giovanni,
I did a quick test with the current SDCC snapshot (SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.3.2 #8938 (Jan 28 2014) (Mac OS X i386)), but it seems it does not like empty structs:
Are they there for doxygen?
and some macros:
I did a quick test with the current SDCC snapshot (SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.3.2 #8938 (Jan 28 2014) (Mac OS X i386)), but it seems it does not like empty structs:
Code: Select all
ChibiOS_2.4.5/os/kernel/templates/chcore.h:123: syntax error: token -> '}' ; column 1
Are they there for doxygen?
and some macros:
Code: Select all
ChibiOS_2.4.5/os/kernel/include/ch.h:110: error 176: sizeof applied to an incomplete type
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: STM8 support dropped?
Hi,
The empty struct are only in template files, you are not supposed to compile templates. See how the other 3 STM8 ports are placed under "ports" and create a 4th port under ./ports/SDCC/STM8
Giovanni
The empty struct are only in template files, you are not supposed to compile templates. See how the other 3 STM8 ports are placed under "ports" and create a 4th port under ./ports/SDCC/STM8
Giovanni
Re: STM8 support dropped?
Thanks for pointing to the right direction. I created a new port. However I'm not sure what are equivalents in SDCC for far/near/tiny/const...
Other problem I found trying to compile the STM8S discovery demo from ChibiOS:
Seems it's the STACK_ALIGN macro. It makes the passed value negative (0x00A1 -> 0xFFA1)
SDCC bug?
Other problem I found trying to compile the STM8S discovery demo from ChibiOS:
Code: Select all
ChibiOS_2.4.5/test/test.h:80: error 195: Size of array 'T0' is negative
Seems it's the STACK_ALIGN macro. It makes the passed value negative (0x00A1 -> 0xFFA1)
SDCC bug?
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: STM8 support dropped?
Can't tell, I should look at the code. It could also be an error in the macro.
Giovanni
Giovanni
Re: STM8 support dropped?
Is now a good timing to reconsider stm8 support?
Now SDCC, like 3.6.0, supports stm8 quite well. The community has developed a patch on STM standard Periph Libs.
https://github.com/gicking/STM8-SPL_SDCC_patch/
I personally have tried the patched lib with SDCC on several typical boards, and I will keep doing it. https://github.com/aguegu/stm8demos
And check this out:
http://www.colecovision.eu/stm8/compilers.shtml
Now SDCC, like 3.6.0, supports stm8 quite well. The community has developed a patch on STM standard Periph Libs.
https://github.com/gicking/STM8-SPL_SDCC_patch/
I personally have tried the patched lib with SDCC on several typical boards, and I will keep doing it. https://github.com/aguegu/stm8demos
And check this out:
http://www.colecovision.eu/stm8/compilers.shtml
- Giovanni
- Site Admin
- Posts: 14444
- Joined: Wed May 27, 2009 8:48 am
- Location: Salerno, Italy
- Has thanked: 1074 times
- Been thanked: 921 times
- Contact:
Re: STM8 support dropped?
Hi,
Support has been dropped after 2.6 because lack of interest/feedback and, mainly, me being tired to deal with bad proprietary toolchains.
What about debugging and ST-Link support? the compiler is just one of the required element. Porting the code from 2.6 should be easy.
Giovanni
Support has been dropped after 2.6 because lack of interest/feedback and, mainly, me being tired to deal with bad proprietary toolchains.
What about debugging and ST-Link support? the compiler is just one of the required element. Porting the code from 2.6 should be easy.
Giovanni
Re: STM8 support dropped?
Both ST-Link v1/v2 works fine with stm8flash.
I do not know how to debug on stm8, stm32 also, with GDB. All I got is one or two blinking led and serial output, and building my projects little step by step.
I know it is a lot of work. And I understand why you drop support.
There is another rtos called Atomthreads, http://atomthreads.com/, claims it supports stm8. But at the first glance, it is lack of the HAL layer. I may try that first as long as I got enough understanding about the chip.
I do not know how to debug on stm8, stm32 also, with GDB. All I got is one or two blinking led and serial output, and building my projects little step by step.
I know it is a lot of work. And I understand why you drop support.
There is another rtos called Atomthreads, http://atomthreads.com/, claims it supports stm8. But at the first glance, it is lack of the HAL layer. I may try that first as long as I got enough understanding about the chip.
Who is online
Users browsing this forum: No registered users and 9 guests