2020-08-12 12:58 AM
I have few doubts as follows:
1. Each MEMORY MAPPED ADDRESS is how many bytes wide? 1 or 4 bytes (I think it as 1 byte).
2. The ST datasheet for stm446xx says the SRAM is of 128Kb size then,start and end addresss is 0x20000000 to 0x2001FFFF but, bit band alias region starts from 0X22000000 upto 0x23FFFFFF then, the bit band start address is exceeding the end address of available SRAM. Can anyone please explain this i.e how do we use bit band region then ?
2020-08-12 01:05 AM
JW
2020-08-12 02:14 AM
Thanks JW,
(for example: lets consider FLASH mem region which is of 512Mb) start address: 0X00000000 end region: 1FFFFFFFX (536870911d)
TOTAL locations(address) = 536870912. And SIZE of these locations = 512Mb = 536870912bytes. Hence Size per location is: 536870912/536870912 = 1byte.
Which means ,
address location :0x00000000 =1byte,
location 0x00000001 =1 byte,..so on
Where am I wrong in this calculation?
2.Meaning if there is no physical SRAM for alias region how can we do bit-banding?. Can you please elaborate more.
2020-08-12 03:15 AM
Thanks JW,
(for example: lets consider FLASH mem region which is of 512Mb) start address: 0X00000000 end region: 1FFFFFFFX (536870911d)
TOTAL locations(address) = 536870912. And SIZE of these locations = 512Mb = 536870912bytes. Hence Size per location is: 536870912/536870912 = 1byte.
Which means ,
address location :0x00000000 =1byte,
location 0x00000001 =1 byte,..so on
Where am I wrong in this calculation?
2.Meaning if there is no physical SRAM for alias region how can we do bit-banding?. Can you please elaborate more.
2020-08-12 03:36 AM
Each 32-bit word in the 0x22000000 address space translates to a bit in the 0x20000000 space.
ie 0x22000004 accesses the second bit at 0x20000000
2020-08-12 06:08 AM
The reference manual gives a nice example of how to use the bit banding region:
FLASH is not bit banded. Only SRAM1 and SRAM2.