Skip to content

Ensure Nanostack is initialised before using it #192

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

Merged
merged 1 commit into from
Jun 8, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions mesh_nvm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
*/

#include "mbed.h"
#include "Nanostack.h"

/* Application configuration values from json */
#define MESH_LOWPAN 1
Expand Down Expand Up @@ -68,7 +69,9 @@ void mesh_nvm_initialize()
}

if (!mount_status) {
Nanostack::get_instance(); // ensure Nanostack is initialised
ns_file_system_set_root_path("/fs/");
// Should be like: Nanostack::get_instance().file_system_set_root_path("/fs/");
Copy link
Contributor

@SeppoTakalo SeppoTakalo Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand what you are trying to say with this comment?
Proposal for a new API?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You got it right, that kind of API should be added later on.

}
}

Expand Down