<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to Home</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/</link><description>Recent changes to Home</description><language>en</language><lastBuildDate>Thu, 18 Aug 2022 19:23:40 -0000</lastBuildDate><atom:link href="https://forge.codesys.com/drv/mcp7941x/home/Home/feed" rel="self" type="application/rss+xml"></atom:link><item><title>Home modified by aliazzz</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v52
+++ v53
@@ -183,7 +183,7 @@
 The RTC module has been loaded and is permanently activated for exclusive OS only usage.
 CODESYS cannot use the SRAM from the RTC if the resource is in permanent use of the OS.

-# manual RTC-sync 
+## manual RTC-sync 
 Normally a deamon syncs the clock but you can also consider triggering a manual sync for the clock.
 You can override the standard deamon as follows (not mandatory);

&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Thu, 18 Aug 2022 19:23:40 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.comcc21ca4fa182005f0f753037ed17e69a9d6f75d3</guid></item><item><title>Home modified by aliazzz</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v51
+++ v52
@@ -4,98 +4,43 @@
 [[download url=https://forge.codesys.com/drv/mcp7941x/code/HEAD/tree/tags/v0.0.2.1/mcp7491x.package?format=raw label=Package]]

 [TOC]
-# I2C MCP7941x realtime clock
-This chip is the follow-up of the famous DS1307 realtime clock (RTC).
-It enables you to use RETAIN declared variables in your code on a Raspberry Pi or Beaglebone.
-
-This RTC chip is used in the Monarco Hat but it can also be installed separatly as a standalone RTC add-on solution on a break-out board.
-By adding a battery backed SRAM MCP7941x realtime clock to your Raspberry setup you obtain a hardware realtime clock and SRAM capability.
-
-The RTC time itself can be accessed via several "of the shelve" libraries, so I did not bother to implement it (sorry).
-However, obtaining current date and time is demonstrated in the provided example code with help of such an "of the shelve" library.
-
-## Changelog  
-v0.0.2.1 stable initial public release
-
-devdescr.xml: vendor id set to 0003, device id set to 0009, see https://forge.codesys.com/drv/io-drivers/database/Home/ for details.     
-~~~
-    &amp;lt;deviceidentification&amp;gt;
-      &amp;lt;type&amp;gt;500&amp;lt;/type&amp;gt;
-      &amp;lt;id&amp;gt;0003 0009&amp;lt;/id&amp;gt;
-      &amp;lt;version&amp;gt;0.0.2.1&amp;lt;/version&amp;gt;
-    &amp;lt;/deviceidentification&amp;gt;
-~~~
-
-## Usage
-Install the .package file, it provides the library, example and an eula.
-
-For a quick start, open the example code from the package installation directory. You can declare any type of variable as RETAIN.
-If you have several POU's in your program containing RETAIN data, the total accumulated maximum size may not exceed 64 Bytes.
-
-Anytime you write the retained data in your program, the SRAM gets updated with the new values.
-Whenever your runtime stops or reboots, the values are stored in the battery buffered SRAM. 
-If your runtime resumes, the data is restored from SRAM to the userdata auto-magically.
-
-VAR RETAIN
-    abyMyRetainedBytes : ARRAY [0..63] OF BYTES; // maximum size of retained data in SRAM of mcp7491x
-END_VAR
-
-## RETAIN data size restriction of 64 Bytes 
-** If your total RETAIN data exceeds 64 Bytes, anything over this maximum is simply ignored and will not be retained!
-Beware, no error messages or feedback is given if the data exceeds this size **
-
-You can verify this behaviour by opening the test program, re-edit the code for array's of e.g. 96 bytes size, fill it and then cold start the controller. 
-When you enable the runtime, only 64 bytes get reloaded from SRAM.
-
-VAR RETAIN
- abyMyRetainedBytes : ARRAY [0..95] OF BYTES; // Exceeds maximum size of retained data in SRAM of mcp7491x, indexes [64..95] are simply ignored as they will not       physically fit in the SRAM.
-END_VAR
-
-## Performance as performed with the example code
-Tested on a Raspberry Pi 3B+ with singlecore runtime license and using the example code from the package, this so you can verify these results for yourself if you wish.
-If you have any meaningful feedback, please let me know. I will add your testresults to this page.
-
-Test procedure:
-1) Use a single task, configure it as in the table.
-1) Go online, flush the SRAM, then verify the array contents, then Cold reset the controller and press run and check the array again. The array should be empty.
-2) Write the Test sequence, then Cold reset the controller and press run and check the array again, the array should be filled with correct value's.
-
-Tested using Raspberry Pi 3B+ hardware with a Single Core License
-
-Tasktime | Prio | Result
----------- | ---------- | ---------- 
-250ms | 1 | No issue's
-100ms | 1 | No issue's
-50ms | 1 | No issue's
-25ms | 1 | No issue's
-5ms | 1 | No issue's
-1ms | 1 | No issue's
-
-As seen in the table, tasktimes as quick as 1 milliseconds is working correct.
-**Beware, as your mileage may vary because of various reasons e.g. bigger programcode, more tasks, multitasking, etc, etc!**
-
-# Installing the MCP7941 for SRAM/RTC usage in CODESYS
-You can use this driver in combination with the Monarco HAT or any other pcb which uses the MCP7941x Realtimeclock (RTC). 
-It will provide you with 64 bytes battery buffered SRAM Retain support in CODESYS on a Raspberry Pi based hardware, as the Pi has no native SRAM support. 
-
-Getting and setting the time is not implemented in this library but can easily be achieve with several other common flavoured libraries in CODESYS.
-
-## MCP7941x hardware setup
-In order to set up a MCP7941x real time clock, start by connecting it to the RPi and a quartz crystal. 
-The following a rough sketch on how to connect the pins to point one in the right direction - in practice, one might need capacitors to smooth signals or resitors to pull-up the SCL- and SDA-interface, depending for example on the battery and quartz crystal used.
-~~~
-X1: Connect to external 32.768 kHz quartz crystal 
-X2: Connect to external 32.768 kHz quartz crystal
-VBAT: Connect to external battery
-VSS: Connect to GND (e.g. RPi-Pin 9)
-VCC: Connect to RPi-Pin 1 (3.3V)
-MFP: -
-SCL: Connect to RPi-Pin 5 (GPIO3_SCL1)
-SDA: Connect to RPi-Pin 3 (GPIO3_SDA1)
-~~~
-
-## installing the i2c software tools
-After connecting the hardware,  activated the i2c bus of via 
+# Monarco HAT / MCP7941x
+RPi natively has no Real Time Clock and SRAM support. The i2c MCP7941x chip is the successor for the famous DS1307 Real Time Clock (RTC) and Monarco HAT implements MCP7941x as an RTC.
+After correct install and configuration under the host OS, this RTC will provide you with 64 bytes battery buffered SRAM Retain support in CODESYS on a Raspberry Pi based hardware.
+Obtaining the current date and time is achieved through usage of standard CODESYS libraries like SysLibRTC or CAA libraries.
+
+This chip can also be installed as a standalone RTC add-on solution on a break-out board. By wiring a battery backed SRAM MCP7941x RTC chip to your Raspberry/Beaglebone setup you gain both an RTC and RETAIN SRAM capability.
+
+## MCP7941x hardware/wiring setup
+In order to set up a MCP7941x RTC, start by connecting it to the RPi and a quartz crystal. 
+The following a rough sketch on how to connect the pins to point one in the right direction - in practice, one might need capacitors to smooth signals or resistors to pull-up the SCL- and SDA- lines, depending for example on the battery and quartz crystal used.
+
+~~~
+    X1: Connect to external 32.768 kHz quartz crystal 
+    X2: Connect to external 32.768 kHz quartz crystal
+    VBAT: Connect to external battery
+    VSS: Connect to GND (e.g. RPi-Pin 9)
+    VCC: Connect to RPi-Pin 1 (3.3V)
+    MFP: -
+    SCL: Connect to RPi-Pin 5 (GPIO3_SCL1)
+    SDA: Connect to RPi-Pin 3 (GPIO3_SDA1)
+~~~
+
+
+## MCP7941x software setup
+
+**NOTE: Default this chip is configured for access from linux OS, so you cannot get access to the SRAM from CODESYS as linux has permanently claimed this resource.**
+So if you want to use the SRAM under CODESYS you myst performa configuration on the linux OS side
+
+    1. Enable usage in CODESYS
+    2. Permanent Linux access setup 
+
+
+### Enable usage in CODESYS
+
+installing the i2c software tools after connecting 
+the hardware and activation of the i2c bus.
+
 ~~~
 sudo raspi-config
 ~~~ 
