最近在调试JTAG,通过对ATOM的GPIO 操作,把ATOM的GPIO口模拟成JTAG信号,然后把CPLD的firmware,从ATOM平台烧进CPLD中。
这里主要是使用了Altera的 STAPL工具, 叫jamplayer, 这是一个开源的工具,再source下,直接make就能生成jamplayer工具。
还需要在quartusII中把xxx.pof 格式的CPLD firmware转换成xxx.jam格式。jam文件才能被jamplayer操作。
主要的使用命令如下:
jamplayer [option] file
jamplayer -acheck_idcode xxx.jam //check the CPLD id and jam file id, if the same tell the id number and return success
jamplayer -averify xxx.jam //compare the cpld contents and the file contents, if the same, return success.
jamplayer -aprogram xxx.jam // flash the firmware, it will erase first, then program, then verify.
jamplayer -aerase xxx.jam //it will erase CPLD firmware
jamplayer -ablankcheck xxx.jam //check if it's blank.return succeed if it's blank.
option 还可以有