![]() |
|
Tài trợ cho PIC Vietnam |
dsPIC - Bộ điều khiển tín hiệu số 16-bit Theo dự kiến của Microchip, vào khoảng năm 2011 dsPIC sẽ có doanh số lớn hơn PIC |
|
Ðiều Chỉnh | Xếp Bài |
![]() |
#1 |
Nhập môn đệ tử
Tham gia ngày: Aug 2007
Bài gửi: 6
: |
Hỏi về đọc ghi vào EEPROM của dsPIC30F
trong file dataEEPROM.h có nội dung
Code:
/* * ReadEErow prototype: * Parameters Definition: * Page: is the 8 most significant bits of the source address in EEPROM * Offset: is 16 least significant bits of the source address in EEPROM * DataOut: is the 16-bit address of the destination RAM location or array * Size: is the number of words to read from EEPROM and is a value of 1 or 16 * Return Value: * Function returns ERROREE (or -1) if Size is invalid */ extern int ReadEE(int Page, int Offset, int* DataOut, int Size); /* * EraseEErow prototype: * Parameters Definition: * Page: is the 8 most significant bits of the address in EEPROM to be erased * Offset: is 16 least significant bits of the address in EEPROM to be erased * Size: is the number of words to read from EEPROM and is a value of 1, 16 or * 0xFFFF (for erasing ALL EEPROM memory) * Return Value: * Function returns ERROREE (or -1) if Size is invalid */ extern int EraseEE(int Page, int Offset, int Size); /* * WriteEErow prototype: * Parameters Definition: * Page: is the 8 most significant bits of the destination address in EEPROM * Offset: is 16 least significant bits of the destination address in EEPROM * DataIn: is the 16-bit address of the source RAM location or array * Size: is the number of words to read from EEPROM and is a value of 1 or 16 * Return Value: * Function returns ERROREE (or -1) if Size is invalid */ extern int WriteEE(int* DataIn, int Page, int Offset, int Size); Nhờ mọi người giúp đỡ ! |
![]() |
![]() |
|
|