@@ -111,11 +56,15 @@
 ## check the adressing/connections
 Once you have it installed check that the RTC has been detected using:
 ~~~
-sudo i2cdetect -y 0  # (if using v1 Raspberry Pi or)
-sudo i2cdetect -y 1  # (if using v2 Raspberry Pi)
-~~~
-
-This will look something like;
+sudo i2cdetect -y 0  # (if using Raspberry Pi 1 or)
+sudo i2cdetect -y 1  # (if using Raspberry Pi 2 or later)
+~~~
+
+    Note: 
+    The MCP7941x has two i2c adresses: 0x57 and 0x6f, if the addresses both show up they are ready for communication.
+    0x57 leads to the EEPROM, a status register and a unique ID register whereas 0x6f is the address that leads to the SRAM and RTC itself
+    
+This output should now look something like this;
 ~~~
 aliazzz@Raspbian:~ $ sudo i2cdetect -y 1
      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
@@ -129,42 +78,11 @@
 70: -- -- -- -- -- -- -- --
 ~~~

-The MCP7941x has two i2c adresses: 0x57 and 0x6f,  if the addresses show up they are ready for communication.
-0x57 leads to the EEPROM, a status register and a unique ID register whereas 0x6f is the address that leads to the SRAM and RTC itself
-
-**The MCP7941x is now ready for use with CODESYS**
-
-
-## installing the MCP7941 for permanent use under linux
-
-**NOTE: If you install this chip for linux use, you cannot get access to the SRAM from CODESYS as linux has permanently claimed this resource!
-Continue at your own risk **
-
-In order to establish a permanent linux OS connection add, first follow the steps to enable the RTC for use in CODESYS (see above)
-Once the above steps are completed, follow the below steps.
-
-In "/etc/modules" 
-~~~
-sudo nano /etc/modules
-~~~
-add 
-~~~
-rtc-mcp7941x
-~~~
-Edit the file and close it via alt-x and save the changes
-
-In "/boot/config.txt"
-~~~
-sudo nano /boot/config.txt
-~~~
-add
-~~~
-dtoverlay=i2c-rtc,mcp7941x
-~~~
-Again, edit the file and close it via alt-x and save the changes.
-
-Now reboot,
-After reboot the 'sudo i2cdetect' yields;
+
+### 6f ?
+The MCP7941x is now ready for use with CODESYS =) and you can skip to chapter manual RTC-sync
+
+However, if the table shows UU the RTC module has been loaded and is permanently activated for exclusive OS only usage, please continue below.
 ~~~
 aliazzz@Raspbian:~ $ sudo i2cdetect -y 1
      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
