Search found 12 matches

by tenbaht
Tue Jan 16, 2018 3:13 pm
Forum: STM8
Topic: How do I get my AWU ISR into the interrupt vector table? [SOLVED -- RTFM!]
Replies: 17
Views: 354

Re: How do I get my AWU ISR into the interrupt vector table? [SOLVED -- RTFM!]

Because I'm seeing a little bit of what dannyf mentioned about trimming out unused code. The UART is great for debugging and certain kinds of projects, but my little standalone mailbox detector doesn't need serial communication. The AVR platform automatically trims all that stuff out if you don't u...
by tenbaht
Mon Jan 15, 2018 10:04 am
Forum: STM8
Topic: Same C code, different assembly
Replies: 4
Views: 98

Re: Same C code, different assembly

The halt() is actually #defined as __asm__("halt"). The problem is, that inline assembly disables the internal optimizer of the compiler for the command before, as it can't know for sure if the values of this command are needed for the inline assember commands. This is not a bug, but an intentional ...
by tenbaht
Sat Jan 06, 2018 4:44 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

First, when I plugged my STLink device in, somehow Linux didn't recognize it. I don't know why, because I was messing with it and watching dmesg, and it started working. I think unplugging it and plugging it back in may have done it. Anyway, I had to mess with it a little bit. Second, there was a l...
by tenbaht
Fri Jan 05, 2018 1:42 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

It did take me about 20 minutes to figure out how to get my STLink gadget working. And figuring out which pins to connect to the serial adapter, and how to convert the Serial.print() to Serial_print_s() calls took a little bit longer. I wish there were a couple of sample programs somewhere I could ...
by tenbaht
Wed Dec 06, 2017 12:39 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

gungsukma wrote:
Mon Nov 27, 2017 7:31 am
Please add a menu or something to unlock the protected chip
Good suggestion, thank you. I set up a feature request: https://github.com/tenbaht/sduino/issues/37
I am little busy right now, but I will look into it as soon as time permits.
by tenbaht
Wed Dec 06, 2017 12:31 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

No, you are not expected to copy library files. It should just work - the same way it does for the regular Arduino libs. But it only works for libraries that are modified for use with Sduino as most Arduino libs are written in C++ instead of plain C.

What exactly are you trying to do?
by tenbaht
Mon Oct 23, 2017 9:01 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

STM8 support in SDCC is progressing fast in the last 12 months and IMHO perfectly production ready. The code size still seems to be bigger than with the commercial compilers, but I never investigated in detail how big the difference really is. I really love the very direct access to the inner workin...
by tenbaht
Mon Oct 16, 2017 8:27 am
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

Hi danny, Yes, the SPL is a memory hog and quite complicated to use. The only advantage I can see in using it would be to be prepared for an easier migration to the STM32. That's why I don't use it for Sduino anymore. It is still part of the source code, but the only function still used is the seria...
by tenbaht
Thu Oct 12, 2017 7:15 am
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

Yes, it's the SDCC. I would love to integrate it into the IDE. I tried that at the beginning, but I never got it to work without having at least one C++ input file. I don't remember the full details anymore, but it was something about a hardwired assumption about filename extentions in this build pr...
by tenbaht
Wed Oct 11, 2017 9:20 pm
Forum: STM8
Topic: Introducing Sduino for the STM8
Replies: 26
Views: 1820

Re: Introducing Sduino for the STM8

Hi Roger! Yes, that's what I did. Use pure C, but thanks to some preprocessor magic it almost looks like C++. In many cases you get away with a simple search-and-replace to exchange all class-dots with underscores. Converting an existing Arduino library is harder, though. It would be great if somebo...