mirror of
https://github.com/Dasharo/zephyr.git
synced 2026-03-06 14:57:20 -08:00
As both C and C++ standards require applications running under an OS to
return 'int', adapt that for Zephyr to align with those standard. This also
eliminates errors when building with clang when not using -ffreestanding,
and reduces the need for compiler flags to silence warnings for both clang
and gcc.
Most of these changes were automated using coccinelle with the following
script:
@@
@@
- void
+ int
main(...) {
...
- return;
+ return 0;
...
}
Approximately 40 files had to be edited by hand as coccinelle was unable to
fix them.
Signed-off-by: Keith Packard <keithp@keithp.com>
.. _th02-sample: TH02: Temperature and Humidity Monitor ###################################### Overview ******** This sample periodically reads temperature and humidity from the Grove Temperature & Humidity Sensor (TH02) and display the results on the Grove LCD display. Requirements ************ This sample uses the TH02 sensor and the grove LCD display. Both devices are controlled using the I2C interface. More details about the sensor and the display can be found here: - `Grove Temperature And Humidity`_ - `Grove LCD Module`_ Wiring ****** The easiest way to get this wired is to use the Grove shield and connect both devices to I2C. No additional wiring is required. Depending on the board you are using you might need to connect two 10K ohm resistors to SDL and and SDA (I2C). The LCD display requires 5 volts, so the voltage switch on the shield needs to be on 5v. References ********** - TH02 (Si7005): https://www.silabs.com/documents/public/data-sheets/Si7005.pdf .. _Grove LCD Module: http://wiki.seeed.cc/Grove-LCD_RGB_Backlight/ .. _Grove Temperature And Humidity: http://wiki.seeed.cc/Grove-TemptureAndHumidity_Sensor-High-Accuracy_AndMini-v1.0/