From 118bc835fa19d827361bf8524a609b243c6b6778 Mon Sep 17 00:00:00 2001 From: Tobias Jahnke Date: Thu, 14 Jun 2018 12:44:46 +0200 Subject: hal-most-unicens.c: add registration for hal-mgr Change-Id: I50d389e8bd4f6f13d4f91efaac95973b0d506ad0 Signed-off-by: Tobias Jahnke --- MOST_UNICENS/hal_most_unicens.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'MOST_UNICENS') diff --git a/MOST_UNICENS/hal_most_unicens.c b/MOST_UNICENS/hal_most_unicens.c index d31082c..d9f297e 100644 --- a/MOST_UNICENS/hal_most_unicens.c +++ b/MOST_UNICENS/hal_most_unicens.c @@ -374,6 +374,22 @@ STATIC int unicens_service_init() { /* request of initial card values */ /* unicens_request_card_values(ALSA_DEVICE_ID); */ + json_object *apiObject; + wrap_json_pack(&apiObject, "{s:{s:s s:s s:s s:s s:s s:s s:i}}", + "metadata", + "api", "hal-most-unicens", + "uid", "/dev/snd/by-id/usb-Microchip-SMSC_OS81210_0000-0000000C-02", + "info", "External Hal for Unicens", + "author", "Tobias Janhke", + "version", "1.0", + "date", "2018-06-14", + "snd-dev-id", -1); + + json_object *returnedJ; + if(afb_service_call_sync("4a-hal-manager", "load", apiObject, &returnedJ)) + AFB_ERROR("An issue happen during registration to hal-manager : %s", json_object_get_string(returnedJ)); + + OnErrorExit: AFB_NOTICE("Initializing HAL-MOST-UNICENS-BINDING done.."); return err; -- cgit 1.2.3-korg