diff options
author | Fred Sundvik <fsundvik@gmail.com> | 2016-03-12 19:35:09 +0200 |
---|---|---|
committer | Fred Sundvik <fsundvik@gmail.com> | 2016-03-12 19:35:09 +0200 |
commit | 11bd4ba0dd39654318bd0a3ae495656c2b2187bb (patch) | |
tree | 2f14db1331b35a61877ee481e3a2779cb00ac542 /serial_link/system/system.c | |
parent | 168c5b679f23c25263623f0f8f2b340543cf2140 (diff) | |
download | firmware-11bd4ba0dd39654318bd0a3ae495656c2b2187bb.tar.gz firmware-11bd4ba0dd39654318bd0a3ae495656c2b2187bb.tar.bz2 firmware-11bd4ba0dd39654318bd0a3ae495656c2b2187bb.zip |
Remote object callable from many places
Change init_transport to add_remote_objects, so that it can be
called many times from different places.
Diffstat (limited to 'serial_link/system/system.c')
-rw-r--r-- | serial_link/system/system.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/serial_link/system/system.c b/serial_link/system/system.c index 9cf695a30..9e4ee5d95 100644 --- a/serial_link/system/system.c +++ b/serial_link/system/system.c @@ -120,7 +120,7 @@ static matrix_object_t last_matrix = {}; SLAVE_TO_MASTER_OBJECT(keyboard_matrix, matrix_object_t); MASTER_TO_ALL_SLAVES_OBJECT(serial_link_connected, bool); -remote_object_t* test_remote_objects[] = { +static remote_object_t* remote_objects[] = { REMOTE_OBJECT(serial_link_connected), REMOTE_OBJECT(keyboard_matrix), }; @@ -128,7 +128,7 @@ remote_object_t* test_remote_objects[] = { void init_serial_link(void) { serial_link_connected = false; init_serial_link_hal(); - init_transport(test_remote_objects, sizeof(test_remote_objects)/sizeof(remote_object_t*)); + add_remote_objects(remote_objects, sizeof(remote_objects)/sizeof(remote_object_t*)); init_byte_stuffer(); sdStart(&SD1, &config); sdStart(&SD2, &config); |