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

Can an array parameter be passed as a JSON Arrray? #2

Open
HaxorGate opened this issue Jul 16, 2019 · 0 comments
Open

Can an array parameter be passed as a JSON Arrray? #2

HaxorGate opened this issue Jul 16, 2019 · 0 comments

Comments

@HaxorGate
Copy link

I haven't used aJSON before, as I've been using ArduinoJson. Is it possible to register a method with your library that takes a JSON array as a parameter?
For instance, if I want to call a factory method at runtime, can I have:

DECLARE_JSON_PROC(ButtonController, makeButtonVector, void);

BEGIN_JSON_REGISTRATION
REGISTER_JSON_PROC(makeButtonVector, JSON_RPC_RET_TYPE_NONE);
END_JSON_REGISTRATION

where "makeButtonVector" would normally have the following signature:

void ButtonController::makeButtonVector( uint8_t *pins, uint8_t npins );

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

1 participant