anchor.diff:  -spec append_data_block(binary(), [binary()]) -> [binary()].
   append_data_block(BlockData, Blocks) ->
       lists:reverse([BlockData | lists:reverse(Blocks)]).
  +
  +%% @private
  +%% @doc Maybe send a message to one of the
  +%%      gen_servers to write another block,
  +%%      and then return the updated func inputs
  +-spec maybe_write_block(term(), term(), term()) -> {term(), term(), term()}.
  +maybe_write_block(BufferQueue, FreeWriters, UnackedWrites) ->
  +    {BufferQueue, FreeWriters, UnackedWrites}.
  +
  +-spec state_from_block_written(non_neg_integer(), pid(), term()) -> term().
  +state_from_block_written(BlockID, WriterPid,
  +                                State=#state{unacked_writes=UnackedWrites,
  +                                             free_writers=FreeWriters,
  +                                             buffer_queue=BufferQueue}) ->
  +    NewUnackedSet = ordsets:del_element(BlockID, UnackedWrites),
  +    NewFreeWriters = ordsets:add_element(WriterPid, FreeWriters),
  +    %% 3. Maybe write another block
  +    {NewBufferQueue, NewFreeWriters2, NewUnackedSet2} =
  +    maybe_write_block(BufferQueue, NewFreeWriters, NewUnackedSet),
  +    State#state{unacked_writes=NewUnackedSet2,
  +                free_writers=NewFreeWriters2,
  +                buffer_queue=NewBufferQueue}.
  +
  +
  +
  
positive.code:     %% timer here, depending on the
      %% state we're in?
      {next_state, StateName, State};
  handle_info(_Info, StateName, State) ->
      {next_state, StateName, State}.
  
  
negative.code: %% when a block is written
  %% and we were already not full,
  %% we're still not full
  not_full({block_written, BlockID, WriterPid}, State) ->
      NewState = state_from_block_written(BlockID, WriterPid, State),
      {next_state, not_full, NewState}.
  
  full({block_written, BlockID, WriterPid}, State=#state{reply_pid=Waiter}) ->
      NewState = state_from_block_written(BlockID, WriterPid, State),
      gen_fsm:reply(Waiter, ok),
      {next_state, not_full, NewState}.
  
  all_received({block_written, BlockID, WriterPid}, State) ->
      NewState = state_from_block_written(BlockID, WriterPid, State),
      case ordsets:size(NewState#state.unacked_writes) of
          0 ->
              {next_state, done, State};
          _ ->
  