diff --git a/RtMidi.cabal b/RtMidi.cabal
--- a/RtMidi.cabal
+++ b/RtMidi.cabal
@@ -1,6 +1,6 @@
 cabal-version:       3.0
 name:                RtMidi
-version:             0.6.0.0
+version:             0.6.1.0
 synopsis:            Haskell wrapper for RtMidi, the lightweight, cross-platform MIDI I/O library.
 description:         Please see the README on GitHub at <https://github.com/riottracker/RtMidi#readme>
 category:            Sound
diff --git a/Sound/RtMidi.hs b/Sound/RtMidi.hs
--- a/Sound/RtMidi.hs
+++ b/Sound/RtMidi.hs
@@ -34,6 +34,7 @@
   , defaultOutput
   , createOutput
   , sendMessage
+  , sendUnsafeMessage
   , currentApi
   )
 where
@@ -388,8 +389,12 @@
 
 -- | Immediately send a single message out an open MIDI output port.
 sendMessage :: OutputDevice -> VS.Vector Word8 -> IO ()
-sendMessage d buf = VS.unsafeWith buf $ \m -> withDevicePtr d $ \dptr ->
-  void (rtmidi_out_send_message dptr (coerce m) (fromIntegral (VS.length buf)))
+sendMessage d buf = VS.unsafeWith buf (\ptr -> sendUnsafeMessage d ptr (VS.length buf))
+
+-- | A variant of 'sendMessage' that allows reading directly from pinned memory.
+sendUnsafeMessage :: OutputDevice -> Ptr Word8 -> Int -> IO ()
+sendUnsafeMessage d ptr size =
+  withDevicePtr d $ \dptr -> void (rtmidi_out_send_message dptr (coerce ptr) (fromIntegral size))
 
 -- | Returns the specifier for the MIDI 'Api' in use
 currentApi :: IsDevice d => d -> IO Api