@@ -177,8 +95,97 @@
 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- UU
 70: -- -- -- -- -- -- -- --
 ~~~
-The RTC module has been loaded and activated and the RTC is used by linux.
-
+
+### UU shows up
+If you see "UU" instead of 0x6f for your RTC after the previous steps, this likely is caused by loading of the 
+incorrect rtc_ds1307 driver or by permanently claim the RTC access by linux.
+
+This can have 2 causes, either you 
+
+    1. configure the Hat for the first time and you have not blacklisted loading of the incorrect rtc_ds1307 driver yet
+    2. deliberately permanently claimed the RTC access
+
+#### Loading of the incorrect driver (rtc_ds1307 module)
+
+This is triggered in the OS by the plug&amp;amp;play mechanism of the Monarco HAT onboard EEPROM.
+So we have to prevent Linux to load the incorrectr driver by blacklisting it and thus "free" its resource on the i2c bus.
+Not to worry, we must do some extra configuring.
+
+To disable automatic loading of the driver, use the following:
+~~~
+sudo -s
+echo "blacklist rtc_ds1307" &amp;gt; /etc/modprobe.d/monarco-rtc.conf
+~~~
+
+The same can be done for the onboard DS2482-100 1-Wire controller
+~~~
+sudo -s
+echo "blacklist ds2482" &amp;gt; /etc/modprobe.d/monarco-onewire.conf
+~~~
+
+Now reboot the RPi and run
+~~~
+aliazzz@Raspbian:~ $ sudo i2cdetect -y 1
+     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
+00: -- -- -- -- -- -- -- -- -- -- -- -- --
+10: -- -- -- -- -- -- -- -- 18 -- -- -- -- -- -- --
+20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- --
+60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 6f
+70: -- -- -- -- -- -- -- --
+~~~
+
+The MCP7941x is now ready for use with CODESYS =)
+
+
+#### Claim RTC resource for exclusive OS only usage (UU)
+In order to claim a **permanent** linux OS access add, first follow the all the previous steps to enable the RTC for use in CODESYS (see above), 
+and continue to follow then follow the below steps. Basicly you **UNDO** freeing the RTC for CODESYS.
+
+In "/etc/modules" 
+~~~
+sudo nano /etc/modules
+~~~
+add 
+~~~
+rtc-mcp7941x
+~~~
+Edit the file and close it via alt-x and save the changes
+
+In "/boot/config.txt"
+~~~
+sudo nano /boot/config.txt
+~~~
+add
+~~~
+dtoverlay=i2c-rtc,mcp7941x
+~~~
+Again, edit the file and close it via alt-x and save the changes.
+
+Now reboot,
+After reboot the 'sudo i2cdetect' yields;
+
+~~~
+aliazzz@Raspbian:~ $ sudo i2cdetect -y 1
+     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
+00: -- -- -- -- -- -- -- -- -- -- -- -- --
+10: -- -- -- -- -- -- -- -- 18 -- -- -- -- -- -- --
+20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
+50: -- -- -- -- -- -- -- 57 -- -- -- -- -- -- -- --
+60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- UU
+70: -- -- -- -- -- -- -- --
+~~~
+
+The RTC module has been loaded and is permanently activated for exclusive OS only usage.
+CODESYS cannot use the SRAM from the RTC if the resource is in permanent use of the OS.
+
+# manual RTC-sync 
+Normally a deamon syncs the clock but you can also consider triggering a manual sync for the clock.
+You can override the standard deamon as follows (not mandatory);

 In "/lib/udev/hwclock-set" 
 ~~~
