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

Compilation warnings: Grove_Sunlight_Sensor #19

Closed
matsujirushi opened this issue Sep 30, 2023 · 1 comment
Closed

Compilation warnings: Grove_Sunlight_Sensor #19

matsujirushi opened this issue Sep 30, 2023 · 1 comment
Assignees
Labels
external library UAY Unassigned yet Wio_Tracker_1110_Examples Label for Wio_Tracker_1110_Examples

Comments

@matsujirushi
Copy link
Collaborator

matsujirushi commented Sep 30, 2023

  • Si115X.cpp:15:26: warning: comparison is always false due to limited range of data type [-Wtype-limits]
  • Si115X.cpp:124:22: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'unsigned int'} [-Wsign-compare]
| Wio_Tracker_1110_Examples | grove_light_si1151.ino              | warnings  |  5.92s |
/home/runner/.arduino15/packages/Seeeduino/hardware/nrf52/1.1.5/libraries/Grove_Sunlight_Sensor/Si115X.cpp: In member function 'void Si115X::config_channel(uint8_t, uint8_t*)':
/home/runner/.arduino15/packages/Seeeduino/hardware/nrf52/1.1.5/libraries/Grove_Sunlight_Sensor/Si115X.cpp:15:26: warning: comparison is always false due to limited range of data type [-Wtype-limits]
   15 |     if(len != 4 || index < 0 || index > 5)
      |                    ~~~~~~^~~
/home/runner/.arduino15/packages/Seeeduino/hardware/nrf52/1.1.5/libraries/Grove_Sunlight_Sensor/Si115X.cpp: In member function 'int Si115X::get_int_from_bytes(uint8_t*, size_t)':
/home/runner/.arduino15/packages/Seeeduino/hardware/nrf52/1.1.5/libraries/Grove_Sunlight_Sensor/Si115X.cpp:124:22: warning: comparison of integer expressions of different signedness: 'int' and 'size_t' {aka 'unsigned int'} [-Wsign-compare]
  124 |     for(int i = 0; i < len; i++){
      |                    ~~^~~~~
@KillingJacky
Copy link
Member

Thank you for the fixing Seeed-Studio/Grove_Sunlight_Sensor#12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external library UAY Unassigned yet Wio_Tracker_1110_Examples Label for Wio_Tracker_1110_Examples
Projects
Status: Done
Development

No branches or pull requests

3 participants