Compare commits

...

65 Commits

Author SHA1 Message Date
Jakob Olsson
2117bc1903 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 1b8501d fix enable pin, add get signal strength
* 6db2741 add set_pin, disable_pin
-------------------------------------------------------------------------------
commit 1b8501d5a24fcdf784678e8f864964fc0138254c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-04 14:04:47 +0200

    fix enable pin, add get signal strength

Base directory -> /
 dongle_network.c | 71 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 dongle_pin.c     | 58 ++++++++++++++++++++++++++++++++++++++++++++-
 libmobile.c      |  4 ++--
 libmobile.h      |  2 +-
 4 files changed, 131 insertions(+), 4 deletions(-)
-------------------------------------------------------------------------------
commit 6db274197ef6151d119335d99e85dbbbbc788978
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-04 12:54:09 +0200

    add set_pin, disable_pin

Base directory -> /
 dongle_pin.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-----
 libmobile.c  | 112 +++++++++++++++++++++++++++++++++++++++++++++---
 libmobile.h  |   4 ++
 3 files changed, 238 insertions(+), 15 deletions(-)
-------------------------------------------------------------------------------
2018-05-04 14:05:25 +02:00
Jakob Olsson
b553a6bb9f new binary to add 2018-05-04 14:05:10 +02:00
Jakob Olsson
6a2e0a259e Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 01d0e03 accomodate for splitting files, some test code for pin
* 5eb1ecb rename file and object
* f01ee70 remove remaining curls from dongle.c, remove duplicate function, TODO: naming scheme, run cppcheck, checkpatch
* 911c050 move (most) curl code to libmobile, still some remaining in dongle, write_func duplicate, TODO: consistent returns, clean memory?
* 76f11f2 add delete, set (default apn), and show current apn, some cleanup
* c39d839 add list_apn_profiles, listing the APN_config names, essentiall listing their names
* 89d9e82 dynamically find index fix
* 634b533 can send post request to add new APN profile, TODO: add dynamic idx, set_default(), apply()
* 85beb1d add preliminary functionality & ubus method for setting APN
* 2a6dd7c Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into HEAD
* 28356f4 add referer to dongle
-------------------------------------------------------------------------------
commit 01d0e038fd26a2fc5a483ad4bf2c7f7accd5820c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-04 09:14:16 +0200

    accomodate for splitting files, some test code for pin

Base directory -> /
 Makefile     | 16 ++++++-----
 dongle_apn.c | 48 +--------------------------------
 dongle_pin.c | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 libmobile.c  | 74 +++++++++++++++++++++++++++++++--------------------
 4 files changed, 143 insertions(+), 82 deletions(-)
-------------------------------------------------------------------------------
commit 5eb1ecbb3fd267917df4ed5b387f840d59db8ba1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 16:52:24 +0200

    rename file and object

Base directory -> /
 dongle.c     | 255 -----------------------------------------------------------
 dongle_apn.c | 255 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 255 insertions(+), 255 deletions(-)
-------------------------------------------------------------------------------
commit f01ee707753f66ed918f9603d4e9f98975ba882b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 16:48:31 +0200

    remove remaining curls from dongle.c, remove duplicate function, TODO:
    naming scheme, run cppcheck, checkpatch

Base directory -> /
 dongle.c    | 53 +++++------------------------------------------------
 libmobile.c | 35 +++++++++++++++++++++++++++++++++++
 libmobile.h |  3 ++-
 3 files changed, 42 insertions(+), 49 deletions(-)
-------------------------------------------------------------------------------
commit 911c05069f03c08dd45692333318134c4a00cc9e
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 16:35:20 +0200

    move (most) curl code to libmobile, still some remaining in dongle,
    write_func duplicate, TODO: consistent returns, clean memory?

Base directory -> /
 Makefile    |  12 ++-
 dongle.c    | 224 +++++---------------------------------------------------
 libmobile.c | 238 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 libmobile.h |  17 +++++
 4 files changed, 282 insertions(+), 209 deletions(-)
-------------------------------------------------------------------------------
commit 76f11f2f6fd746d36b0a5f8def09153e0ddb77c1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 14:54:01 +0200

    add delete, set (default apn), and show current apn, some cleanup

Base directory -> /
 dongle.c | 227 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------
 1 file changed, 205 insertions(+), 22 deletions(-)
-------------------------------------------------------------------------------
commit c39d83953dba361d676e247002b7f63e5c4851bf
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 12:22:06 +0200

    add list_apn_profiles, listing the APN_config names, essentiall listing
    their names

Base directory -> /
 dongle.c | 77 ++++++++++++++++++++++++++++++++++++++++++++++++++--------------
 1 file changed, 61 insertions(+), 16 deletions(-)
-------------------------------------------------------------------------------
commit 89d9e82bf0d68adbd110774f989a557a500eabee
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 11:20:02 +0200

    dynamically find index fix

Base directory -> /
 dongle.c | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++-------------
 1 file changed, 65 insertions(+), 16 deletions(-)
-------------------------------------------------------------------------------
commit 634b5338b59cf65e22d645996d785ce9260862c0
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-03 09:25:33 +0200

    can send post request to add new APN profile, TODO: add dynamic idx,
    set_default(), apply()

Base directory -> /
 dongle.c | 74 +++++++++++++++++++++++++++++-----------------------------------
 1 file changed, 34 insertions(+), 40 deletions(-)
-------------------------------------------------------------------------------
commit 85beb1d0cccc607802d46af01ab3bae2f695f18f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-02 16:10:13 +0200

    add preliminary functionality & ubus method for setting APN

Base directory -> /
 dongle.c | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
 1 file changed, 68 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 2a6dd7c10342831238ad9b123824be10a8714601
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-02 12:12:19 +0200

    Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into HEAD

Base directory -> /
 dongle.c | 1 +
 1 file changed, 1 insertion(+)
-------------------------------------------------------------------------------
commit 28356f4b967693740071e99af1592429073dfb8a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-05-02 12:11:54 +0200

    add referer to dongle

Base directory -> /
 dongle.c | 1 +
 1 file changed, 1 insertion(+)
-------------------------------------------------------------------------------
2018-05-04 09:17:53 +02:00
Jakob Olsson
9d1540df1d accomodate for splitting dongle file into several 2018-05-04 09:12:04 +02:00
Jakob Olsson
547a955cfe Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 33af504 change from verbose to loglevel, from -v to -l
-------------------------------------------------------------------------------
commit 33af50474ee9f9ef9b7fdf80f43de31f69bd6014
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-30 12:52:12 +0200

    change from verbose to loglevel, from -v to -l

Base directory -> /
 parse_args.c | 8 ++++----
 parser.c     | 2 +-
 watcher.c    | 4 ++--
 3 files changed, 7 insertions(+), 7 deletions(-)
-------------------------------------------------------------------------------
2018-04-30 12:52:54 +02:00
Jakob Olsson
4f9594a6d1 change verbose to loglevel for all files 2018-04-30 12:32:31 +02:00
Jakob Olsson
86487e8c23 add object from bash script, status and set_configurations available 2018-04-30 12:26:27 +02:00
Jakob Olsson
0caad1b5c7 publishes and prints status 2018-04-30 11:50:54 +02:00
Jakob Olsson
101224dd31 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 7424f4a fix restart and update configurations from publishing event, other minor fixes
* 8d9286f typo
* b774f37 fix some compile errors
* 3ff8fa6 some name scheme changes, send new flags by event
* 77a2cb7 fix receiving events - listener required to be global or static
* d7e3c62 parser crash crash when receive event
* 825e628 add listener for events
* 6674802 consistent header and c declarations
* b322927 add send event method
* d9266c7 documentation addition, style change
*   3be1f4f fix merge conflicts
|\
| * 88e8a18 fix regarding error handling
| * 229f367 change if-case in check_for_change to prevent multiple printouts on restart, minor style and error handling fixes
| * 15ecc8d changes according to cppcheck, add some error handling in watcher
| * b3d0151 fix to compile - plenty warnings and not tested with cppcheck
| * 3c19c3c small style changes and makefile fix
| * 260bc4a error handling and general style changes -untested!
| * 7242c3c initial changes, test if limits.h is correct
* | 18366b5 add documentation
|/
* f12fdbb minor fixes
* 6aa5b34 some stylistic changes - untested
* caf59c5 print dongle response on ubus, minor style fixes
* 287a85a add struct to keep track of len instead, as in libcurl example
* a2fe80d unfinished, print garbage + response
-------------------------------------------------------------------------------
commit 7424f4adcaac30925ca7f36f78e90136af8be8fa
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-27 13:20:36 +0200

    fix restart and update configurations from publishing event, other minor
    fixes

Base directory -> /
 parser.c  | 10 ++++++----
 watcher.c | 43 +++++++++++++++++++++++--------------------
 watcher.h |  1 +
 3 files changed, 30 insertions(+), 24 deletions(-)
-------------------------------------------------------------------------------
commit 8d9286ff4bb421a21dbe5d945b5f1867068343e4
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-27 09:11:26 +0200

    typo

Base directory -> /
 watcher.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit b774f37a70134158290bbcc389166d6b884dafef
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-27 09:03:57 +0200

    fix some compile errors

Base directory -> /
 watcher.c | 34 ++++++++++------------------------
 1 file changed, 10 insertions(+), 24 deletions(-)
-------------------------------------------------------------------------------
commit 3ff8fa611ce6541cbefa0d72b86bd403a941aa61
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-27 08:52:20 +0200

    some name scheme changes, send new flags by event

Base directory -> /
 parser.c  | 30 +++++++++++++-----------------
 watcher.c | 61 ++++++++++++++++++++++++++++++++++++++++---------------------
 2 files changed, 53 insertions(+), 38 deletions(-)
-------------------------------------------------------------------------------
commit 77a2cb7762a2140a55437377ed9ae779049394f1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 15:56:38 +0200

    fix receiving events - listener required to be global or static

Base directory -> /
 parser.c  | 47 +++++++++++++++++++++++------------------------
 watcher.c |  8 ++++----
 2 files changed, 27 insertions(+), 28 deletions(-)
-------------------------------------------------------------------------------
commit d7e3c6221fb648d6ff4966d8fed078bbb6421b91
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 11:25:34 +0200

    parser crash crash when receive event

Base directory -> /
 parser.c | 28 +++++++++++++++++++++++-----
 1 file changed, 23 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit 825e6288af7757dda7cb1a229e36b95281fb6f2e
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 10:57:28 +0200

    add listener for events

Base directory -> /
 parser.c | 33 +++++++++++++++++++++++++++++++--
 1 file changed, 31 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 6674802533ebd5e86692acde93295d24d648198d
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 10:24:25 +0200

    consistent header and c declarations

Base directory -> /
 watcher.c |  5 +++--
 watcher.h | 14 +++++++++-----
 2 files changed, 12 insertions(+), 7 deletions(-)
-------------------------------------------------------------------------------
commit b322927957e294867eaf16296d5d1253e6e6efe6
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 10:17:03 +0200

    add send event method

Base directory -> /
 dongle.c  |  4 ++--
 watcher.c | 21 ++++++++++++++++++---
 2 files changed, 20 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit d9266c7f4c2af00073cfa35d0dd4552961ff767c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 09:26:08 +0200

    documentation addition, style change

Base directory -> /
 .gitignore |  4 ++++
 parser.c   | 18 +++++++--------
 parser.h   |  2 +-
 watcher.c  | 52 ++++++++++++++++++++++++++---------------
 watcher.h  | 78 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
 5 files changed, 123 insertions(+), 31 deletions(-)
-------------------------------------------------------------------------------
commit 3be1f4f09875baaa665389dc34c002303fdf46ba
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 08:45:52 +0200

    fix merge conflicts

Base directory -> /
 Makefile     |   6 ++
 common.h     |   6 ++
 dongle.c     |   6 +-
 parse_args.c |  10 +--
 parser.c     | 256 +++++++++++++++++++++++++++++++++++++++++------------------
 parser.h     |  28 +++++--
 watcher.c    | 215 ++++++++++++++++++++++++++++++++-----------------
 watcher.h    |  22 ++++-
 8 files changed, 384 insertions(+), 165 deletions(-)
-------------------------------------------------------------------------------
commit 18366b5fa66e6c9126d583b88a9794a3cbc2fa4c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-26 08:39:43 +0200

    add documentation

Base directory -> /
 parse_args.h |  7 +++++++
 parser.h     | 33 ++++++++++++++++++++++-----------
 watcher.c    | 26 ++++++--------------------
 watcher.h    | 10 ++++++++--
 4 files changed, 43 insertions(+), 33 deletions(-)
-------------------------------------------------------------------------------
commit 88e8a18867c9dd1ff389a8e0b94e5bae93abd8b1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-25 11:43:33 +0200

    fix regarding error handling

Base directory -> /
 parser.c  | 78 ++++++++++++++++++++++++++++++++++++++++++++++--------------
 parser.h  |  3 ++-
 watcher.c | 81 ++++++++++++++++++++++++++++++++++++++++++++++-----------------
 watcher.h |  4 ++--
 4 files changed, 123 insertions(+), 43 deletions(-)
-------------------------------------------------------------------------------
commit 229f36701dea502fab841166c18b5a04168f47de
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-25 10:35:05 +0200

    change if-case in check_for_change to prevent multiple printouts on restart,
    minor style and error handling fixes

Base directory -> /
 parser.c  | 18 ++++++++----------
 watcher.c | 26 ++++++++++++++------------
 2 files changed, 22 insertions(+), 22 deletions(-)
-------------------------------------------------------------------------------
commit 15ecc8d0f703b8facf4221bf21693c1387589a50
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-25 09:20:57 +0200

    changes according to cppcheck, add some error handling in watcher

Base directory -> /
 parser.c  |  15 ++-----
 watcher.c | 141 +++++++++++++++++++++++++++++++++++++++-----------------------
 watcher.h |   2 +-
 3 files changed, 94 insertions(+), 64 deletions(-)
-------------------------------------------------------------------------------
commit b3d015126ae1d817c283ab4be0fe5cc89b778526
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 16:53:59 +0200

    fix to compile - plenty warnings and not tested with cppcheck

Base directory -> /
 parser.c | 8 ++++----
 parser.h | 3 ++-
 2 files changed, 6 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit 3c19c3c30148fa995c84fb6fbdee0aa903035461
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 16:43:35 +0200

    small style changes and makefile fix

Base directory -> /
 Makefile     |  4 ++--
 dongle.c     |  6 +++---
 parse_args.c | 10 ++++------
 parser.c     |  9 ++++-----
 4 files changed, 13 insertions(+), 16 deletions(-)
-------------------------------------------------------------------------------
commit 260bc4a5bc5e22e29b0352187c8a5682a8c4ad4b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 16:35:20 +0200

    error handling and general style changes -untested!

Base directory -> /
 common.h  |   6 ++
 parser.c  | 197 ++++++++++++++++++++++++++++++++++++++++++++------------------
 parser.h  |   2 +
 watcher.h |   1 +
 4 files changed, 151 insertions(+), 55 deletions(-)
-------------------------------------------------------------------------------
commit 7242c3c2b8537f09ae8e87a17e2690c8f24fe13a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 14:09:42 +0200

    initial changes, test if limits.h is correct

Base directory -> /
 Makefile  |  6 ++++++
 parser.c  | 21 +--------------------
 parser.h  | 16 +++++++++++++++-
 watcher.c | 20 --------------------
 watcher.h | 19 +++++++++++++++++++
 5 files changed, 41 insertions(+), 41 deletions(-)
-------------------------------------------------------------------------------
commit f12fdbb07029cbfa69f7b8976474f88046fb4e2a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 12:09:29 +0200

    minor fixes

Base directory -> /
 parser.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit 6aa5b3402ad216f4428f171c390a52d5ed0e8b61
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 12:04:39 +0200

    some stylistic changes - untested

Base directory -> /
 dongle.c |  6 +-----
 parser.c | 53 ++++++++++++++++++++++++++++-------------------------
 2 files changed, 29 insertions(+), 30 deletions(-)
-------------------------------------------------------------------------------
commit caf59c521938b8bcc083379015e98b5e0d217f8d
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 11:24:17 +0200

    print dongle response on ubus, minor style fixes

Base directory -> /
 Makefile  |   2 +-
 dongle.c  | 102 +++++++++++++++++++++++++++++++++++++++++++++-----------------
 parser.c  |   1 -
 watcher.c |   3 +-
 4 files changed, 77 insertions(+), 31 deletions(-)
-------------------------------------------------------------------------------
commit 287a85a5c2f3762f510e5ce83c658e3ac2c64e61
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-24 10:26:18 +0200

    add struct to keep track of len instead, as in libcurl example

Base directory -> /
 .gitignore |  1 +
 dongle.c   | 39 ++++++++++++++++++++++++++-------------
 2 files changed, 27 insertions(+), 13 deletions(-)
-------------------------------------------------------------------------------
commit a2fe80d5ad7a85ad3301fbce08bce1e003d2a0d1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 16:52:01 +0200

    unfinished, print garbage + response

Base directory -> /
 dongle.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
2018-04-30 10:29:23 +02:00
Jakob Olsson
7382667fc1 attempt to publish ubus object through script 2018-04-30 10:21:06 +02:00
Jakob Olsson
24e497b471 add dongle binary to makefile 2018-04-26 11:28:02 +02:00
Jakob Olsson
7c2ba26b8c Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 4567e2f minor bug fix
* d00214e some dongle test with curl
* 354a426 small improvement to parsing loglevel flag
* cb71185 consistency change for flags
-------------------------------------------------------------------------------
commit 4567e2f38f3f85222bd44c4810bb9bade824dbca
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 15:43:28 +0200

    minor bug fix

Base directory -> /
 dongle.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit d00214e63a827d0731c4b73a402fd7dcc12bf20b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 15:24:12 +0200

    some dongle test with curl

Base directory -> /
 Makefile | 11 ++++++---
 dongle.c | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 89 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit 354a42605ede034f54243212a455f00d1f8ebbb6
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 13:39:46 +0200

    small improvement to parsing loglevel flag

Base directory -> /
 parse_args.c | 9 +++++----
 watcher.c    | 6 +++++-
 2 files changed, 10 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit cb7118580c39418c23a2248e790d359806c32235
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 09:55:19 +0200

    consistency change for flags

Base directory -> /
 .gitignore |  3 +--
 parser.c   | 35 ++++++++++++++++++++---------------
 watcher.c  | 34 ++++++++++++++++++++--------------
 3 files changed, 41 insertions(+), 31 deletions(-)
-------------------------------------------------------------------------------
2018-04-23 15:44:43 +02:00
Jakob Olsson
ccbf01013b test for some dongle 2018-04-23 15:44:23 +02:00
Jakob Olsson
2b4cef1cb4 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 9b7f1d4 clean some printouts
* 3e3d127 change some loglevel printouts
-------------------------------------------------------------------------------
commit 9b7f1d4e7ceefc205e799cc6fa8d231363c6f48d
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 09:31:22 +0200

    clean some printouts

Base directory -> /
 parser.c  |  5 ++---
 watcher.c | 39 ++++++++++++---------------------------
 2 files changed, 14 insertions(+), 30 deletions(-)
-------------------------------------------------------------------------------
commit 3e3d12778eb03315ca6a2554271df9a6cbffbbaf
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 09:24:06 +0200

    change some loglevel printouts

Base directory -> /
 parser.c | 21 ++++++---------------
 1 file changed, 6 insertions(+), 15 deletions(-)
-------------------------------------------------------------------------------
2018-04-23 09:39:44 +02:00
Jakob Olsson
0674212035 start with loglevel 0 2018-04-23 09:39:01 +02:00
Jakob Olsson
da55d5ef09 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 27bb443 move bash-scripts to test folder, remove capital files pathes
* 71c8008 move uloop_timeout struct outside restart application, now restarts with correct flags, add files to gitignore
* 58ee177 try to restart parser with execv, unsccessful adding to uloop, crashesh with uloop, does not without
* d242006 kill and replace process with new start flags
-------------------------------------------------------------------------------
commit 27bb443eb1380e142b827c9a413adcddd0e964e5
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 08:57:29 +0200

    move bash-scripts to test folder, remove capital files pathes

Base directory -> /
 bash-tests/multiple-addremove.sh | 10 ++++++++++
 bash-tests/nested-array.sh       | 21 +++++++++++++++++++++
 bash-tests/nested-objects.sh     | 19 +++++++++++++++++++
 bash-tests/ssid.sh               | 13 +++++++++++++
 common.h                         |  4 ++--
 multiple-addremove.sh            | 10 ----------
 nested-array.sh                  | 21 ---------------------
 nested-objects.sh                | 19 -------------------
 parse_args.c                     |  4 ++--
 ssid.sh                          | 13 -------------
 10 files changed, 67 insertions(+), 67 deletions(-)
-------------------------------------------------------------------------------
commit 71c80083e3ee35d8ea71fd12e923783a75300f22
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-23 08:33:42 +0200

    move uloop_timeout struct outside restart application, now restarts with
    correct flags, add files to gitignore

Base directory -> /
 .gitignore | 12 +++++++++++-
 parser.c   | 30 ++++++++----------------------
 2 files changed, 19 insertions(+), 23 deletions(-)
-------------------------------------------------------------------------------
commit 58ee1775d3ec4d5c5979687a1262a227d828b83e
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-20 16:01:36 +0200

    try to restart parser with execv, unsccessful adding to uloop, crashesh with
    uloop, does not without

Base directory -> /
 parser.c  | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-----
 watcher.c | 41 ++++++++++++++++++++++++-------------
 2 files changed, 92 insertions(+), 19 deletions(-)
-------------------------------------------------------------------------------
commit d2420069fdda2d38b47ab1d7e06143ad5e05e52f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-20 11:34:51 +0200

    kill and replace process with new start flags

Base directory -> /
 parser.c  |  5 ++--
 watcher.c | 98 ++++++++++++++++++++++++---------------------------------------
 2 files changed, 39 insertions(+), 64 deletions(-)
-------------------------------------------------------------------------------
2018-04-23 09:11:57 +02:00
Jakob Olsson
fc2d33ec4d remove capitalization 2018-04-23 09:01:49 +02:00
Jakob Olsson
99ac1c3c41 manual hash change 2018-04-19 14:04:56 +02:00
Jakob Olsson
79e09f6627 manual change of hash 2018-04-19 12:05:58 +02:00
Jakob Olsson
fb29645dbe add mosquitto package and adjust Makefile in onboardingd to accomodate 2018-04-19 10:51:40 +02:00
Jakob Olsson
35dee9de2e Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 258865c attempting execv solution that keeps pid
* aba0a7f some style change, documentation and name scheme changes
* f77798f swap functionality of set_configurations from parser to watcher and all corresponding changes
* 66b18db add timeout prior to lookup, small error fixes
* d5ad23f add restart from wtihin application functionality for watcher, some more small error fixes
* dc9a03e correct error printouts for invoking ubus from watcher, also provide preliminary restart functions in order to change paths and loglevel from within applications
* f914252 set buf mem to 0 prior to initializing, invoking ubus calls from separate binary works, however will not invoke after restart
* 9ac0215 add uloop and ubus object to watcher, currently incomplete
* e413469 small fix to make ubus IPC work through invoking ubus call
* b9135c8 attempt at invoking ubus method from outside binary that registers it
* a3001e0 update according to checkpatch errors and added some documentation
* c48bd84 added ubus IPC by system() from watcher
* 4ec1230 correction to parser header for declaration of check_pipe (should rename)
* 8bef035 does not compile -- fix header at monday
* 3227782 small fixes
* 07218dc prepare for ubus ipc, untested
* b02592a can change both arguments from single call to set_configuration with both arguments
* 0b2f4ec cleaned up and can now use same method to change configuration file and loglevel
* 6666a31 change config through UCI c API
* 877a72d add support for path through uci, loglevel timing out
* 3ff7676 delete binary
* dc74ccc forgot to add parser.c, test
* ee27697 add functionality to change configuration file through UCI api
* 4968afd some minor errors
* 24921f6 test stackoverflow code to see uci functionality
* 0cc6235 add return to prevent request timeout
* 5618a04 restart from init.d and add paranthesis
* 1e699fe fixed small errors
-------------------------------------------------------------------------------
commit 258865c880870d87fc90917140ab883e73d9c38a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-18 11:00:06 +0200

    attempting execv solution that keeps pid

Base directory -> /
 parse_args.c | 12 ++++++-----
 watcher.c    | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++++-----
 2 files changed, 70 insertions(+), 10 deletions(-)
-------------------------------------------------------------------------------
commit aba0a7f0ebf8663f9181c274fde4744e7673bff2
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-18 09:04:39 +0200

    some style change, documentation and name scheme changes

Base directory -> /
 Makefile     | 16 +++++-----
 debug.c      | 50 -------------------------------
 debug.h      |  8 -----
 parse_args.c | 50 +++++++++++++++++++++++++++++++
 parse_args.h |  8 +++++
 parser.c     | 55 +++++++++++++++++-----------------
 parser.h     | 43 ++++++++++++++++++++++++++-
 watcher.c    | 97 ++++++++++++++++--------------------------------------------
 8 files changed, 160 insertions(+), 167 deletions(-)
-------------------------------------------------------------------------------
commit f77798fdb527019b251044c63e01c685e64e4369
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-17 16:54:55 +0200

    swap functionality of set_configurations from parser to watcher and all
    corresponding changes

Base directory -> /
 parser.c  | 234 +++++++++++++-------------------------------------------------
 watcher.c | 136 ++++++++++++++++++++++++++++++++----
 2 files changed, 171 insertions(+), 199 deletions(-)
-------------------------------------------------------------------------------
commit 66b18dbc824259721fb1c628a28367fca1bcee44
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-17 15:39:55 +0200

    add timeout prior to lookup, small error fixes

Base directory -> /
 parser.c  | 2 +-
 watcher.c | 8 +++++---
 2 files changed, 6 insertions(+), 4 deletions(-)
-------------------------------------------------------------------------------
commit d5ad23f9a91b021109082210d35f949ff4423eab
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-17 14:14:47 +0200

    add restart from wtihin application functionality for watcher, some more
    small error fixes

Base directory -> /
 parser.c  |  9 +++++----
 watcher.c | 26 ++++++++++++++++++++------
 2 files changed, 25 insertions(+), 10 deletions(-)
-------------------------------------------------------------------------------
commit dc9a03ea2309acb0a3d8077bf4a67cf42bb95b5f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-17 13:32:27 +0200

    correct error printouts for invoking ubus from watcher, also provide
    preliminary restart functions in order to change paths and loglevel from
    within applications

Base directory -> /
 parser.c  | 61 +++++++++++++++++++++++++++++++++++++++++++++++++------------
 watcher.c | 41 +++++++++++++++++++++++++++++++----------
 2 files changed, 80 insertions(+), 22 deletions(-)
-------------------------------------------------------------------------------
commit f914252a366c6d253a0ad31ed9ddff11a0c59def
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-17 09:59:18 +0200

    set buf mem to 0 prior to initializing, invoking ubus calls from separate
    binary works, however will not invoke after restart

Base directory -> /
 watcher.c | 58 +++++++++++++++++++++++++++++++++++++---------------------
 1 file changed, 37 insertions(+), 21 deletions(-)
-------------------------------------------------------------------------------
commit 9ac0215fa11dd9b5fd89c97dd2e52e0d8d8b5bf5
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 16:25:14 +0200

    add uloop and ubus object to watcher, currently incomplete

Base directory -> /
 parser.c  |   2 ++
 watcher.c | 103 +++++++++++++++++++++++++++++++++++++++++---------------------
 watcher.h |  10 ++++--
 3 files changed, 78 insertions(+), 37 deletions(-)
-------------------------------------------------------------------------------
commit e41346923ce263deadbb8c806fa41a876a1b6b70
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 14:39:43 +0200

    small fix to make ubus IPC work through invoking ubus call

Base directory -> /
 watcher.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit b9135c8eb608d2203f6820fe940609ce24b6dd21
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 12:33:31 +0200

    attempt at invoking ubus method from outside binary that registers it

Base directory -> /
 watcher.c | 30 +++++++++++++++++++++++++++++-
 1 file changed, 29 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit a3001e08a77a7a4597628f3a754eb7c30cdb4012
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 10:41:04 +0200

    update according to checkpatch errors and added some documentation

Base directory -> /
 parser.c  | 81 ++++++++++++++++++++++++---------------------------------------
 parser.h  | 74 +++++++++++++++++++++++++++++++++++++++++++++++++--------
 watcher.c |  2 +-
 watcher.h |  2 +-
 4 files changed, 97 insertions(+), 62 deletions(-)
-------------------------------------------------------------------------------
commit c48bd844a11904a9cb9d73bffb4041b17a918b30
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 09:51:36 +0200

    added ubus IPC by system() from watcher

Base directory -> /
 parser.c  | 45 ++++++++++++++++++++++++++++++---------------
 watcher.c | 24 +++++++++++++-----------
 2 files changed, 43 insertions(+), 26 deletions(-)
-------------------------------------------------------------------------------
commit 4ec1230d5d98dac7a33b37191f2470aeca3cb34f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-16 08:29:58 +0200

    correction to parser header for declaration of check_pipe (should rename)

Base directory -> /
 parser.h | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 8bef0353a661578d5358d315430e632bcb0d958c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 16:53:22 +0200

    does not compile -- fix header at monday

Base directory -> /
 parser.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit 3227782da6e164111ab121e875e165f8fe69bca4
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 16:49:30 +0200

    small fixes

Base directory -> /
 parser.c | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit 07218dc0e73b500aa586511296c3087153258d1a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 16:47:32 +0200

    prepare for ubus ipc, untested

Base directory -> /
 parser.c | 97 ++++++++++++++++++++++++++++------------------------------------
 1 file changed, 42 insertions(+), 55 deletions(-)
-------------------------------------------------------------------------------
commit b02592a3efac991ca7836bcf365570352f634c34
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 15:58:43 +0200

    can change both arguments from single call to set_configuration with both
    arguments

Base directory -> /
 parser.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit 0b2f4ecbfe469acc974da9c15aa72afca913851a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 14:49:52 +0200

    cleaned up and can now use same method to change configuration file and
    loglevel

Base directory -> /
 parser.c | 23 +++++++++++------------
 1 file changed, 11 insertions(+), 12 deletions(-)
-------------------------------------------------------------------------------
commit 6666a31f3e3fb4045c087a94bd0ac80bcc5b21a9
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 14:11:13 +0200

    change config through UCI c API

Base directory -> /
 parser.c | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)
-------------------------------------------------------------------------------
commit 877a72dc5d490578b47ddcd26d114352724a97c4
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 11:57:57 +0200

    add support for path through uci, loglevel timing out

Base directory -> /
 parser.c | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit 3ff76761d2dc05061d9d68282cfa93bfbe1e971c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 10:32:43 +0200

    delete binary

Base directory -> /
 parser | Bin 57260 -> 0 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)
-------------------------------------------------------------------------------
commit dc74ccc90b12899a92b34f39314fd489ceeda26b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 10:32:06 +0200

    forgot to add parser.c, test

Base directory -> /
 parser.c | 78 ++++++++++++++++++++++++++++++++++++++--------------------------
 1 file changed, 46 insertions(+), 32 deletions(-)
-------------------------------------------------------------------------------
commit ee276970030b3a53cc041df0596c32615ce1a2de
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-13 10:26:26 +0200

    add functionality to change configuration file through UCI api

Base directory -> /
 Makefile |   2 +-
 parser   | Bin 0 -> 57260 bytes
 2 files changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit 4968afd535bf929c4783cb593ad7d19ba2078b5c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 16:47:49 +0200

    some minor errors

Base directory -> /
 parser.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
-------------------------------------------------------------------------------
commit 24921f64ca06a077fd35018b8e8ccda69e5d9899
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 16:35:38 +0200

    test stackoverflow code to see uci functionality

Base directory -> /
 parser.c | 53 +++++++++++++++++++++++++++++++++++++++++++++--------
 parser.h | 42 ++++++++++++++++++++++++++++++++++++++++--
 2 files changed, 85 insertions(+), 10 deletions(-)
-------------------------------------------------------------------------------
commit 0cc623501d20bc7e11e0c441e6ef70d4f78cd2e3
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 14:42:47 +0200

    add return to prevent request timeout

Base directory -> /
 parser.c | 2 ++
 1 file changed, 2 insertions(+)
-------------------------------------------------------------------------------
commit 5618a04628e3d1ac147461d0aa1fd39e8c03e84c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 13:57:55 +0200

    restart from init.d and add paranthesis

Base directory -> /
 parser.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 1e699fe9cc0810470e3445af39ff32d09ce93600
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 13:28:04 +0200

    fixed small errors

Base directory -> /
 parser.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
2018-04-18 11:36:24 +02:00
Jakob Olsson
6553804000 change verbose flag to take number 2018-04-18 11:01:11 +02:00
Jakob Olsson
a525ba8db1 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 7801606 take integer as input for ubus method
* ba0c6fa change set_loglevel to accept int
* f061d83 add null termination to strings prior to strcat, add to publish ubus method to alter loglevel, and some minor typoes
-------------------------------------------------------------------------------
commit 7801606c2a529348a08b32e6fc9aaffd324cbe50
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 12:08:42 +0200

    take integer as input for ubus method

Base directory -> /
 parser.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit ba0c6fada99fd51b09752753b1fe06d12229c4e9
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 10:58:23 +0200

    change set_loglevel to accept int

Base directory -> /
 parser.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
commit f061d8312861c46fcf27ef159dc9bf795aac5e55
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 10:49:33 +0200

    add null termination to strings prior to strcat, add to publish ubus method
    to alter loglevel, and some minor typoes

Base directory -> /
 parser.c | 19 ++++++++++---------
 1 file changed, 10 insertions(+), 9 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
839b785329 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 3ffa4fd typo
-------------------------------------------------------------------------------
commit 3ffa4fdfe060b15ee21628d5bd3ed2b6563b1018
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 10:39:42 +0200

    typo

Base directory -> /
 parser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
dae114b97b add JSON folder to copy to router so dont have to write it manually all the time to test 2018-04-12 13:49:55 +02:00
Jakob Olsson
f6ec7a3f58 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 36a4757 fix array format
*   e6451c7 Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into jakob
|\
| * 7fe3e74 can send argument and print data
* | 0678b94 add functionality to pass path or verbose argument, alters configuration file and restarts daemon
|/
* 017a6de smaller error fixes
* 3509854 attempt at ubus method with argument
* 6b350fe add table brackets surrounding each element in an array
* c5f9df1 remove test printouts
* 2a72406 open table inside explore object rather than prior
* bca5404 additional printout tests
* 49a7de6 manual blobmsg addition to test print
* 1617af6 should now record empty arrays
* 0b31324 code errors fix
* 6e225cb keep track of current json structure in blobmsg
* 70eb760 ubus method call and application now both work, small bug fix and small code readability improvement.
* 58a34ac additional confusion regarding file path and pipe fixes
* 001926b mixed up file path and pipe path
* 1523a26 fix minor typoes and errors
* 8a3837e move main, add uloop
* 5c68335 additional test.
* 353fd54 print dummy info to ubus onboarding.parser status
* 17a77e5 missed to change name and add context, publish objects works
* c76006c corrected to ubus_add_object...
*   9216101 attempt to publish ubus objects
|\
| * 74c5b96 minor trivial fixes to watcher, parser & makefile. Does not publish ubus objects.
* b43931b attempt to publish ubus object
-------------------------------------------------------------------------------
commit 36a47571c015cb4e5c8b778f2e6d27f2343260e8
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 09:21:33 +0200

    fix array format

Base directory -> /
 parser.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit e6451c7c6cfc7d263c2830be64d19c6852482975
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 09:17:42 +0200

    Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into jakob

Base directory -> /
 parser.c | 2 ++
 1 file changed, 2 insertions(+)
-------------------------------------------------------------------------------
commit 0678b945d6d2d72216627d7c43646a208140fdfb
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-12 09:16:08 +0200

    add functionality to pass path or verbose argument, alters configuration
    file and restarts daemon

Base directory -> /
 parser.c | 54 ++++++++++++++++++++++++++++++++++++++++++++++++------
 parser.h |  4 ++--
 2 files changed, 50 insertions(+), 8 deletions(-)
-------------------------------------------------------------------------------
commit 7fe3e743a2b181ea9227efcfb98a1c7f58f3d480
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 16:49:54 +0200

    can send argument and print data

Base directory -> /
 parser.c | 2 ++
 1 file changed, 2 insertions(+)
-------------------------------------------------------------------------------
commit 017a6de37338fcfd9c4e6d8f3a20c44f47b14322
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 16:19:59 +0200

    smaller error fixes

Base directory -> /
 parser.c | 21 ++++++++++-----------
 1 file changed, 10 insertions(+), 11 deletions(-)
-------------------------------------------------------------------------------
commit 350985405f9561ff5ec7ed0396babe5b5a2a233a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 16:13:43 +0200

    attempt at ubus method with argument

Base directory -> /
 parser.c | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++++----------
 1 file changed, 61 insertions(+), 11 deletions(-)
-------------------------------------------------------------------------------
commit 6b350feff33782b29a5b49956d211dcf3990bed9
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 13:39:44 +0200

    add table brackets surrounding each element in an array

Base directory -> /
 parser.c | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
-------------------------------------------------------------------------------
commit c5f9df159ade9619b25829857929d71291720410
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 13:24:13 +0200

    remove test printouts

Base directory -> /
 parser.c | 37 +------------------------------------
 parser.h |  1 +
 2 files changed, 2 insertions(+), 36 deletions(-)
-------------------------------------------------------------------------------
commit 2a72406c8aecfdb7d5ce83320d94ab108806ae61
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 13:10:06 +0200

    open table inside explore object rather than prior

Base directory -> /
 parser.c | 52 +++++++++++++++++++++++++++++-----------------------
 1 file changed, 29 insertions(+), 23 deletions(-)
-------------------------------------------------------------------------------
commit bca54040f1faa6a795194ac8c8f7303e381a24a4
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 11:30:12 +0200

    additional printout tests

Base directory -> /
 parser.c | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)
-------------------------------------------------------------------------------
commit 49a7de6e7bc854072f877469e103a86c6dd2563c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 11:14:16 +0200

    manual blobmsg addition to test print

Base directory -> /
 parser.c | 31 +++++++++++++++++--------------
 parser.h |  2 +-
 2 files changed, 18 insertions(+), 15 deletions(-)
-------------------------------------------------------------------------------
commit 1617af6cde6ea57a635ba31258093c1a70464a54
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 10:48:40 +0200

    should now record empty arrays

Base directory -> /
 parser.c | 26 ++++++++++++++------------
 parser.h |  1 +
 2 files changed, 15 insertions(+), 12 deletions(-)
-------------------------------------------------------------------------------
commit 0b31324d9a2be85b00757cde2ec5b0a7d4e504a2
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 09:39:47 +0200

    code errors fix

Base directory -> /
 parser.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
-------------------------------------------------------------------------------
commit 6e225cb6c62da2987925c2da59408b3fc67b1278
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 09:36:11 +0200

    keep track of current json structure in blobmsg

Base directory -> /
 parser.c | 18 +++++++++++++++---
 1 file changed, 15 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit 70eb760c7e2492e1a133519617a7c2952d547234
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 09:17:01 +0200

    ubus method call and application now both work, small bug fix and small code
    readability improvement.

Base directory -> /
 parser.c  | 65 ++++++++++++++++++++++++++++++---------------------------------
 watcher.h |  4 ++--
 2 files changed, 33 insertions(+), 36 deletions(-)
-------------------------------------------------------------------------------
commit 58a34ac88530330de97df1e256da00fb8b65b6ce
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 08:40:19 +0200

    additional confusion regarding file path and pipe fixes

Base directory -> /
 watcher.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)
-------------------------------------------------------------------------------
commit 001926b0cc8e0648df60fa5c4ed372bec0e42707
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-11 08:29:34 +0200

    mixed up file path and pipe path

Base directory -> /
 watcher.c | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
-------------------------------------------------------------------------------
commit 1523a26640a5db09e78c042403ec3738006c99ab
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 16:50:32 +0200

    fix minor typoes and errors

Base directory -> /
 parser.c  | 9 +++++----
 parser.h  | 3 +++
 watcher.c | 4 ++--
 3 files changed, 10 insertions(+), 6 deletions(-)
-------------------------------------------------------------------------------
commit 8a3837ec132c9c4bf850f046057e1c93c44d6fb3
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 16:43:57 +0200

    move main, add uloop

Base directory -> /
 parser.c | 127 ++++++++++++++++++++++++++++++++++++++-------------------------
 1 file changed, 77 insertions(+), 50 deletions(-)
-------------------------------------------------------------------------------
commit 5c68335f6fa4a5e0015756e2f174415545af778f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 13:49:12 +0200

    additional test.

Base directory -> /
 parser.c | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit 353fd547584c58316b475e2b00297ffc63dce1b8
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 12:27:22 +0200

    print dummy info to ubus onboarding.parser status

Base directory -> /
 parser.c | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit 17a77e56d7a7a4200917cb7b4ad17c60d20e2665
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 11:07:58 +0200

    missed to change name and add context, publish objects works

Base directory -> /
 parser.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit c76006c38cb1dbefea92cfab49d84b1bf3a83b17
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 10:55:32 +0200

    corrected to ubus_add_object...

Base directory -> /
 parser.c  | 5 ++++-
 watcher.c | 5 ++++-
 2 files changed, 8 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
commit 921610133314811605955335f91f997d7173a62b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 10:41:48 +0200

    attempt to publish ubus objects

Base directory -> /
 Makefile  | 2 +-
 parser.c  | 4 ++--
 watcher.c | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)
-------------------------------------------------------------------------------
commit b43931b44d94855015c77cb0c309bd6aa6140a47
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 09:30:57 +0200

    attempt to publish ubus object

Base directory -> /
 parser.c  | 25 +++++++++++++++++++------
 parser.h  |  8 ++++----
 watcher.c | 25 +++++++++++++++++++------
 watcher.h |  2 +-
 4 files changed, 43 insertions(+), 17 deletions(-)
-------------------------------------------------------------------------------
commit 74c5b96edb5d25d139322d7dfb82978abbe965a2
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-10 08:46:18 +0200

    minor trivial fixes to watcher, parser & makefile. Does not publish ubus
    objects.

Base directory -> /
 Makefile  | 2 +-
 parser.c  | 6 +++---
 watcher.c | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
f8a92990b0 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* e7129e9 add ubus library to makefile
* e6f93e0 publish ubus objects
* fc0af41 changes to style, also accordance to checkpatch
-------------------------------------------------------------------------------
commit e7129e9f5a2145e20f2011e08233471a4c8ce73b
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 16:28:32 +0200

    add ubus library to makefile

Base directory -> /
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit e6f93e00ae413f5d0b5520397e59b159f958cfba
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 15:59:40 +0200

    publish ubus objects

Base directory -> /
 parser.c  | 21 +++++++++++++++++++++
 watcher.c | 21 +++++++++++++++++++++
 2 files changed, 42 insertions(+)
-------------------------------------------------------------------------------
commit fc0af41610d1ad2e10b254b4e641de5b248938a0
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 15:37:40 +0200

    changes to style, also accordance to checkpatch

Base directory -> /
 parser.c  | 71 ++++++++++++++++++---------------------------------------------
 parser.h  |  1 +
 watcher.c | 39 ++++++++++++++---------------------
 watcher.h |  4 ++--
 4 files changed, 39 insertions(+), 76 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
e7bceaacbb Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* e6f93e0 publish ubus objects
* fc0af41 changes to style, also accordance to checkpatch
-------------------------------------------------------------------------------
commit e6f93e00ae413f5d0b5520397e59b159f958cfba
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 15:59:40 +0200

    publish ubus objects

Base directory -> /
 parser.c  | 21 +++++++++++++++++++++
 watcher.c | 21 +++++++++++++++++++++
 2 files changed, 42 insertions(+)
-------------------------------------------------------------------------------
commit fc0af41610d1ad2e10b254b4e641de5b248938a0
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 15:37:40 +0200

    changes to style, also accordance to checkpatch

Base directory -> /
 parser.c  | 71 ++++++++++++++++++---------------------------------------------
 parser.h  |  1 +
 watcher.c | 39 ++++++++++++++---------------------
 watcher.h |  4 ++--
 4 files changed, 39 insertions(+), 76 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
cb2527007b forgot ! on shebang... 2018-04-12 13:49:55 +02:00
Jakob Olsson
6b92fe1d67 new name 2018-04-12 13:49:55 +02:00
Jakob Olsson
64f92411a6 test please dont look 2018-04-12 13:49:55 +02:00
Jakob Olsson
5f29bb8c6a re-add start and stop 2018-04-12 13:49:55 +02:00
Jakob Olsson
82addbb34f minor errors 2018-04-12 13:49:55 +02:00
Jakob Olsson
aad6415b66 change to naming convention 2018-04-12 13:49:55 +02:00
Jakob Olsson
b427c7b75c Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* aeca1e5 add blob list.h linked list library
* 1a1ea5b push common.h
* 6ed19ae swap to libubox test... dont look thanks
-------------------------------------------------------------------------------
commit aeca1e5f1385feef723af4955d665f244b75f5cd
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-09 09:50:43 +0200

    add blob list.h linked list library

Base directory -> /
 Makefile |  2 +-
 parser.c | 80 +++++++++++++++++++++++++++++-----------------------------------
 parser.h | 27 ++++++++--------------
 3 files changed, 47 insertions(+), 62 deletions(-)
