anchor.diff:      Data = Data0#data{ac = AC,
   		      ac_monitor = ACMonitor,
   		      mac = ClientMAC},
  -    {ok, initial_state(MacMode), Data}.
  +    {ok, initial_state(Data), Data}.
   
   %%
   %% Data transitions follow IEEE 802.11-2012, Section 10.3.2
  
positive.code:     ACMonitor = erlang:monitor(process, AC),
  
      Data = update_from_cfg(StationCfg, Data0#data{ac = AC, ac_monitor = ACMonitor}),
      {next_state, initial_state(MacMode), Data, [{reply, From, {ok, self()}}, ?IDLE_TIMEOUT]};
  
  handle_event({call, From}, delete, connected, Data = #data{mac_mode = MacMode}) ->
      wtp_del_station(Data),
      aaa_disassociation(Data),
      {next_state, initial_state(MacMode), Data, [{reply, From, ok}, ?SHUTDOWN_TIMEOUT]};
  
  handle_event({call, From}, Event, connected, Data = #data{mac_mode = MacMode})
    when Event == detach; Event == delete ->
      wtp_del_station(Data),
      aaa_disassociation(Data),
      {next_state, initial_state(MacMode), Data, [{reply, From, ok}, ?SHUTDOWN_TIMEOUT]};
  
  handle_event({call, From}, Event, _State, _Data) when Event == detach; Event == delete ->
      {keep_state_and_data, [{reply, From, {error, not_attached}}, ?IDLE_TIMEOUT]};
  
negative.code: callback_mode() ->
      [handle_event_function].
  
  init([AC, ClientMAC, StationCfg = #station_config{bss = RadioMAC}]) ->
      Data0 = init_from_cfg(StationCfg),
  
      lager:debug("Register station ~p ~p as ~w", [AC, ClientMAC, self()]),
  