@@ -200,31 +207,97 @@
 sudo hwclock -r
 ~~~

-**The RTC is now in permanent use of the Linux OS!
-CODESYS cannot use the SRAM from the RTC if the resource is in permanent use of the OS.**
-
-
-## On a Monarco HAT UU shows up but you did not install the RTC for use on the linux side..
-As for loading the rtc_ds1307 module, this is caused by the plug&amp;amp;play mechanism of the Monarco HAT and its onboard EEPROM.
-For details, see https://www.raspberrypi.org/blog/introducing-raspberry-pi-hats/, namely this:
-"The EEPROM holds the board manufacturer information, GPIO setup and a thing called a ‘device tree‘ fragment – basically a description of the attached hardware that allows Linux to automatically load the required drivers."
-
-To disable automatic loading of the driver, use the following:
-~~~
-sudo -s
-echo "blacklist rtc_ds1307" &amp;gt; /etc/modprobe.d/monarco-rtc.conf
-~~~
-The same can be done for the onboard DS2482-100 1-Wire controller (not sure how 1-Wire bus is handled in Codesys)
-~~~
-sudo -s
-echo "blacklist ds2482" &amp;gt; /etc/modprobe.d/monarco-onewire.conf
-~~~
-
-
-# Enjoy!
-Enjoy your RETAIN data support for CODESYS on Raspberry Pi platform!
-
-Monarco Hat Realtime Clock SRAM Support Package
-[[download url=https://forge.codesys.com/drv/mcp7941x/code/HEAD/tree/tags/v0.0.2.1/mcp7491x.package?format=raw label=Package]]
+# CODESYS usage
+## RETAIN data size &amp;lt;= 64 Bytes
+Install the .package file, it provides the library, example and an EULA.
+For a quick start, open the example code from the package installation directory. 
+You can declare any type of variable as RETAIN. If you have several POU's in your program containing RETAIN data,
+**the total accumulated maximum RETAIN size should not exceed 64 Bytes**.
+
+Anytime you write the retained data in your program, the SRAM gets updated with the new values.
+Whenever your runtime stops or reboots, the values are stored in the battery buffered SRAM. 
+If your runtime resumes, the data is restored from SRAM to the userdata auto-magically, no extra code needed.
+
+Example 1) 64 bytes in a single declaration;
+~~~
+VAR RETAIN
+    abyRetainData : ARRAY [0..63] OF BYTES; // maximum size RETAIN in SRAM of mcp7491x
+END_VAR
+~~~
+
+Example 2) 64 bytes via multiple declarations;
+~~~
+
+VAR RETAIN
+    abyRetainData1 : ARRAY [0..31] OF BYTES; //32 Bytes
+END_VAR
+
+VAR RETAIN
+    iSomeValue1, iSomeValue2 : INT; // 2* 2 Bytes (4)
+    rSomeOtherValue1, rSomeOtherValue2 : REAL; // 2 * 4 Bytes (8)
+    dwYetAnotherValue1: DWORD; // 4 Bytes (4)
+    // 4+8 + 4 = 16 Bytes
+END_VAR
+
+VAR RETAIN
+    R : ARRAY [0..15] OF BYTES; //16 Bytes 
+END_VAR
+~~~
+
+## RETAIN data size &amp;gt; 64 Bytes 
+**If your total RETAIN data exceeds 64 Bytes, anything over this maximum is simply ignored** and will not be retained. 
+Beware, no error messages or any feedback feedback is given if the data exceeds this size!
+
+You can verify this behavior by opening the test program, re-edit the code for array's of e.g. 96 bytes size, fill it and then cold start the controller. 
+When you enable the runtime, only 64 bytes get reloaded from SRAM.
+
+Example 3) &amp;gt;64 bytes in a single declaration;
+~~~
+VAR RETAIN
+    abyMyRetainedBytes : ARRAY [0..95] OF BYTES; // Exceeds maximum size, indexes [64..95] are ignored as they will not physically fit in the SRAM.
+END_VAR
+~~~
+
+Example 4) &amp;gt;64 bytes via multiple declarations;
+~~~
+
+VAR RETAIN
+    abyRetainData1 : ARRAY [0..48] OF BYTES; //48 Bytes
+END_VAR
+
+VAR RETAIN
+    iSomeValue1, iSomeValue2 : INT; // 2* 2 Bytes (4)
+    rSomeOtherValue1, rSomeOtherValue2 : REAL; // 2 * 4 Bytes (8)
+    dwYetAnotherValue1: DWORD; // 4 Bytes (4)
+    // 4+8 + 4 = 16 Bytes
+END_VAR
+
+VAR RETAIN
+    R : ARRAY [0..32] OF BYTES; //32 Bytes 
+END_VAR
+~~~
+
+# Performance
+Tested on a Raspberry Pi 3B+ with single core runtime license and using the example code from the package, you are welcome to verify if you wish.
+
+Test procedure:
+1) Use a single task, configure it as in the table.
+1) Go online, flush the SRAM, then verify the array contents, then Cold reset the controller and press run and check the array again. The array should be empty.
+2) Write the Test sequence, then Cold reset the controller and press run and check the array again, the array should be filled with correct value's.
+
+Raspberry Pi CODESYS SL (no MC) run on 3B+ hardware with Raspbian Buster latest release
+
+Tasktime | Prio | Result
+---------- | ---------- | ---------- 
+250ms | 1 | No issue's
+100ms | 1 | No issue's
+50ms | 1 | No issue's
+25ms | 1 | No issue's
+5ms | 1 | No issue's
+1ms | 1 | No issue's
+
+As seen in the table, tasktimes as quick as 1 milliseconds are working correct.
+**Beware, your mileage may vary, due to hardware/OS/tasktime etc etc**
+

 [TOC]
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Thu, 18 Aug 2022 19:22:37 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.coma2a3dea0b9f677715747d67cb1cb8aa128f662a6</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=25#c1fb</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;now I've opened a thread in the forum: &lt;a href="https://forge.codesys.com/forge/talk/Deutsch/thread/a73b9e4a96/"&gt;https://forge.codesys.com/forge/talk/Deutsch/thread/a73b9e4a96/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Perhaps, you can look in in my new code? &lt;br/&gt;
Maybe you can discover a mistake... :-)&lt;/p&gt;
&lt;p&gt;Thx,&lt;br/&gt;
wayne&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">wayne</dc:creator><pubDate>Fri, 03 Apr 2020 06:42:21 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com03fcd395432b022ae6906cb7a8a0bda113bd5406</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=250#668f/5dcc</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Some advice: Never try to use a library for hardware it is not written for (!)&lt;br/&gt;
In the most negative scenario your hardware could brick or short circuit.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Thu, 02 Apr 2020 10:26:12 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com38dabc34e7a5adf6b56f22d96d8a8321bbef641a</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=25#668f</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Ahh... &lt;br/&gt;
I've looked into the data sheets (that was a good hint ;-) and there was the first problem.&lt;br/&gt;
The adressing is different (2 bytes for the adress)&lt;/p&gt;
&lt;p&gt;Yes, i'll run it on a rpi and the i2c detects the 24c32.&lt;/p&gt;
&lt;p&gt;OK, i will study the data sheet a little bit longer and then create a new CForge project.&lt;/p&gt;
&lt;p&gt;Thx,&lt;br/&gt;
wayne&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">wayne</dc:creator><pubDate>Thu, 02 Apr 2020 07:43:12 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com1fd6ab036497ee026a0aae1b9349131282dec5c0</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=250#347f/ef2f</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Surely you can use this library as a basis for your needs. It would be even better if you would start a new CForge project for it. If you do, we can help even better you with implementation for it.&lt;/p&gt;
&lt;p&gt;You wote *The i2c-adress is also 16#57, At the moment, after a power failure, the retain data is "0"... *&lt;/p&gt;
&lt;p&gt;The AT24C is a dedicated EEPROM, while the MCP7941x is a multipurpose package (RTC, Calendar and EEPROM) made by a different brand, so if it works out of the box, that would be sheer luck.&lt;/p&gt;
&lt;p&gt;I think you should download and study the data sheets for your AT24C and the MCP7941x. After studying both data sheets and the library for the MCP7941x you can rewrite it to suit your specific needs.&lt;/p&gt;
&lt;p&gt;PS, I assume you run it on a Raspberry pi. &lt;br/&gt;
Have you checked if the i2c master detects it? When your runtime sees the ic, then you can start debugging.&lt;/p&gt;
&lt;p&gt;Good luck!&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Tue, 31 Mar 2020 16:08:46 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com7c69b66aa05b38e887f47a4d0a60a933b35a80d4</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=25#347f</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hello aliazzz,&lt;/p&gt;
&lt;p&gt;I want to use the Eeprom AT24C (4096x8) on a DS3231.&lt;br/&gt;
What do I've to change in the code?&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The i2c-adress is also 16#57, &lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;At the moment, after a power failure, the retain data is "0"... &lt;/p&gt;
&lt;p&gt;Thx,&lt;br/&gt;
wayne&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">wayne</dc:creator><pubDate>Tue, 31 Mar 2020 15:14:52 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com856dd7d59afa6296ca85c7a369cbf40e20dab3d6</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=100#2f47/7b40/e3f1</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Ehm, to rephrase it: the Retain mechanism in Codesys will compile but will not work in the standard raspberry pi hardware. This package enables the user to leverage battery backed up hardware sram support in a raspberry pi via the retain mechanisme which will work in combination with this library.&lt;/p&gt;
&lt;p&gt;The smallest working interval at which it works  stable was T#1msec.&lt;br/&gt;
Your mileage may vary!&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Tue, 11 Feb 2020 19:38:36 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com86ad8f5610686f2c447de9dcda8e6e1c4119e45c</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=25#2f47/7b40</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;AFAIK the driver doesn't change the retain strategy, but it stores and restores the data additionally into the external chip.&lt;/p&gt;
&lt;p&gt;&lt;a class="user-mention" href="/u/aliazzz/"&gt;@aliazzz&lt;/a&gt; what is the interval in which the data is stored?&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Ingo</dc:creator><pubDate>Tue, 11 Feb 2020 19:03:42 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.comae098e411d807d1bf5599b21eca4b4a34f1d789f</guid></item><item><title>Discussion for Home page</title><link>https://forge.codesys.com/drv/mcp7941x/home/Home/?limit=100#2f47/509e</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hi, &lt;/p&gt;
&lt;p&gt;Thank you!&lt;/p&gt;
&lt;p&gt;Retain data is not supported by the raspberry pi runtime by design of the hardware. Raspberry Pi has to my knowledge never been released with built in SRAM or battery backed up ram or similar.&lt;br/&gt;
This library focuses purely on realisation of retain data with an mcp7941x RTC Chip with built in SRAM.&lt;br/&gt;
If you wish to implement a workaround via a textfile, you are free to do so yourself as it is not part of the mcp7941x RTC Chip.&lt;/p&gt;
&lt;p&gt;With kind regards&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">aliazzz</dc:creator><pubDate>Tue, 11 Feb 2020 17:26:33 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.com41d8a3c8f973f5f459ff64359994fd0d1c64120d</guid></item></channel></rss>