Giter Club home page Giter Club logo

i2ctoeepromofht66f318's Introduction

※Access internal EEPROM of HT66F318 (via I2C slave address 0x33) applications

  • Using the host I2C access MCU internal resource GPIO, EEPROM(64bytes), ADC(8ch 12bits), PWM output(10bit), Capture, OLED display...
    專案利用PC or Raspberry Pi or Arduino 軟件主控通過I2C下達通訊指令以存取GPIO port, EEPROM(64bytes), ADC(8ch 12bits), PWM output(10bit), Capture, OLED display...

  • 在MCU資源不足或是應用裝置缺乏時, Host即可透過I2C來控制這個裝置而把UART port use for other

  • Project Option:
    HIRC12M (hi speed internal RC): 可選項有:HXT(400K~16Mhz),HIRC4M,HIRC8M,HIRC12M
    LICR (Low speed internal RC for TB0/TB1): 可選項有:LXT(32.768Khz),LIRC(32Khz)
    So no need any external OSC. or X'tal in this project.
    WatchDog: enable

  • TB0,1 enable LIRC interrupt for 16.05ms, 0.514sec

  • TM0 enable HIRC12M (hi speed internal RC) interrupt for around 200us

  • EEPROM data: 0A 0B 0C 0D 0E 0F 0E 0D

  • I2C slave(address 0x33) SDA(PC5),SCL(PC6) Host(PC or Raspberry Pi)速度必須在100K/bps以下, 連續的read/write更可能要在50K/bps(HIRC8M)
    HT66F318 Internal RC HIRC8M/HIRC12M 兩種HIRC也有差別的

I2C slave 開機後複製EEPROM data(0A 0B 0C 0D 0E 0F 0E 0D)置於I2C傳輸的緩衝當中, 準備被I2C提取(host read)
I2C slave 收到host write 8 bytes資料後暫放置於準備傳輸的緩衝當中, 準備被I2C提取(host read)
請注意I2C slave傳送前有哪些資料在緩衝區 一次性長度(Read or Write), 最長為8bytes

Relevant information

  • HT-IDE3000 V8.02 Image
  • HOLTEK C Compiler V3/Assembly Image
  • HT66F318 Config, used 8Mhz X'tal external, VDD/VDDA binding Image Image Image Image
  • HT66F318 28ssop Schematic Diagram Image Image

How to test or used

Using PC or Raspberry Pi or Arduino Host software control I2C of MCU (Slave address 0x33)

  • For Example 5digit (20000count)AD converter ICL7135

I2C Formate: @33 AA BB CC DD EE

  • For Example 16bits x 4digit LED matrix

I2C Formate: @33 D1 D2 D3 D4 D5 6D D7 D8

i2ctoeepromofht66f318's People

Contributors

louisopen avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.