. Wow, you're right. Thank you so much. I would have taken forever to get to 
this. This tells me I need to get into the opcodes quickly. Right now I'm still 
feeling around the mnemonics. Its been a week or so since I started working 
with the STM8 chips.
The source from where I copied the stm8s.h file is 
https://github.com/lujji/stm8-bare-min/blob/master/stm8s/lib/stm8s.hThat's 
where the 5300 has no 0x. I've given them a heads up!
I'll post this on the sdcc user board also for the public.
Thank you, Thank you, Thank you !!
Thanks and Warm Regards
Shiv




    On Monday, August 5, 2019, 09:00:50 PM GMT+5:30, Richard Hodges 
<rich...@hodges.org> wrote:  
 
 On 2019-08-05 09:10, Shivakumar R wrote:
> Thank you Richard. You're a gem!
> 
> Here goes:

>       000033                        155 00106$:
>                                     156 ;test5.c: 32: TIM2_SR1 &= ~(1 <<
> TIM2_SR1_UIF);
>       000033 72 11 14 B8      [ 1]  157 bres 5304, #0

Look at your TIM2_SR1 definition. I bet you will find the "0x" is
missing from 5304.

Actually, it looks like you should look at ALL of your TIM2 definitions.
The compiler sees them as decimal, not hex. So nothing with TIM2 works.

Well, it would be nice if all problems were this simple.

All the best,
-Richard


> On Monday, August 5, 2019, 02:35:42 PM GMT+5:30, Richard Hodges
> <rich...@hodges.org> wrote:
> 
> 
> On 2019-08-04 23:51, Shivakumar R via Sdcc-user wrote:
>> Hi
>> Thank you for your test of my code. I had earlier checked the signal on
>> the scope, but verified it once again after seeing your response. 
>> The signal pulses hi when the LED is ON, then remains at GND after the 5
>> count pulses are done. can I post videos here? I could show the board
>> (not) working.
> 
> Send my your .lst file and I will check the assembly code against mine.
> There might be a wrong value somewhere.
  
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to