??? 05/31/06 21:07 Modified: 05/31/06 21:12 Read: times |
#117438 - DS89C4x0 IAP/ISP explained Responding to: ???'s previous message |
Erik Malund said:
Okay so is there a difference between IAP and ISP? I also assumed they were the same
What I understand is that ISP is something that can be done with no software effort on your side, IAP requires some. Erik More specifically, ISP (in-system programming) is a feature implemented by a hardcoded bootloader present in the '420/'430/'440/'450 ROM. The chip's documentation indicates what hardware stimuli must be present to get the device to boot into this special ROM, the existence of which is otherwise effectively invisible* to you. When the device is running in ROM bootloader mode, your own code is not running. Interaction with the ROM-based bootloader is done over the first serial port of the device, at any of a number of baudrates that it supports; the API for interaction with the loader is also documented. You may choose to simply use Dallas' own tool (MTK) to interact with the ROM loader, a 3rd party tool such as mine (which complies with this API), or write an API-compliant tool of your own design if none of the other options suit your needs. In the case of IAP, (in-application programming), your own embedded code, while running, has the ability to modify the contents of the '430/'440/'450's internal flash; this feature is not supported on the '420. IAP is done independently of the hardcoded ROM bootloader. All you do to write to the internal flash is follow the chip's documented procedure for writing the flash. What interface the code/data you write to flash comes from is up to you; any interface you have available is fine, but especially in the case of code, you must make sure that the integrity of the transmission is guaranteed. This of most significance in the presence of an unreliable link (think: radio interface without error correction). Additionally, the upstream source of the data, and how it is communicated (all the way down to physical layer), is up to you. It is also worth noting that there is a history of issues related to ISP/IAP in early revisions of these devices; for more information about that, start here. The long and short of this is that unless you have requirements calling for the support of IAP, the easiest path from an empty DS89C4x0 to one with your code on it in a prototyping environment is your lab bench parallel device programmer or ISP using a pre-existing tool. --Sasha Jevtic *effectively invisible is not to imply that undocumented hooks into this code do not exist. However, I have not seen suggestion of any such hooks in the publicly available documentation. Kevin Self might know otherwise, though. |