2024-01-16 04:36 AM
In the ULD driver for the VL53L8 is the file vl53lmz_api.c. In line 354 to 364, the firmware is loaded in pieces of 0x8000 bytes:
My microcontroller has not enough ram to handle such big blocks, so I have to load the firmware in smaller pieces. But for what are the write commands to register 0x7FFF between loading the FW blocks in line 358, 361 and 364?
What has to be adjusted to write the FW e.g. in blocks of 0x2000 bytes?
Used product: SATEL-VL53L8
Solved! Go to Solution.
2024-01-16 07:57 AM
It's a page register.
Set the page register to 0x9, write 0x8000 bytes into it.
Set the page register to 0xA, write 8000 bytes into it.
Set the page register to 0xB, write 0x5000 bytes into it.
Then set the page register back to 1 and off you go.
You can break up those writes to whatever chunksize you want.
Just set the page number, and start writing at 0, remembering to increment the address by the chunksize for each write.
ST is very STM32-centric. But we probably should have written that code with a definable chunksize. Even if we defaulted it to 0x8000.
- john
2024-01-16 07:57 AM
It's a page register.
Set the page register to 0x9, write 0x8000 bytes into it.
Set the page register to 0xA, write 8000 bytes into it.
Set the page register to 0xB, write 0x5000 bytes into it.
Then set the page register back to 1 and off you go.
You can break up those writes to whatever chunksize you want.
Just set the page number, and start writing at 0, remembering to increment the address by the chunksize for each write.
ST is very STM32-centric. But we probably should have written that code with a definable chunksize. Even if we defaulted it to 0x8000.
- john