robotastic / ANCS-Library

Library to handle ANCS notifications with an AVR and Nordic's nrf8001
53 stars 8 forks source link

Date and Time Issue #14

Open zkprogram opened 8 years ago

zkprogram commented 8 years ago

Hi, I was trying to use the date and time attributes and I kept coming out with values that were completely wrong. After looking at the code, I found some errors that I corrected in the attached files. First, buffer only needed to have 4 or 2 added to it each time. Also, the time.Y was defined as an 8 bit integer, which could not hold the correct date of 2016.

I also added a way to retrieve seconds with time.s.

I attached the corrected files as PDFs under the same names as the originals. ancs_data_source.cpp.pdf ancs_notification.h.pdf