little_flash - LITTLE FLASH Software package#

Adapted Air780EP Air201

Note

This page document is automatically generated by this file. If there is any error, please submit issue or help modify pr, thank you!

Tip

This library has its own demo,click this link to view little_flash demo examples

lf.init(spi_device)#

Initialization little_flash

Parameters

Incoming Value Type

Explanation

int

userdata spi_device

Return Value

return value type

explanation

userdata

Returns a data structure on success, otherwise nil

Examples

--spi_device
spi_device = spi.deviceSetup(0,17,0,0,8,2000000,spi.MSB,1,0)
log.info("lf.init",lf.init(spi_device))

lf.mount(flash, mount_point, offset, maxsize)#

mount little_flash lfs file system

Parameters

Incoming Value Type

Explanation

userdata

flash Flash The data structure returned by the device object lf.init()

string

mount_point Mount directory name

int

starting offset, default 0

int

Total size, the default is the entire flash

Return Value

return value type

explanation

bool

Successful return true

Examples

log.info("lf.mount",lf.mount(little_flash_device,"/little_flash"))