Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Get error Plugin Crashed: undefined method `generate_siri_utterance' for #<SiriProxy::PluginManager:0x2842140> #2

Open
heydemar opened this issue Aug 13, 2013 · 8 comments

Comments

@heydemar
Copy link

[Info - Plugin Manager] Processing 'Temperatur'
[Info - Plugin Manager] Processing plugin RPi
[Info - Plugin Manager] Matches (?i-mx:temperatur)
[Info - Plugin Manager] Applicable states:
[Info - Plugin Manager] Current state:
[Info - Plugin Manager] Matches, executing block
[Info - Plugin Manager] Say: Your Raspberry Pi is 49.8°C or 121.6°F.
[Info - Plugin Manager] Plugin Crashed: undefined method `generate_siri_utterance' for #SiriProxy::PluginManager:0x2842140
[Info - Guzzoni] Got invalid data (non-ACE protocol?), terminating the connection.

@elvisimprsntr
Copy link
Owner

I can't help if you don't give me any background what you changed or what you were doing.

@elvisimprsntr
Copy link
Owner

Try posting your code and I will take a look

@heydemar
Copy link
Author

Sorry, it is the org. code of you:

class SiriProxy::Plugin::RPi < SiriProxy::Plugin

def initialize(config)
end

############# Commands

listen_for(/warm is my pi/i) do
get_temp
request_completed
end

listen_for(/(restart|stop|start) airpi/i) do |command|
restart_airpi(command.downcase.strip)
request_completed
end

############# Actions

def get_temp
tempC = vcgencmd measure_temp.gsub(/[^\d.]/, '').to_f
tempF = sprintf("%.1f", tempC * 9 / 5 + 32)
say "Your Raspberry Pi is #{tempC}°C or #{tempF}°F."
end

def restart_airpi(command)
sh /etc/init.d/shairport #{command}
say "#{command.capitalize} AirPi."
end

############# Initialization

end

@elvisimprsntr
Copy link
Owner

The code it correct. There must be something wrong with your Ruby or SiriProxy installation or config.

  1. Are you using my SD card image or did you install from scratch?
  2. What version of ruby are you running? Post output of 'which siriproxy'
  3. What versions of gems are you using? Post the output of 'siriproxy bundle'

@elvisimprsntr
Copy link
Owner

The other possibility is Siri cannot interpret the degree symbol in the say statement for your language settings. Try replacing the degree symbol with the word 'degrees'

@elvisimprsntr
Copy link
Owner

Are you sure you didn't modify my code? Because the output log indicates otherwise.

@elvisimprsntr
Copy link
Owner

What did you do to resolve this error?

@elvisimprsntr
Copy link
Owner

Someone has suggested the follow on another repo:

netpro2k/SiriProxy-Twitter#2

@elvisimprsntr elvisimprsntr reopened this Oct 26, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants