Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VMD file parse eror,Count = 0! #8

Open
imliubo opened this issue Mar 21, 2020 · 2 comments
Open

VMD file parse eror,Count = 0! #8

imliubo opened this issue Mar 21, 2020 · 2 comments

Comments

@imliubo
Copy link

imliubo commented Mar 21, 2020

Hi,
I'm trying this very amazing project, but I seem to have encountered a problem.
I use A-EYE hardware,I have modified the pins of the LCD and SD card for A-EYE board.Model file it seem can be parse right,but the motion file can not be parse right(count always is 0),did I miss something?
I use PC it can be works well!
Log:

Core 0 Hello world                                   
core 1 registering...                                
Core 1 Hello world
sd init 0
card info status 0
CardCapacity:31914983424
CardBlockSize:512
mount sdcard:0
count:0
ik=7
@elect-gombe
Copy link
Owner

it seems loading model file is okay, but could not load a motion file.
'count:0' shows there is no key frames in that motion file.

https://github.com/elect-gombe/k210_mmd/blob/master/vmd.cpp

Make sure your motion file is enough small to fit within RAM of k210.
I tested motion file of 'wavefile'. you can download from here: https://bowlroll.net/file/5983

@imliubo
Copy link
Author

imliubo commented Mar 23, 2020

Hi @elect-gombe ,
Thanks for help me,I try this motion file again,the problem still exists.
It was fail in this line:

    filread(&f,&motioncount,sizeof(uint32_t));
    motionlist = (motion_t*)malloc(sizeof(motion_t)*motioncount);
    if(motionlist == NULL){
     fail();
    }

Looks like memory allocation failed or file read error.
Tonight, I will push the code to this repository(after 10 PM),If time is convenient, please take look~

Have a nice day!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants