Hamed el Muden, Secretary at Tetuan to the Prince of Barbary