RTClib is not being recognized as a library

I am very new to arduino and wanted to make a simple clock using RTC 3231 and 16x2 I2C LCD. Everything on my arduino was working perfect. I came to know that to use a RTC, you need a library named RTClib. I installed that library from the official library manager but when i typed in include <RTClib> instead of becoming orange, it stayed black. I took that as a bug and tried to upload the code but it gave me an error:
`Arduino: 1.8.13 (Windows 10), Board: "Arduino Uno"

In file included from C:\Users\admin\Desktop\sketch_dec28c\sketch_dec28c\sketch_dec28c.ino:3:0:

C:\Users\admin\Documents\Arduino\libraries\RTClib-2.0.2\src/RTClib.h:25:10: fatal error: Adafruit_I2CDevice.h: No such file or directory

#include <Adafruit_I2CDevice.h>

      ^~~~~~~~~~~~~~~~~~~~~~

compilation terminated.

exit status 1

Error compiling for board Arduino Uno.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.`

This is my very first project, I decided to download another RTC lib version via Github but it gave me more errors now what should i do?

It might be better if you used the correct syntax and entered

#include <RTCLib.h>

In any case the text colour has no significance. All it means is that the library author did not bother to include the files that describe the keyword colours

Please post your full sketch and full error message using code tags when you do

Hello, since RTClib is not an in-built library, it must be installed, right? Please make sure that you have installed the library in the proper location.

Hi there, I know I might be somewhat late to the party, but it looks like the issue you are having can be solved by including the prerequisite Adafruit BusIO library. Hope this helps!

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.