User Activity

  • Modified a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I apologize for the delay -- for some reason my email put everything into spam folder. n.b. this assembly is from invocation with no optimization. Working case: ; I code from now on! ; ; Starting pCode block S_Timer__TimerFlagRaised code _TimerFlagRaised: ; .line 126; Timer.c bool TimerFlagRaised(timer_handle_t timer) MOVFF FSR2L, POSTDEC1 MOVFF FSR1L, FSR2L MOVFF r0x00, POSTDEC1 MOVFF r0x01, POSTDEC1 MOVLW 0x02 MOVFF PLUSW2, r0x00 ; ;multiply lit val:0x05 by variable r0x00 and store in r0x00 ; .line...

  • Posted a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I apologize for the delay -- for some reason my email put everything into spam folder. Working case: ; I code from now on! ; ; Starting pCode block S_Timer__TimerFlagRaised code _TimerFlagRaised: ; .line 126; Timer.c bool TimerFlagRaised(timer_handle_t timer) MOVFF FSR2L, POSTDEC1 MOVFF FSR1L, FSR2L MOVFF r0x00, POSTDEC1 MOVFF r0x01, POSTDEC1 MOVLW 0x02 MOVFF PLUSW2, r0x00 ; ;multiply lit val:0x05 by variable r0x00 and store in r0x00 ; .line 129; Timer.c return (g_timerEntries[timer].flag == true);...

  • Modified a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I've found the source of the problem. In my code, I have a typedef struct: typedef struct TimerEntry { timer_event_t eventType : 4; timer_state_t state : 1; bool flag : 1; timer_value_t period, count; } TimerEntry; In another part of the code, I have the following function: bool TimerFlagRaised(timer_handle_t timer) { return (g_timerEntries[timer].flag); } This always returns true. However, if I change it to: bool TimerFlagRaised(timer_handle_t timer) { return (g_timerEntries[timer].flag == true);...

  • Posted a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I've found the source of the problem. In my code, I have a typedef struct: typedef struct TimerEntry { timer_event_t eventType : 4; timer_state_t state : 1; bool flag : 1; timer_value_t period, count; } TimerEntry; In another part of the code, I have the following function: bool TimerFlagRaised(timer_handle_t timer) { return (g_timerEntries[timer].flag); } This always returns true. However, if I change it to: bool TimerFlagRaised(timer_handle_t timer) { return (g_timerEntries[timer].flag == true);...

  • Modified a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I can't believe that didn't occur to me. You're absolutely right. Now to find out why...

  • Posted a comment on ticket #2721 on Small Device C Compiler (SDCC)

    The oscilloscope shows a 44.36 uS duration between LED toggles. On a system oscillator of 32 MHz, /4 for 8 MHz, this yields ~355 cycles. These pulses are periodically longer due to an interrupt call. This is not such a long time, and my guess would be that a flag in my code is stuck TRUE for some reason and the main loop code keeps running without interruption. What gives me pause is that the same code runs on XC8 without issue. If there's a compiler quirk I'm overlooking, I'd greatly appreciate...

  • Modified a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I can't believe that didn't occur to me. You're absolutely right. Now to find out why... ( I imagine this means the bug is closed? )

  • Posted a comment on ticket #2721 on Small Device C Compiler (SDCC)

    I can't believe that didn't occur to me. You're absolutely right. Now to find out why...

View All

Personal Data

Username:
plapets
Joined:
2018-02-19 08:52:25

Projects

  • No projects to display.

Personal Tools

Monday.com Logo