diff --git a/CMake/CMakeHelpers.cmake b/CMake/CMakeHelpers.cmake
index b56e39ea5d16cc1cfb680266630df42c5ae09dca..4afd1a43fd79a53254e584723f29599021a46e66 100644
--- a/CMake/CMakeHelpers.cmake
+++ b/CMake/CMakeHelpers.cmake
@@ -2,6 +2,9 @@
 macro (add_event arg1 event_name dir dir_out)
       
   exec_program( "protoc" "${PROTOBUF_BIN}" ARGS "${dir}/${event_name}.proto" "--proto_path=${dir}" "--python_out=${dir_out}" OUTPUT_VARIABLE output )
+
+  list (APPEND ${arg1}_EVENT_SOURCE_FILES "${dir}/${event_name}.pb.h" "${dir}/${event_name}.pb.cc")
+  
 #  message ("output off protoc is: ${output}")
 #  message ("${dir}")
 #  message ("${dir_out}")
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d052e5972d70bc9856eee690f9c49644c3e00cf4..04f78bb385fbf7deddf26bcc11af87b2d27ae408 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -29,8 +29,6 @@ set (NETT_LIBRARY_DEBUG "" CACHE FILEPATH "The nett debug library to link agains
 
 set( ZMQ_LIBRARY "" CACHE FILEPATH "The zmq library to link against" )
 
-
-
 include( "include/nett-python/_SourceFiles.cmake" )
 include( "src/nett-python/_SourceFiles.cmake" )
 
@@ -41,16 +39,17 @@ include_directories (${PROTOBUF_INCLUDE_DIR})
 include_directories ("${CMAKE_CURRENT_SOURCE_DIR}/include")
 include_directories ("${CMAKE_CURRENT_SOURCE_DIR}/include")
 
-add_library (nett_python SHARED ${ProjectSources})
+add_event ( nett_python routing_message ${NETT_SCHEMA_DIR} ${PROJECT_BINARY_DIR} )
+add_event ( nett_python string_message ${NETT_SCHEMA_DIR} ${PROJECT_BINARY_DIR} )
+
+add_library (nett_python SHARED ${ProjectSources} ${nett_python_EVENT_SOURCE_FILES})
+
 target_link_libraries( nett_python optimized ${NETT_LIBRARY} debug ${NETT_LIBRARY_DEBUG})
 target_link_libraries( nett_python optimized ${PYTHON_LIBRARY} debug ${PYTHON_LIBRARY_DEBUG})
 target_link_libraries( nett_python optimized ${BOOST_PYTHON_LIBRARY} debug ${BOOST_PYTHON_LIBRARY_DEBUG})
 target_link_libraries( nett_python optimized ${PROTOBUF_LIBRARY} debug ${PROTOBUF_LIBRARY_DEBUG})
 target_link_libraries( nett_python ${ZMQ_LIBRARY} )
 
-add_event ( nett_python routing_message ${NETT_SCHEMA_DIR} ${PROJECT_BINARY_DIR} )
-add_event ( nett_python string_message ${NETT_SCHEMA_DIR} ${PROJECT_BINARY_DIR} )
-
 if( WIN32 )
 add_custom_command( TARGET nett_python
                     POST_BUILD
diff --git a/src/nett-python/nett-python.cpp b/src/nett-python/nett-python.cpp
index 51e89731ff07a86146e823d51e5338e87a5fa28c..714b91fa262b72e7c5247533b377018eedc4bd19 100644
--- a/src/nett-python/nett-python.cpp
+++ b/src/nett-python/nett-python.cpp
@@ -11,22 +11,51 @@
 
 #include <../schema/string_message.pb.h>
 
-
 using namespace boost::python;
 
-std::shared_ptr<nett::slot_in<string_message>> create_slot_in_string_message()
+const std::string& a = "tcp://127.0.0.1:65445";
+
+void initA(std::string endpoint)
 {
-    return nett::make_slot_in<string_message>();
+    nett::initialize( a );
 }
 
-//nett::make_slot_out<string_message>(const std::string &slot_tag);
-
 
+template <class event_type>
+class python_slot_out
+{
+public:
+    python_slot_out( std::string const &slot_tag )
+    {
+        slot_ = nett::make_slot_out<event_type>( slot_tag );
+    }
+
+    void send( std::string const & message )
+    {
+        slot_->send(convert(message));
+    }
+
+private:
+    event_type convert( std::string const & serialized )
+    {
+        event_type message;
+        if ( !message.ParseFromString( serialized ) )
+            throw std::runtime_error( "protobuf ParseFromString() failed" );
+
+        return message;
+    }
+
+    std::shared_ptr < nett::slot_out<event_type> > slot_;
+};
 
 BOOST_PYTHON_MODULE(nett_python)
 {
-     def("initialize", &nett::initialize);
+    def( "initialize", &nett::initialize );
+    //def( "shutdown", &nett::shutdown);
+
+     class_< python_slot_out < string_message > >( "slot_out_string", init<std::string>() )
+         .def( "send", &python_slot_out< string_message >::send)
+         ;
 
 
-     class_ < nett::slot_in < string_message >, boost::noncopyable >( "slot_in_string", no_init );
 }
\ No newline at end of file