TAILIEUCHUNG - HandBooks Professional Java-C-Scrip-SQL part 198

Tham khảo tài liệu 'handbooks professional java-c-scrip-sql part 198', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | flashBase UNLOCK2_OFFSET FLASH_CMD_UNLOCK2 flashBase COMMAND_OFFSET FLASH_CMD_BYTE_PROGRAM Perform the actual write operation. baseAddress offset data offset Wait for the operation to complete or time-out. while baseAddress offset DQ7 data offset DQ7 baseAddress offset DQ5 if baseAddress offset DQ7 data offset DQ7 break return offset flashWrite Function flashErase Description Erase a block of the Flash memory device. Notes This function is specific to the AMD 29F010 Flash memory. In this device individual sectors may be hardware protected. If this algorithm encounters a protected sector the erase operation will fail without notice. Returns O on success. Otherwise -1 indicates failure. int flashErase unsigned char sectorAddress unsigned char flashBase FLASH_BASE Issue the command sequence for sector erase. flashBase UNLOCK1_OFFSET FLASH_CMD_UNLOCK1 flashBase UNLOCK2_OFFSET FLASH_CMD_UNLOCK2 flashBase cOMMAND_OFFSET FLASH_CMD_ERASE_SETUP flashBase uNLOCK1_OFFSET FLASH_CMD_UNLOCK1 flashBase UNLOCK2_OFFSET FLASH_CMD_UNLOCK2 sectorAddress FLASH_CMD_SECTOR_ERASE Wait for the operation to complete or time-out. while sectorAddress DQ7 sectorAddress DQ5 if sectorAddress DQ7 return -1 return 0 flashErase Of course this is just one possible way to interface to a Flash memory and not a particularly advanced one at that. In particular this implementation does not handle any of the chip s possible errors. What if the erase operation never completes The function flashErase will just keep spinning its wheels waiting for that to occur. A more robust implementation would use a software time-out as a backup. For example if the Flash device doesn t respond within twice the maximum expected time as stated in the databook the routine could stop polling and indicate the error to the caller or user in some way. Another thing that people sometimes do with Flash memory is to implement a small filesystem. Because the Flash memory provides nonvolatile storage that is also rewriteable it can .

TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.