Closed mikrocoder closed 1 year ago
Hello Paul,
I have to ask. Don't you want to or can't you?
I downloaded 2.3.5 and 2.3.7. Both have this, exactly the same:
#if defined(__AVR__)
#define PIN_TO_BASEREG(pin) (portInputRegister(digitalPinToPort(pin)))
#define PIN_TO_BITMASK(pin) (digitalPinToBitMask(pin))
#define IO_REG_TYPE uint8_t
#define IO_REG_BASE_ATTR asm("r30")
#define IO_REG_MASK_ATTR
#if defined(__AVR_ATmega4809__)
#define DIRECT_READ(base, mask) (((*(base)) & (mask)) ? 1 : 0)
#define DIRECT_MODE_INPUT(base, mask) ((*((base)-8)) &= ~(mask))
#define DIRECT_MODE_OUTPUT(base, mask) ((*((base)-8)) |= (mask))
#define DIRECT_WRITE_LOW(base, mask) ((*((base)-4)) &= ~(mask))
#define DIRECT_WRITE_HIGH(base, mask) ((*((base)-4)) |= (mask))
#else
#define DIRECT_READ(base, mask) (((*(base)) & (mask)) ? 1 : 0)
#define DIRECT_MODE_INPUT(base, mask) ((*((base)+1)) &= ~(mask))
#define DIRECT_MODE_OUTPUT(base, mask) ((*((base)+1)) |= (mask))
#define DIRECT_WRITE_LOW(base, mask) ((*((base)+2)) &= ~(mask))
#define DIRECT_WRITE_HIGH(base, mask) ((*((base)+2)) |= (mask))
#endif
Hi Paul,
No, this is not the same as the one I showed. Look closely once. Also, your code does not support AVRxDB controllers. I didn't write this just for fun. I don't want to annoy you. So please take a closer look again.
You wrote "In OneWire v2.3.5 the support for the new AVR controllers is still in there and in v2.3.7 it is not anymore. Why was this deleted?"
But I looked at these 2 versions. They have identical AVR defines. Nothing was deleted, nothing was added.
Hi Paul,
Okay, sorry. Then the case is different. Then I thought your 2.3.5 would have been different and I have a supposedly old working 2.3.5. but already adapted. By whoever. Or I have mixed up something during testing. Sorry. I have been experimenting a lot with Spencekonde DxCore and OneWire. Spencekonde wants the support in your OneWire as well. The reason is that your OneWire is very common. :-)
According to that you have never supported the AVRxDB controllers. Would you want to support the AVRxDB controllers? The necessary change is practically in front of you. :-)
Let's close this issue. Maybe start a new issue, fresh with what you wanted to request, without this baggage of incorrect facts.
Okay.
Just in case this wasn't obvious or common sense, starting an issue with a (wrong) accusation that code was deleted is not the way to make friends and influence people. Please, wait a few days before you open a new issue. Consider the details carefully before you write again.
I asked you to wait a few days
Hi Paul,
In OneWire v2.3.5 the support for the new AVR controllers is still in there and in v2.3.7 it is not anymore. Why was this deleted? There is no problem to add it. For everything concerning AVR only this small change is necessary. Tested with AVR128DB64, Nano Every (ATmega4809) and Arduino Mega2560.
You can use the completely revised and better readable formatted file directly. OneWire_direct_gpio_v2.3.8.zip