Commit 023f410a authored by Adam Wujek's avatar Adam Wujek Committed by Adam Wujek

[BUG: #35] proto-ext-whiterabbit: fix Servo not initialized error

This is not the final solution. With this fix this error does not occur
any more, but WRS/WRPC does not sync. It hits the bug #36Signed-off-by: 's avatarAdam Wujek <adam.wujek@creotech.pl>
parent 48dd0215
......@@ -333,6 +333,14 @@ static int wr_extension_state_changed( struct pp_instance * ppi) {
return 0;
}
static int wr_new_slave (struct pp_instance *ppi, void *buf, int len) {
if ( ppi->extState==PP_EXSTATE_ACTIVE ) {
wr_servo_init(ppi);
}
return 0;
}
struct pp_ext_hooks wr_ext_hooks = {
.init = wr_init,
.open = wr_open,
......@@ -342,6 +350,7 @@ struct pp_ext_hooks wr_ext_hooks = {
.handle_followup = wr_handle_followup,
.ready_for_slave = wr_ready_for_slave,
.run_ext_state_machine = wr_run_state_machine,
.new_slave = wr_new_slave,
#if CONFIG_HAS_P2P
.handle_presp = wr_handle_presp,
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment