Simplest way to send the whole mainDevice object to console.log?

I tried a few loops and formats, and haven’t found a generic way to show the whole mainDevice object (keys and values) in the log.
Any help will be appreciated.