-------------------------------------------------------------------------------
commit 1a1ea5bdc4033bbf3adbb1991572abdd2fff6f96
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-06 15:37:03 +0200

    push common.h

Base directory -> /
 common.h | 4 ++++
 1 file changed, 4 insertions(+)
-------------------------------------------------------------------------------
commit 6ed19ae13fb39e4b3a38c10b8eee307c46854a0a
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-06 15:35:20 +0200

    swap to libubox test... dont look thanks

Base directory -> /
 Makefile  |   4 +-
 debug.c   |   4 +-
 debug.h   |   2 +-
 parser.c  | 152 +++++++++++++++++++++++++++-----------------------------------
 parser.h  |   4 ++
 watcher.c |  49 ++++++++++----------
 watcher.h |  13 +++---
 7 files changed, 105 insertions(+), 123 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
a0afd51889 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 4c3b4b4 minor bug fix, faulty variable order
* 2195e87 get file path from flag
-------------------------------------------------------------------------------
commit 4c3b4b446c2c244d3dfee0a6fd9a18f97a56bfcf
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-06 10:20:49 +0200

    minor bug fix, faulty variable order

Base directory -> /
 debug.h   | 2 +-
 watcher.c | 6 ++++--
 2 files changed, 5 insertions(+), 3 deletions(-)
-------------------------------------------------------------------------------
commit 2195e87d017b174db3107e9b9d17d1b4520307be
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-06 09:57:33 +0200

    get file path from flag

Base directory -> /
 debug.c  | 65 ++++++++++++++++++++++++++++++++++++----------------------------
 debug.h  |  6 +++++-
 parser.c | 36 +++++++++++------------------------
 parser.h | 16 ++++++++--------
 4 files changed, 61 insertions(+), 62 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
c35d6e7db3 add file_path check to init.d script 2018-04-12 13:49:55 +02:00
Jakob Olsson
338465db4c add file path 2018-04-12 13:49:55 +02:00
Jakob Olsson
c4d04e1650 correct config structure 2018-04-12 13:49:55 +02:00
Jakob Olsson
7e0ee31372 config load typo... 2018-04-12 13:49:55 +02:00
Jakob Olsson
65eb95290e correct if cases and minor errors 2018-04-12 13:49:55 +02:00
Jakob Olsson
818c5f19c6 add possibility to stop and start 2018-04-12 13:49:55 +02:00
Jakob Olsson
aeb6c29f32 add configuration, make daemon depend on config for debug options 2018-04-12 13:49:55 +02:00
Jakob Olsson
9e6144f9d6 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 0f39861 correct json include
-------------------------------------------------------------------------------
commit 0f3986168f978d435c1dc0798ead921c18e913d1
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 15:20:50 +0200

    correct json include

Base directory -> /
 parser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
48d8788fba Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 43c64d2 correct watcher in Make
* 66bbf23 add my own debug library to enable --verbose debug
-------------------------------------------------------------------------------
commit 43c64d2ccbd69c8135f975c389bb04ce23ead66c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 15:03:53 +0200

    correct watcher in Make

Base directory -> /
 Makefile | 3 +++
 debug.c  | 1 +
 2 files changed, 4 insertions(+)
-------------------------------------------------------------------------------
commit 66bbf23c9bac0882047f322b02a90f84cfd4a06f
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 14:43:41 +0200

    add my own debug library to enable --verbose debug

Base directory -> /
 JSON/APs.json |   6 +--
 Makefile      |  16 ++++---
 debug.c       |  40 ++++++++++++++++
 debug.h       |   4 ++
 parser.c      | 148 ++++++++++++++++++++++++++++++++++++++++------------------
 parser.h      |   5 +-
 watcher.c     |  32 ++++++++-----
 watcher.h     |   2 +-
 8 files changed, 185 insertions(+), 68 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
effd2ebb48 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 7359cac forget to change path...
-------------------------------------------------------------------------------
commit 7359cac711a4f3f0c882381aecf03f8ecefe4d40
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 10:28:06 +0200

    forget to change path...

Base directory -> /
 parser.c  | 2 +-
 watcher.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
e45b093cc5 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 647ef53 add correct messages and fixed some faulty behaviour (infinitely reading pipe)
-------------------------------------------------------------------------------
commit 647ef53d88bc941dbb0b14855e8ae38d7a4c7fbb
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 10:18:02 +0200

    add correct messages and fixed some faulty behaviour (infinitely reading
    pipe)

Base directory -> /
 JSON/APs.json |  2 +-
 parser.c      | 16 ++++++++++------
 watcher.c     | 45 +++++++++++----------------------------------
 watcher.h     |  9 ++++++---
 4 files changed, 28 insertions(+), 44 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
bbbf1327c4 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 1ff31b2 will try again in 30s if file did not exist
-------------------------------------------------------------------------------
commit 1ff31b20be62ff71d8a0697c5655003ed2b795c4
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-05 08:32:55 +0200

    will try again in 30s if file did not exist

Base directory -> /
 watcher.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
f26fd5d994 change to redirect stdout and stderr to logd 2018-04-12 13:49:55 +02:00
Jakob Olsson
10a8938afd add prints to functions - will hopefully solve starting as daemon 2018-04-12 13:49:55 +02:00
Jakob Olsson
b6e0983d92 remove duplicate start service 2018-04-12 13:49:55 +02:00
Jakob Olsson
d7973f4ede Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 500f481 Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into jakob
* 4a05d44 move struct definition to header
-------------------------------------------------------------------------------
commit 500f4815385b8d434d0be997c9a31556025b8d21
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 15:53:38 +0200

    Merge branch 'jakob' of private.inteno.se:iopsys-onboarding into jakob

Base directory -> /
 parser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
commit 4a05d44da39640af324321ff42b66c03da9cf431
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 15:53:01 +0200

    move struct definition to header

Base directory -> /
 parser.c | 32 +++++++++++++++++---------------
 parser.h | 38 ++++++++++++++++++++++++++------------
 2 files changed, 43 insertions(+), 27 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
3dffcf6401 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* 8a35b40 change include to fit openWRT
-------------------------------------------------------------------------------
commit 8a35b40d95f98d6944c98f7dc7be620c5a1fd1f5
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 14:43:18 +0200

    change include to fit openWRT

Base directory -> /
 parser.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
3dafd0d521 Update feed [ feed_inteno_packages ] package [ onboardingd ]
-------------------------------------------------------------------------------
* fecd251 remove garbage file
* 38bb4ef add gitignore
* 5ae1d88 removed some options
-------------------------------------------------------------------------------
commit fecd251a7b36e03ce809be54b29ce7676bf8f00c
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 14:24:34 +0200

    remove garbage file

Base directory -> /
 JSON/.APs.json.swp | Bin 1024 -> 0 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)
-------------------------------------------------------------------------------
commit 38bb4ef90680e494376a06adfdef506182a9f5c7
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 14:22:39 +0200

    add gitignore

Base directory -> /
 .gitignore | 4 ++++
 1 file changed, 4 insertions(+)
-------------------------------------------------------------------------------
commit 5ae1d88c43c3cc03f940db254637d78196a5429d
Author: Jakob Olsson <jakobols@kth.se>
Date: 2018-04-04 13:57:46 +0200

    removed some options

Base directory -> /
 parser.c  |  4 ++--
 watcher.c | 15 ++-------------
 2 files changed, 4 insertions(+), 15 deletions(-)
-------------------------------------------------------------------------------
2018-04-12 13:49:55 +02:00
Jakob Olsson
6e76de6519 added parser and watcher in procd 2018-04-12 13:49:55 +02:00
Jakob Olsson
6c5e065975 changed hash manually again ?? 2018-04-12 13:49:55 +02:00
Jakob Olsson
f4d2993bac removed some typo error 2018-04-12 13:49:55 +02:00
Jakob Olsson
d3e1350ee4 changed to most recent hash manually 2018-04-12 13:49:55 +02:00
Jakob Olsson
58a8256ee2 makefile changes 2018-04-12 13:49:55 +02:00
Jakob Olsson
09a486f90a hash update manual test 2018-04-12 13:49:55 +02:00
Jakob Olsson
9e55257916 change of hash manually test 2018-04-12 13:49:55 +02:00
Jakob Olsson
4118abd13e correct url for private folder 2018-04-12 13:49:55 +02:00
Jakob Olsson
95e4761eea some changes 2018-04-12 13:49:55 +02:00
Jakob Olsson
59bbfe6bf8 corrections within makefile addresses 2018-04-12 13:49:55 +02:00
Jakob Olsson
03df688e0e first commit 2018-04-12 13:49:55 +02:00
9 changed files with 671 additions and 0 deletions

13
mosquitto/Config.in Normal file
View File

@@ -0,0 +1,13 @@
config MOSQUITTO_LWS
bool "libwebsockets support"
depends on PACKAGE_mosquitto-ssl
default y
help
Includes websockets support in the broker, via libwebsockets
config MOSQUITTO_PASSWD
bool "Include mosquitto_passwd utility"
depends on PACKAGE_mosquitto-ssl
default y
help
mosquitto_passwd is a tool for managing password files for mosquitto.

231
mosquitto/Makefile Normal file
View File

