Re: [fpc-devel] AVR embedded Atmega 328p interrupts

2015-11-29 Thread Andrew Haines
On 11/29/2015 02:13 PM, Jeppe Johansen wrote: Not sure the timer initialization is right, but it looks ok. One thing you need is the interrupt procedure directive: procedure TIMER0_overflow; interrupt; public name 'TIMER0_COMPA_ISR'; Otherwise it'll probably reset at some point. Ok I got it

[fpc-devel] AVR embedded Atmega 328p interrupts

2015-11-29 Thread Andrew Haines
Hi, I am experimenting with the avr embedded compiler from trunk and am trying to set an interrupt. I am not sure how to do it. The interrupt I want to change is TIMER0_COMPA_ISR. I see in the startup code there is: .weak TIMER0_COMPA_ISR and later there is: .set TIMER0_COMPA_ISR,

Re: [fpc-devel] AVR embedded Atmega 328p interrupts

2015-11-29 Thread Andrew Haines
On 11/29/2015 02:13 PM, Jeppe Johansen wrote: Not sure the timer initialization is right, but it looks ok. One thing you need is the interrupt procedure directive: procedure TIMER0_overflow; interrupt; public name 'TIMER0_COMPA_ISR'; Otherwise it'll probably reset at some point. What

Re: [fpc-devel] AVR embedded Atmega 328p interrupts

2015-11-29 Thread Jeppe Johansen
Not sure the timer initialization is right, but it looks ok. One thing you need is the interrupt procedure directive: procedure TIMER0_overflow; interrupt; public name 'TIMER0_COMPA_ISR'; Otherwise it'll probably reset at some point. What compiler commandline are you using? Best Regards,

Re: [fpc-devel] simpleipc issues

2015-11-29 Thread Ondrej Pokorny
On 11.11.2015 17:47, Michael Van Canneyt wrote: I have several remarks: a) Your TBaseSingleInstance class contains too many methods. It assumes you are using advancedipc. I refactored TBaseSingleInstance so that it doesn't depend on advancedipc. I suggest refactoring such a way that

Re: [fpc-devel] AVR embedded Atmega 328p interrupts

2015-11-29 Thread Jeppe Johansen
On 11/29/2015 11:35 PM, Andrew Haines wrote: On 11/29/2015 02:13 PM, Jeppe Johansen wrote: Not sure the timer initialization is right, but it looks ok. One thing you need is the interrupt procedure directive: procedure TIMER0_overflow; interrupt; public name 'TIMER0_COMPA_ISR'; Otherwise