Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove volatile from wait loops #434

Merged
merged 3 commits into from
Oct 10, 2023
Merged

Conversation

caternuson
Copy link
Contributor

Removes the volatile qualifier being used in a few wait loops. Doesn't seem necessary. This fixes a compile warn for ESP32. Example warn for ref:

  /home/runner/Arduino/libraries/Adafruit_GFX_Library/Adafruit_SPITFT.cpp:2309:39: warning: '++' expression of 'volatile'-qualified type is deprecated [-Wvolatile]
   2309 |   for (volatile uint8_t i = 0; i < 1; i++)
        |                                       ^

@caternuson
Copy link
Contributor Author

Tested with a Feather ESP32 and PID 1480 (older non eyespi version) TFT and library example:
https://github.com/adafruit/Adafruit_ILI9341/blob/master/examples/graphicstest/graphicstest.ino

@caternuson
Copy link
Contributor Author

@ladyada for review

@ladyada
Copy link
Member

ladyada commented Oct 10, 2023

i'd just delete - current version will be optimized out

@caternuson
Copy link
Contributor Author

@ladyada take it you mean just remove the loops? pushed those changes and confirmed still working with same test setup.

@ladyada
Copy link
Member

ladyada commented Oct 10, 2023

yep lets try it!

@caternuson caternuson merged commit 6338e26 into adafruit:master Oct 10, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants