Skip to content

Commit

Permalink
Add non-incrementing block word write to the AHB-AP.
Browse files Browse the repository at this point in the history
  • Loading branch information
hugovincent committed Jul 6, 2011
1 parent cd261db commit 609495c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions SWDCommon.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,13 @@ def writeBlock (self, adr, data):
for val in data:
self.dp.writeAP(self.apsel, 0x0C, val)

def writeBlockNonInc (self, adr, data):
self.csw(0, 2) # 32-bit non-incrementing addressing
self.dp.writeAP(self.apsel, 0x04, adr)
for val in data:
self.dp.writeAP(self.apsel, 0x0C, val)
self.csw(1, 2) # 32-bit auto-incrementing addressing

def writeHalfs (self, adr, data):
self.csw(2, 1) # 16-bit packed-incrementing addressing
self.dp.writeAP(self.apsel, 0x04, adr)
Expand Down

0 comments on commit 609495c

Please sign in to comment.