This is my first post, forgive me if my format is strange or incorrect.
I've spent hours on this so far and I'm hoping someone else can see a simple mistake I'm making.
Regarding my (attached) sketch, I am simply storing some 32-bit (unsigned long) numbers in the PROGMEM area.
But when I retrieve them and Serial.print them, they're incorrect.
I expect to see this output:
0 112233
1 44556677
2 8899AABB
3 CCDDEEFF
But I see this:
0 2233
1 6677
2 FFFFAABB
3 FFFFEEFF
It appears that for some reason, Bit31 is acting as a sign and only the lower 16-bits are correctly reported. But these are supposed to be unsigned longs.
Can anyone see a problem with what I'm doing or have a solution?
Thank you so much!!!
You need to get rid of the cast to pointer. It's NOT a pointer, and pointers on AVR are only 16bits, so you're throwing away the high bytes (and then sign-extending, apparently.)