aboutsummaryrefslogtreecommitdiffstats
path: root/4a-hal
AgeCommit message (Collapse)AuthorFilesLines
2018-10-08Handle if some hal info are not availableJonathan Aillet1-5/+6
Handle the case if some hal info are not available when the data of all registered hal are requested. Change-Id: Ia55fcc9ff6e964fe23965cf92bb06533c3d11695 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Use a structure to store ctl hal specific dataJonathan Aillet3-8/+61
To avoid multiple variables at NULL in specific hal data, use a structure to store all controller hal specific data. These data won't be use if the hal is external (registered). Example of controller hal specific data : - Mixer api name - Mixer initialization json - Mixer streams names and card id ... Change-Id: Ifc4823d5ea21ed408b4ecc25b870cad74d3b2173 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Use json_object* instead of struct json_object*Jonathan Aillet2-3/+3
In code, use json_object* instead of struct json_object*. Change-Id: I9b37f30807331b6f85dc7f36242d5c1206093565 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Change the way that hal data are initialized and freedJonathan Aillet1-7/+10
Initialized the whole hal data structure instead of member by member. Free all strings if the hal is external (in this case, strings are allocated by hal manager). Change-Id: Ic860bcbf1999a870f34d12640e9c68b2cbc50876 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Rename function used to load verbs into a dynamic apiJonathan Aillet4-4/+4
Rename function used to load verbs into a dynamic api from 'HalUtlLoadStaticVerbs' to 'HalUtlLoadVerbs' because it is used to load not only static verbs. Change-Id: Idc033ccf0a8e7556e0809e8fa3554d09d0e81d39 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Regroup declaration of variables in functionsJonathan Aillet1-7/+5
Regroup declaration of variables in 'HalMgrLoaded' function. Add error info when responding that the request have failed. Change-Id: Ib25159f37928bd8cc442e9db08b280e93b6b568b Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Remove some unnecessary freeJonathan Aillet1-20/+2
Remove some unnecessary free that used to free strings that are handled by controller. Remove test if NULL before free (free doesn't do anything if pointer is NULL). Change-Id: I9f9bdb3f194900567da6bd2dada6dae4ea87b1fa Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Remove the 'ping' of each hal controller apiJonathan Aillet1-2/+0
Remove the 'ping' verb of each hal controller api which won't be useful anymore. Rename action in configuration file to be able ping an api nevertheless. Change-Id: I5b1ce8f8cd83dc3e689c3bd676244477921ba20d Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Add a 'List' verb to each hal controller apiJonathan Aillet4-0/+69
Add a 'List' verb to each hal controller api which will list verbs available for this api. The callback of the verb is not implemented yet. Change-Id: Ibc44ef8673267b0b952b32fb256214452aa3c000 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Change the name of controller configuration filesJonathan Aillet1-2/+2
Change the name of controller configuration files to be sure that they will be found during 'CtlConfigScan'. Add the name that the binder should take into config.cmake to be sure that the controller configuration files will be found during 'CtlConfigScan'. Change-Id: I94c55c186c52f6f89b06400133cfbce36221d245 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Change how to request all loaded api infoJonathan Aillet1-18/+6
Instead of receiving all info about api by passing request arg : { "option" : "metadata" } api info will be obtained by passing this request arg : { "verbose" : 1 } Change-Id: I26a14d61ffefbb7f4630f4a3199ee5238008263a Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Remove sections id in sections callbacks structureJonathan Aillet1-6/+5
Remove sections id in sections callbacks structure because it's not mandatory anymore (it's even harder to add a section with these ids). Change-Id: I04caa1c83137e4165c023207d2b58376c176c248 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Change names of some structures fieldsJonathan Aillet4-30/+26
Change names of some structures fields to match the fileds name in controller structure. Change-Id: I579ec53835daa010154982539d09d5a2dcbd28b2 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Get Hal controller api structure fields properlyJonathan Aillet3-32/+7
Because of a recent change in the app-controller, change the way that metadata was get. Avoid to parse json again and use only CtlConfigT strcuture fields to fill Hal controller api structure. Add a fields info in Hal controller api structure. Change-Id: I17ff00bfd6d0991bed47831a92bf81ddcf3fb4c9 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Pre-version of 4a-hal-managerJonathan Aillet14-0/+1160
Pre-version of 4a-hal manager that uses app-fwk DynAPI and app-controller. Current version : - Declare a new API for each HAL (each .json config file is used to generate one app-controller API) at startup. - Define verbs that will be provided by this API. - Provide verb to list and get info of loaded API. Change-Id: I7bb6e8b7539b1acd5556fd9275a1b536e129332d Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
2018-10-08Add compilation configurationJonathan Aillet1-0/+53
Add compilation configuration for 4a-hal-gezneric project. Change-Id: If5bc696cbf3170923ea67cef301c71720a70fe70 Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>