Coder Social home page Coder Social logo

Comments (8)

armink avatar armink commented on July 26, 2024

在 fdb_cfg.h 中配置即可

from flashdb.

hcb900330 avatar hcb900330 commented on July 26, 2024

#define FDB_WRITE_GRAN 1 这个确实配置错了
但是该正确以后,value字符数多了 还是存不进去 不知道这value的最大数 在哪里配置

from flashdb.

hcb900330 avatar hcb900330 commented on July 26, 2024

#define FDB_WRITE_GRAN 1 这个确实配置错了
但是该正确以后,value字符数多了 还是存不进去 不知道这value的最大数 在哪里配置

好像没有这个参数配置

from flashdb.

hcb900330 avatar hcb900330 commented on July 26, 2024

在 fdb_cfg.h 中配置即可

kv大小不好设置 我想换ts试试的 result = fdb_tsdb_init(&tsdb, "liandong", "fdb_tsdb1", get_time, 20*1024, NULL);
还是不能初始化
[FlashDB][tsl][liandong] (applications\FlashDB\src\fdb_tsdb.c:748) (max_len < db_sec_size(db)) has assert failed at fdb_tsdb_init.

from flashdb.

armink avatar armink commented on July 26, 2024

如果是设置 TSDB 的 MAX_LEN ,可以通过 fdb_tsdb_init 来设置

from flashdb.

hcb900330 avatar hcb900330 commented on July 26, 2024

如果是设置 TSDB 的 MAX_LEN ,可以通过 fdb_tsdb_init 来设置
我设置了20*1024 都设置不了的
[FlashDB][tsl][liandong] (applications\FlashDB\src\fdb_tsdb.c:748) (max_len < db_sec_size(db)) has assert failed at fdb_tsdb_init.

from flashdb.

armink avatar armink commented on July 26, 2024

那说明是你的 扇区设置的太小了,可以通过 control 来调整扇区大小 http://armink.gitee.io/flashdb/#/zh-cn/api?id=%e6%8e%a7%e5%88%b6-tsdb

from flashdb.

hcb900330 avatar hcb900330 commented on July 26, 2024

那说明是你的 扇区设置的太小了,可以通过 control 来调整扇区大小 http://armink.gitee.io/flashdb/#/zh-cn/api?id=%e6%8e%a7%e5%88%b6-tsdb

修改了下,还是没有用,最大只能设置1024

                      int len=1024*1024;  
		  int len2=1024*50; 
		  fdb_tsdb_control(&tsdb, FDB_TSDB_CTRL_SET_ROLLOVER, &len);
		  fdb_tsdb_control(&tsdb, FDB_TSDB_CTRL_SET_SEC_SIZE, &len2);
		  rt_thread_delay(100);
    result = fdb_tsdb_init(&tsdb, "liandong", "fdb_tsdb1", get_time, 40*1024, NULL);
    if (result != FDB_NO_ERR) {
        return -1;
    }

[FlashDB] You can get the latest version on https://github.com/armink/FlashDB .
[FlashDB] (applications\FlashDB\src\fdb.c:68) (db->sec_size % block_size == 0) has assert failed at _fdb_init_ex.

from flashdb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.