   # and then run as lambas (anonymous callbacks) either in the init function or the loop function.
   defmacro start(do: body) do
     quote do
-      GenServer.call(Blockytalky.UserCode, {:push_fun, :init, fn -> unquote(body) end})
+      GenServer.call(Blockytalky.UserState, {:push_fun, :init, fn -> unquote(body) end})
     end
   end
   defmacro repeatedly(do: body) do
     quote do
-      GenServer.call(Blockytalky.UserCode, {:push_fun, :loop, fn -> unquote(body) end})
+      GenServer.call(Blockytalky.UserState, {:push_fun, :loop, fn -> unquote(body) end})
     end
   end
   defmacro in_time(seconds, do: body) do

  end
  defmacro while_sensor({:in, _m, [port_id, range={:.., _m2, [_left,_right]}]}, do: body) do
    quote do
      GenServer.call(Blockytalky.UserCode, {:push_fun, :loop, fn ->
        while_sensor_value_range(unquote(port_id),
          unquote(range), #could be a constant or a var
          fn -> unquote(body) end)

  defmacro when_receive(msg, do: body) do
    #msg could be get("var")
    quote do
      GenServer.call(Blockytalky.UserState, {:push_fun, :loop, fn ->
        if(unquote(msg) == dequeued_message) do #dequeue message is set at the beginning of the loop
          unquote(body)
        end
