[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Simulavr-devel] [PATCH] use static callbacks instead of template pa
From: |
panic |
Subject: |
Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg |
Date: |
Sat, 17 Jun 2017 18:35:00 +0000 |
Hi,
Michael Hennebry:
> The PINx toggle of PORTx bits is not a new feature.
> simulavr must support this.
> A RMW implementation of SBI also does not work on registers with interrupt
> flags.
At least according to avrlibc doc, this is not recommended for interrupt
flags:
http://www.nongnu.org/avr-libc/user-manual/FAQ.html#faq_intbits
http://www.atmel.com/webdoc/avrlibcreferencemanual/FAQ_1faq_intbits.html
> That does not imply the goodness of a major data structure organization.
> I note that an SBI instruction can only address registers on which it works.
> Allowing extra functionality in other registers should not cause problems.
>
> Note that on some old AVRs, SBI *is* RMW and their datasheets reflect this.
>
> The confusing cyclic reference is called the curiously recurring template
> pattern.
> Not evil.
> Pointers to void are not preferable.
> As a rule, in C++, pointers to void are a bad idea.
what about pointers to Hardware instead? This is the least common
denomininator.
This should also avoid the template altogether, shouldn't it?
> I'm not clear on the template parameter type issue.
> template <typename T> class { ... public: typedef T parametertype; ... } ;
Cheers,
panic
- [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/15
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Klaus Rudolph, 2017/06/16
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/16
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/16
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Klaus Rudolph, 2017/06/17
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/17
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Michael Hennebry, 2017/06/17
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg,
panic <=
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/17
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/17
- [Simulavr-devel] SBI vs. PINx and interrupt flag registers, Michael Hennebry, 2017/06/19
- Re: [Simulavr-devel] SBI vs. PINx and interrupt flag registers, panic, 2017/06/19
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Michael Hennebry, 2017/06/19
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/19
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/25
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, panic, 2017/06/29
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Michael Hennebry, 2017/06/29
- Re: [Simulavr-devel] [PATCH] use static callbacks instead of template param for IOReg, Klaus Rudolph, 2017/06/30