Hi David,

Update (also for other Jallib users). If I use a 'get function I also need a 
'put function but I am not allowed to make a 'put function without a parameter. 
Nor am I allowed to make to 'put functions (one old and one new).

In order to prevent confusion I had to change the 'get to a regular function 
and replace the put by a clear procedure.

This means that I cannot make it backwards compatible so users that are using 
this library need to make a small addition to their code as already mentioned.

So instead of:
   if rtc_alarm_1_flag then
      rtc_alarm_1_flag = FALSE

You must now use:
   if rtc_alarm_1_flag then
      clear_rtc_alarm_1_flag()

For all JAL users, sorry for any inconvience .

About your next topic. If you have something created I can review it and put it 
on GitHub for you and add it to the release. I do have the following questions:

  1.  Is this chip still in production. I thought I saw somewhere that it was 
end of life.
  2.  I recently made a library for the PCA9685. There seems to be overlap in 
the functionality. Would that library help with your project?

Kind regards,

Rob


________________________________
Van: jallib@googlegroups.com <jallib@googlegroups.com> namens Pinhead 
<pinhead...@gmail.com>
Verzonden: zaterdag 19 november 2022 12:57
Aan: jallib@googlegroups.com <jallib@googlegroups.com>
Onderwerp: Re: Re: [jallib] Small remarks on rtc_ds3231.jal

Great.  I am glad I could bring something to the group ??

In the project I start, I will most probably use a PCA9626 from Nxp.
>From a software point of view, there are several variants of that ship that 
>could be defined in that lib also

I will try to write a lib and if it sounds good, I will submit it for review 
and distribution if you want.

I will try to stick to the guidelines and document it as needed.

If this sparks the interest of someone,  I would be delighted to collaborate.

Greetings from Belgium

David
Le 19 nov. 2022, à 12:41, Rob CJ 
<rob...@hotmail.com<mailto:rob...@hotmail.com>> a écrit:
Hi David,

Found it. I agree with you that writing a 1 will not do anything. According to 
the datasheet is does not mess things up but the use may assume that it can set 
the flag which is not the case.

So in order to do it right I should replace this procedure by a clear alarm 
function like you suggested.

So on the sample program it would be:
   if rtc_alarm_1_flag then
      clear_rtc_alarm_1_flag()

I will make the change and keep the older one with the warning it will be 
deprecated.

Thanks for the feedback.

Kind regards,

Rob

________________________________
Van: jallib@googlegroups.com <jallib@googlegroups.com> namens Pinhead 
<pinhead...@gmail.com>
Verzonden: zaterdag 19 november 2022 12:12
Aan: jallib@googlegroups.com <jallib@googlegroups.com>
Onderwerp: Re: [jallib] Small remarks on rtc_ds3231.jal

Hi,

Yes, indeed, we do not use the same version.   In your datasheet,  it is on 
page 14.
See screenshot attached.

Enjoy your day


David
Le 19 nov. 2022, à 11:50, Rob CJ < 
rob...@hotmail.com<mailto:rob...@hotmail.com>> a écrit:
Hi David,

Well spotted, the cosmetic issue. Will fix that.

I do not understand the other issue since in page 15 of my datasheet I cannot 
find what you mention, see attached datasheet that I used.

Next to that I tested the alarm functions and it seems to work correctly.

Can you send me the datasheet you are refering to?

Thanks.

Kind regards,

Rob





________________________________
Van: jallib@googlegroups.com <jallib@googlegroups.com> namens 
pinhe...@gmail.com <pinhead...@gmail.com>
Verzonden: zaterdag 19 november 2022 01:43
Aan: jallib <jallib@googlegroups.com>
Onderwerp: [jallib] Small remarks on rtc_ds3231.jal

Hi,

As I am using this library right now, I have small remarks:

- Cosmetic: In the comments on lines 254 and 259, reference is made to the 
SSD1306
- Functionality leading to mistakes: the logic in the "procedure 
rtc_alarm_2_flag'put(bit in set_flag)" and "procedure rtc_alarm_1_flag'put(bit 
in set_flag)" allows to set the bit to 1.   But on page 15 of the datasheet, it 
is stated that this bit may only be written to 0.   Allowing the user to write 
it to 1 may lead to mistakes, since the user may believe it actually worked, 
when it didn't.   My suggestion: Deprecate with a WARN at compile time those 2 
procedures and replace them with a "procedure clear_rtc_alarm_2_flag'put"(and 
the same for alarm 1)

Just my 2c, hoping to help, and not to critisize the good work done !

Enjoy your week-end.

David.

--
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jallib+unsubscr...@googlegroups.com<mailto:jallib+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jallib/0ff7bd5b-3f82-4f64-9db1-fde6b7b4ac6b%40gmail.com<https://groups.google.com/d/msgid/jallib/0ff7bd5b-3f82-4f64-9db1-fde6b7b4ac6b%40gmail.com?utm_medium=email&utm_source=footer>.

--
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jallib+unsubscr...@googlegroups.com<mailto:jallib+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jallib/GVXP195MB1637C8E697DBB65E36FBB9ADE6089%40GVXP195MB1637.EURP195.PROD.OUTLOOK.COM<https://groups.google.com/d/msgid/jallib/GVXP195MB1637C8E697DBB65E36FBB9ADE6089%40GVXP195MB1637.EURP195.PROD.OUTLOOK.COM?utm_medium=email&utm_source=footer>.

--
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
jallib+unsubscr...@googlegroups.com<mailto:jallib+unsubscr...@googlegroups.com>.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jallib/eea1f948-d4b4-445b-9c72-abfa3f796c7f%40gmail.com<https://groups.google.com/d/msgid/jallib/eea1f948-d4b4-445b-9c72-abfa3f796c7f%40gmail.com?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"jallib" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jallib+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jallib/GVXP195MB1637DD12766E5920A5B668EDE6089%40GVXP195MB1637.EURP195.PROD.OUTLOOK.COM.

Reply via email to