🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    micropython driver for the Epson RX8130CE Real Time Controller used on the Tab5

    Micropython
    1
    1
    12
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • easytargetE
      easytarget
      last edited by easytarget

      I've just finished work on a full feature micropythin driver for this Real Time Controller chip fitted to the Tab5 (and other M5 products etc.)

      https://codeberg.org/easytarget/rx8130ce-micropython

      As an example;

      # Create a I2C object
      # set sda/scl as needed, example below for esp32p4
      
      from machine import I2C, Pin
      i2c = I2C(sda = Pin(31), scl = Pin(32))
      
      # Create a clock object
      from rx8130ce import RX8130
      clock = RX8130(i2c)
      
      print(clock.timestring())
      
      # demo of timer
      from time import sleep
      
      # set a timer for 10s at 64Hz countdown
      clock.timer_enable(count = 640, tsel = 1)
      
      # wait for the timer
      while not clock.timer_interrupt():
        sleep(0.1)
        print('.', end='')
      print('\nTimeout: ', clock.timestring())
      
      # disable timer
      clock.timer_enable(0)
      

      This gives:

      MPY: soft reboot
      MicroPython v1.27.0 on 2025-12-09; Generic ESP32P4 module with WIFI module of external ESP32C6 with ESP32P4
      Type "help()" for more information.
      >>> import test.py
      Fri, 30 Jan 46, 17:16:06
      ....................................................................................................
      Timeout:  Fri, 30 Jan 46, 17:16:16
      >>> 
      

      There is a lot more in the repo, including a demo of how to use the RTC to set the system clock at boot time.

      All the chip 'advanced' features can be accessed via the driver, but are of limited value on the Tab5 due to not having some pins connected, and the /IRQ pin being rendered almost useless by the power management mcu.

      1 Reply Last reply Reply Quote 0
      • First post
        Last post