Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ruby client that uses Marantz web interface as an API.

  • Ruby 2.5, 2.6, 2.7

Put this line in your Gemfile:

source 'https://rubygems.org'

gem 'libxml-ruby'
gem 'marantz'

Then bundle:

$ bundle

You need to configure the gem to fit your needs:

# Default values
Marantz.configure do |config|
  config.host = '127.0.0.1'
  config.max_volume = 50.0
end
avr = Marantz::Client.new
if avr.power != "ON"
  avr.on
else
  puts "Already on"
end

# Power off
avr.off

Currently the following sources are switchable: SAT/CBL, Internet Radio, Presets, Spotify.

 # Change to Internet Radio
 avr.source = :iradio

  # Change preset
 avr.preset = 6

# Change to SAT/CBL
 avr.source = :satellite

 # Getting current source
 avr.source
 => :satellite

NOTE: If the receiver is in standby mode it will be turned on.

# Setting volume (dB)
avr.volume = 35.0

# Getting current volume
avr.volume
=> 35.0

# Muting
avr.mute
avr.unmute

Feel free to message me on GitHub (stoffus).

Copyright © 2020 Christopher Svensson.

About

Ruby client for controlling Marantz AVRs.

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.