@@ -0,0 +1,231 @@
#
# Copyright (C) 2011-2013 OpenWrt.org
# Copyright (C) 2010 Jo-Philipp Wich <xm@subsignal.org>
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=mosquitto
PKG_VERSION:=1.4.15
PKG_RELEASE:=3
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=LICENSE.txt
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=http://mosquitto.org/files/source/
PKG_HASH:=7d3b3e245a3b4ec94b05678c8199c806359737949f4cfe0bf936184f6ca89a83
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/mosquitto/default
SECTION:=net
CATEGORY:=Network
TITLE:=mosquitto - an MQTT message broker
URL:=http://www.mosquitto.org/
MAINTAINER:=Karl Palsson <karlp@etactica.com>
DEPENDS:= +librt +libuuid
USERID:=mosquitto=200:mosquitto=200
endef
define Package/mosquitto-ssl
$(call Package/mosquitto/default)
TITLE+= (with SSL support)
DEPENDS+= +libopenssl +MOSQUITTO_LWS:libwebsockets-openssl
VARIANT:=ssl
PROVIDES:=mosquitto
endef
define Package/mosquitto-nossl
$(call Package/mosquitto/default)
TITLE+= (without SSL support)
VARIANT:=nossl
PROVIDES:=mosquitto
endef
define Package/mosquitto-ssl/config
source "$(SOURCE)/Config.in"
endef
define Package/mosquitto/default/description
Mosquitto is an open source (BSD licensed) message broker that implements
the MQTT protocol version 3.1 and 3.1.1. MQTT provides a lightweight
method of carrying out messaging using a publish/subscribe model.
This package also includes some basic support for configuring via UCI
endef
define Package/mosquitto-ssl/description
$(call Package/mosquitto/default/description)
This package is built with SSL support. TLS-PSK will be included (in both
the client and broker) if OpenSSL is built with TLS-PSK support.
endef
define Package/mosquitto-nossl/description
$(call Package/mosquitto/default/description)
This package is built WITHOUT SSL support.
endef
define Package/mosquitto-client/default
$(Package/mosquitto/default)
TITLE:= mosquitto - client tools
DEPENDS+=+libcares
PROVIDES:=mosquitto-client
endef
define Package/mosquitto-client-ssl
$(call Package/mosquitto-client/default)
TITLE+= (With SSL support)
DEPENDS+=+libmosquitto-ssl
VARIANT:=ssl
endef
define Package/mosquitto-client-nossl
$(call Package/mosquitto-client/default)
TITLE+= (Without SSL support)
DEPENDS+=+libmosquitto-nossl
VARIANT:=nossl
endef
define Package/mosquitto-client/default/description
Command line client tools for publishing messages to MQTT servers
and subscribing to topics.
endef
define Package/mosquitto-client-ssl/description
$(call Package/mosquitto-client/default/description)
This package is built with SSL support
endef
define Package/mosquitto-client-nossl/description
$(call Package/mosquitto-client/default/description)
This package is built without SSL support
endef
define Package/libmosquitto/default
$(Package/mosquitto/default)
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+libpthread +librt +libcares
TITLE:= mosquitto - client library
PROVIDES:=libmosquitto
endef
define Package/libmosquitto-ssl
$(call Package/libmosquitto/default)
TITLE+= (With SSL Support)
DEPENDS+= +libopenssl
VARIANT=ssl
endef
define Package/libmosquitto-nossl
$(call Package/libmosquitto/default)
TITLE+= (Without SSL Support)
VARIANT=nossl
endef
define Package/libmosquitto/default/description
Library required for mosquitto's command line client tools, also for
use by any third party software that wants to communicate with a
mosquitto server.
Should be useable for communicating with any MQTT v3.1/3.1.1 compatible
server, such as IBM's RSMB, in addition to Mosquitto
endef
define Package/libmosquitto-ssl/description
$(call Package/libmosquitto/default/description)
This package is built with SSL support
endef
define Package/libmosquitto-nossl/description
$(call Package/libmosquitto/default/description)
This package is built without SSL support
endef
define Package/libmosquittopp
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=libmosquitto +libstdcpp
TITLE:= mosquitto - client c++ library
endef
define Package/libmosquittopp/description
C++ Library wrapper for libmosquitto.
endef
define Package/mosquitto-ssl/conffiles
/etc/mosquitto/mosquitto.conf
/etc/config/mosquitto
endef
Package/mosquitto-nossl/conffiles = $(Package/mosquitto-ssl/conffiles)
define Package/mosquitto/install/default
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mosquitto $(1)/usr/sbin/mosquitto
$(INSTALL_DIR) $(1)/etc/mosquitto
$(INSTALL_CONF) $(PKG_BUILD_DIR)/mosquitto.conf $(1)/etc/mosquitto/mosquitto.conf
$(CP) ./files/* $(1)/
endef
define Package/mosquitto-nossl/install
$(call Package/mosquitto/install/default,$(1))
endef
define Package/mosquitto-ssl/install
$(call Package/mosquitto/install/default,$(1))
ifeq ($(CONFIG_MOSQUITTO_PASSWD),y)
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mosquitto_passwd $(1)/usr/bin
endif
endef
define Package/mosquitto-client-ssl/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/client/mosquitto_pub $(1)/usr/bin/mosquitto_pub
$(INSTALL_BIN) $(PKG_BUILD_DIR)/client/mosquitto_sub $(1)/usr/bin/mosquitto_sub
endef
Package/mosquitto-client-nossl/install = $(Package/mosquitto-client-ssl/install)
# This installs files into ./staging_dir/. so that you can cross compile from the host
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_BUILD_DIR)/lib/mosquitto.h $(1)/usr/include
$(CP) $(PKG_BUILD_DIR)/lib/cpp/mosquittopp.h $(1)/usr/include
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_BUILD_DIR)/lib/libmosquitto.so.1 $(1)/usr/lib/
$(CP) $(PKG_BUILD_DIR)/lib/cpp/libmosquittopp.so.1 $(1)/usr/lib/
$(LN) libmosquitto.so.1 $(1)/usr/lib/libmosquitto.so
$(LN) libmosquittopp.so.1 $(1)/usr/lib/libmosquittopp.so
endef
# This installs files on the target. Compare with Build/InstallDev
define Package/libmosquitto-ssl/install
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/libmosquitto.so.1 $(1)/usr/lib/
$(LN) libmosquitto.so.1 $(1)/usr/lib/libmosquitto.so
endef
Package/libmosquitto-nossl/install = $(Package/libmosquitto-ssl/install)
define Package/libmosquittopp/install
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/cpp/libmosquittopp.so.1 $(1)/usr/lib/
$(LN) libmosquittopp.so.1 $(1)/usr/lib/libmosquittopp.so
endef
# Applies to all...
MAKE_FLAGS += WITH_DOCS=no UNAME=Linux
ifeq ($(BUILD_VARIANT),nossl)
MAKE_FLAGS += WITH_TLS=no WITH_WEBSOCKETS=no
else
MAKE_FLAGS += WITH_WEBSOCKETS=$(if $(CONFIG_MOSQUITTO_LWS),"yes","no")
MAKE_FLAGS += WITH_TLS_PSK=$(if $(CONFIG_OPENSSL_WITH_PSK),"yes","no")
endif
$(eval $(call BuildPackage,mosquitto-ssl))
$(eval $(call BuildPackage,mosquitto-nossl))
$(eval $(call BuildPackage,libmosquitto-ssl))
$(eval $(call BuildPackage,libmosquitto-nossl))
$(eval $(call BuildPackage,libmosquittopp))
$(eval $(call BuildPackage,mosquitto-client-ssl))
$(eval $(call BuildPackage,mosquitto-client-nossl))

View File

@@ -0,0 +1,4 @@
config owrt owrt
option use_uci 0
config mosquitto mosquitto

View File

@@ -0,0 +1,211 @@
#!/bin/sh /etc/rc.common
# Basic init script for mosquitto
# April 2012, OpenWrt.org
# Provides support for the luci-app-mosquitto package, if installed
START=80
USE_PROCD=1
TCONF=/tmp/mosquitto.generated.conf
# Usage: append_if cfg uci_name output_name
# add a config line of the form "output_name <value>"
# if the "uci_name" was found.
# output_name defaults to uci_name if not specified.
append_if() {
local cfg="$1"
local uci_name="$2"
local out_name="$3"
if [ -z "$out_name" ]; then
out_name=$uci_name
fi
config_get val $cfg $uci_name
if [ -n "$val" ]; then
echo "$out_name $val" >> $TCONF
fi
}
# mosquitto uses true/false, uci uses 1/0
# note that this is not shell truthy, but equality with 1!
append_bool() {
if [ $2 -eq 1 ]; then
echo "$1 true" >> $TCONF
else
echo "$1 false" >> $TCONF
fi
}
# as per append_if, but gets the value as a uci bool, not raw
append_optional_bool() {
local cfg="$1"
local uci_name="$2"
local out_name="$3"
config_get val $cfg $uci_name
if [ -n "$val" ]; then
config_get_bool real $cfg $uci_name
append_bool $out_name $real
fi
}
convert_mosq_general() {
local cfg="$1"
config_get destinations "$1" log_dest
for dest in $destinations; do
echo "log_dest $dest" >> $TCONF
done
config_get_bool no_remote "$1" no_remote_access 0
if [ "$no_remote" -eq 1 ]; then
echo "bind_address localhost" >> $TCONF
fi
config_get port "$1" port 1883
echo "port $port" >> $TCONF
append_if "$1" protocol
append_if "$1" max_inflight_messages
append_if "$1" max_queued_messages
append_if "$1" sys_interval
}
convert_persistence() {
local cfg="$1"
append_if "$cfg" client_expiration persistent_client_expiration
append_if "$cfg" autosave_interval
append_optional_bool "$cfg" autosave_on_changes autosave_on_changes
append_optional_bool "$cfg" persistence persistence
append_if "$cfg" file persistence_file
config_get loc "$cfg" location
if [ -n "$loc" ]; then
[ -d "$loc" ] || {
mkdir -p "$loc";
chown mosquitto "$loc";
}
echo "persistence_location $loc" >> $TCONF
fi
}
add_listener() {
echo "" >> $TCONF
config_get port "$1" port
if [ -z "$port" ]; then
echo "Ignoring listener section without port"
return
fi
config_get_bool no_remote "$1" no_remote_access 0
if [ "$no_remote" -eq 1 ]; then
echo "listener $port 127.0.0.1" >> $TCONF
else
echo "listener $port" >> $TCONF
fi
append_if "$1" protocol
append_if "$1" http_dir
append_optional_bool "$1" use_username_as_clientid use_username_as_clientid
append_if "$1" cafile
append_if "$1" capath
append_if "$1" certfile
append_if "$1" keyfile
append_if "$1" tls_version
append_optional_bool "$1" require_certificate require_certificate
append_optional_bool "$1" use_identity_as_username use_identity_as_username
append_if "$1" crlfile
append_if "$1" ciphers
append_if "$1" psk_hint
}
add_topic() {
echo "topic $1" >> $TCONF
}
add_bridge() {
config_get conn "$1" connection
config_get addr "$1" address
if [ -z "$conn" -o -z "$addr" ]; then
echo "Ignoring bridge section, misisng connection/address"
return
fi
echo "" >> $TCONF
echo "# Bridge connection from UCI section" >> $TCONF
append_if "$1" connection
append_if "$1" address
config_list_foreach "$1" topic add_topic
append_optional_bool "$1" cleansession cleansession
append_optional_bool "$1" try_private try_private
append_optional_bool "$1" notifications notifications
append_optional_bool "$1" round_robin round_robin
# Note, deprecated upstream, preserve old uci configs
append_if "$1" clientid remote_clientid
append_if "$1" remote_clientid
append_if "$1" local_clientid
append_if "$1" notification_topic
append_if "$1" keepalive_interval
append_if "$1" start_type
append_if "$1" restart_timeout
append_if "$1" idle_timeout
append_if "$1" threshold
append_if "$1" protocol_version bridge_protocol_version
append_optional_bool "$1" attempt_unsubscribe bridge_attempt_unsubscribe
append_if "$1" identity bridge_identity
append_if "$1" psk bridge_psk
append_if "$1" tls_version bridge_tls_version
append_if "$1" restart_timeout
append_if "$1" capath bridge_capath
append_if "$1" cafile bridge_cafile
append_if "$1" certfile bridge_certfile
append_if "$1" keyfile bridge_keyfile
# Note, deprecated upstream, preserve old uci configs
append_if "$1" username remote_username
# Note, deprecated upstream, preserve old uci configs
append_if "$1" password remote_password
append_if "$1" remote_username
append_if "$1" remote_password
}
convert_uci() {
rm -rf $TCONF
echo "Generating mosquitto config file in $TCONF"
echo "# mosquitto.conf file generated from UCI config." >>$TCONF
# Don't include a timestamp, it makes md5sum compares fail
config_load mosquitto
config_foreach convert_mosq_general "mosquitto"
config_foreach convert_persistence "persistence"
config_foreach add_listener "listener"
config_foreach add_bridge "bridge"
}
start_service_real() {
local cfg="$1"
local use_uci write_pid
config_get use_uci "$cfg" use_uci
if [ "$use_uci" -eq 1 ]; then
CONF=$TCONF
convert_uci
else
CONF=/etc/mosquitto/mosquitto.conf
fi
config_get write_pid "$cfg" write_pid 0
procd_open_instance
procd_set_param command mosquitto
procd_append_param command -c $CONF
# Makes /etc/init.d/mosquitto reload work if you edit the final file.
procd_set_param file $CONF
[ "$write_pid" -eq 1 ] && procd_set_param pidfile /var/run/mosquitto.pid
procd_close_instance
}
start_service() {
config_load mosquitto
config_foreach start_service_real owrt
}
service_triggers() {
# Makes "reload_config" work
procd_add_reload_trigger "mosquitto"
}

46
onboardingd/Makefile Normal file
View File

@@ -0,0 +1,46 @@
#
# Copyright (C) 2013 Inteno
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=onboardingd
PKG_VERSION:=0.1
PKG_SOURCE_VERSION:=1b8501d5a24fcdf784678e8f864964fc0138254c
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=git@private.inteno.se:iopsys-onboarding.git
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/onboardingd
CATEGORY:=Utilities
DEPENDS:=+libuci +libubox +ubus +libpthread +TARGET_iopsys_ramips:swconfig +TARGET_iopsys_ramips:libnl-tiny +libopenssl +libmosquitto +libcurl
TITLE:=package for onboarding project, as well as some dongle stuff
endef
define Package/onboardingd/description
questd collects system and network information and presents
this information via ubus
endef
define Package/onboardingd/install
$(CP) ./files/* $(1)/ # copy from files to final image
$(INSTALL_DIR) $(1)/sbin # make the dir
$(INSTALL_BIN) $(PKG_BUILD_DIR)/parser $(1)/sbin/ # copy binaries to new directory
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dongle_apn $(1)/sbin/ # copy binaries to new directory
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dongle_pin $(1)/sbin/ # copy binaries to new directory
$(INSTALL_BIN) $(PKG_BUILD_DIR)/dongle_network $(1)/sbin/ # copy binaries to new directory
$(INSTALL_BIN) $(PKG_BUILD_DIR)/watcher $(1)/sbin/ # copy binaries to new directory
$(INSTALL_DIR) $(1)/root/json # create the directory JSON in root
$(CP) ./json/* $(1)/root/json # copy files from JSON folder to router JSON
$(CP) ./json/* $(1)/root/
endef
$(eval $(call BuildPackage,onboardingd))

View File

@@ -0,0 +1,3 @@
config onboarding onboarding
option loglevel 0
option file '/root/json/aps.json'

View File

@@ -0,0 +1,84 @@
#!/bin/sh /etc/rc.common
START=14
STOP=96
USE_PROCD=1
NAME=onboardingd
start_service() {
config_load onboarding
config_get loglevel onboarding loglevel "0"
config_get file onboarding file false
procd_open_instance
procd_set_param command "/sbin/watcher"
procd_append_param command --loglevel "$loglevel"
if [ "$file" ]
then
procd_append_param command --path "$file"
fi
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
procd_open_instance
procd_set_param command "/sbin/parser"
procd_append_param command --loglevel "$loglevel"
if [ "$file" ]
then
procd_append_param command --path "$file"
fi
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
procd_open_instance
procd_set_param command "/sbin/dongle_apn"
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
procd_open_instance
procd_set_param command "/sbin/dongle_network"
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
procd_open_instance
procd_set_param command "/sbin/dongle_pin"
procd_set_param respawn
procd_set_param stdout 1
procd_set_param stderr 1
procd_close_instance
}
#start() {
# service_start /sbin/watcher
# service_start /sbin/parser
#}
#stop() {
#stop_service() is called after procd killed the service
# service_stop /sbin/watcher
# service_stop /sbin/parser
#}
service_triggers()
{
procd_add_reload_trigger onboarding
#echo "trigger"
}
reload_service() {
stop
start
}

View File

@@ -0,0 +1,53 @@
#!/bin/ash
. /lib/functions.sh
. /usr/share/libubox/jshn.sh
handle_interface() {
local config="$1"
local file, loglevel
config_get file $section "file"
config_get loglevel $section "loglevel"
json_init
json_add_string "file" "$file"
json_add_string "loglevel" "$loglevel"
json_dump
}
case "$1" in
list)
json_init
json_add_object "status"
json_close_object
json_add_object "set_configurations"
json_add_string "loglevel" "x"
json_add_string "file" "x"
json_close_object
json_dump
;;
call)
case "$2" in
status)
config_load onboarding
config_foreach handle_interface onboarding
;;
set_configurations)
local input, loglevel, file
read input
json_load $input
json_get_var loglevel loglevel
json_get_var file file
uci_set onboarding onboarding loglevel "$loglevel"
uci_set onboarding onboarding file "$file"
uci_commit onboarding
config_load onboarding
config_foreach handle_interface onboarding
/etc/init.d/onboarding restart
;;
esac
;;
esac

26
onboardingd/json/aps.json Normal file
View File

@@ -0,0 +1,26 @@
{
"access_points": [
{
"ssid": "o",
"snr": 1,
"channel": 11,
"author": {
"first_name": "Jakob",
"last_name": "Olson"
},
"test_obj": {
"inner_test": 1
},
"array1" : [
{
"inner_array" : [
],
"field5": 0,"a3":2,"a4":5
},
{
"field1": 3, "b2":1, "v4": 5
}
]
}
]
}