Skip to content

Commit 823dad9

Browse files
authored
Merge readme from branch dev (#14)
* fix error connect server wdt reset * fix code error * add docs directory * rename diagram image * Update README.md * Update README.th.md
1 parent fe72d9d commit 823dad9

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,17 @@ microgear.init("sXfqDcXHzbFXiLk", "DNonzg2ivwS8ceksykGntrfQjxbL98", "myplant");
160160

161161
---
162162

163+
**void MicroGear:: setEEPROMOffset(int offset)**
164+
165+
Shift the offset of an EEPROM address where a microgear token is stored. This command will be useful if your application wants to store some other data in an EEPROM as well. The default offset value is 0.
166+
167+
![EEPROM-token](docs/images/EEPROM-token-diagram.png)
168+
169+
**arguments**
170+
* *offset* - The EEPROM address offset vale. The default is 0.
171+
172+
---
173+
163174
**void MicroGear::on(unsigned char event, void (* callback)(char*, uint8_t*,unsigned int))**
164175

165176
Add a callback listener to the event.

README.th.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,17 @@ microgear.init("sXfqDcXHzbFXiLk", "DNonzg2ivwS8ceksykGntrfQjxbL98", "myplant");
153153

154154
---
155155

156+
**void MicroGear:: setEEPROMOffset(int *offset*)**
157+
158+
ตั้งค่าตำแหน่งแรกของ EEPROM ที่จะให้ microgear เก็บบันทึก token คำสั่งนี้จะมีประโยชน์ในกรณีที่ผู้ใช้ ต้องการใช้ EEPROM ในการเก็บบันทึกข้อมูลอย่างขึ้นด้วย ข้อมูลจะได้ไม่บันทึกทับซ้อนกัน โดยปกติหากไม่ได้เรียกคำสั่งนี้ microgear library จะใช้ EEPROM เริ่มต้นที่ตำแหน่งที่ 0 ในการเก็บ token
159+
160+
![EEPROM-token](docs/images/EEPROM-token-diagram.png)
161+
162+
**arguments**
163+
* *offset* - ค่า offset ของตำแหน่ง EEPROM ที่ microgaer ใช้บันทึกข้อมูล ค่า default เป็น 0
164+
165+
---
166+
156167
**void MicroGear::on(unsigned char event, void (* callback)(char*, uint8_t*,unsigned int))**
157168

158169
เพิ่มฟังก์ชั่นที่ตอบสนองต่อ event
13 KB
Loading

0 commit comments

Comments
 (0)