New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Sensor Unplugged" warning missing on app start w/ no sensor #57

Closed
nilbus opened this Issue Feb 9, 2015 · 4 comments

Comments

Projects
None yet
2 participants
@nilbus
Owner

nilbus commented Feb 9, 2015

It did seem to work though after plugging and unplugging a sensor.

@nilbus nilbus added the bug label Feb 9, 2015

@everetteallen

This comment has been minimized.

Show comment
Hide comment
@everetteallen

everetteallen Feb 11, 2015

So still seeing this issue where Sensor Unplugged is missing.
If I unplug and replug "hot" I get:

sudo foreman start
19:42:29 web.1  | started with pid 844
19:42:30 web.1  | Warning: You're using Rubygems 2.0.14 with Spring. Upgrade to at least Rubygems 2.1.0 and run `gem pristine --all` for better startup performance.
19:42:32 web.1  | I, [2015-02-10T19:42:32.521912 #844]  INFO -- : Sensor watch started w/ device search path: "/dev/tty.usbserial"
19:44:15 web.1  | E, [2015-02-10T19:44:15.629024 #844] ERROR -- : Actor crashed!
19:44:15 web.1  | Errno::ENXIO: Device not configured
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:44:in `block in sysread'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:390:in `synchronize'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:42:in `sysread'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:322:in `fill_rbuff'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:159:in `gets'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:181:in `each'
19:44:15 web.1  |   /Users/ega/pinewood-derby-master/lib/serial_device.rb:33:in `monitor_input'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:26:in `public_send'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:26:in `dispatch'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:122:in `dispatch'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/cell.rb:60:in `block in invoke'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/cell.rb:71:in `block in task'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/actor.rb:357:in `block in task'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/tasks.rb:57:in `block in initialize'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/tasks/task_fiber.rb:15:in `block in create'

My derby_config.yml is:

admin_password: <%= ENV['DERBY_ADMIN_KEY'] %>
# device_glob: "/dev/tty{USB,.usbserial}*"
device_glob: "/dev/tty.usbserial"
lane_count: 3
sensor_class_name: MicroWizardFastTrack

Any ideas??

everetteallen commented Feb 11, 2015

So still seeing this issue where Sensor Unplugged is missing.
If I unplug and replug "hot" I get:

sudo foreman start
19:42:29 web.1  | started with pid 844
19:42:30 web.1  | Warning: You're using Rubygems 2.0.14 with Spring. Upgrade to at least Rubygems 2.1.0 and run `gem pristine --all` for better startup performance.
19:42:32 web.1  | I, [2015-02-10T19:42:32.521912 #844]  INFO -- : Sensor watch started w/ device search path: "/dev/tty.usbserial"
19:44:15 web.1  | E, [2015-02-10T19:44:15.629024 #844] ERROR -- : Actor crashed!
19:44:15 web.1  | Errno::ENXIO: Device not configured
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:44:in `block in sysread'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:390:in `synchronize'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:42:in `sysread'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:322:in `fill_rbuff'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:159:in `gets'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-io-0.15.0/lib/celluloid/io/stream.rb:181:in `each'
19:44:15 web.1  |   /Users/ega/pinewood-derby-master/lib/serial_device.rb:33:in `monitor_input'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:26:in `public_send'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:26:in `dispatch'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/calls.rb:122:in `dispatch'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/cell.rb:60:in `block in invoke'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/cell.rb:71:in `block in task'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/actor.rb:357:in `block in task'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/tasks.rb:57:in `block in initialize'
19:44:15 web.1  |   /Library/Ruby/Gems/2.0.0/gems/celluloid-0.16.0/lib/celluloid/tasks/task_fiber.rb:15:in `block in create'

My derby_config.yml is:

admin_password: <%= ENV['DERBY_ADMIN_KEY'] %>
# device_glob: "/dev/tty{USB,.usbserial}*"
device_glob: "/dev/tty.usbserial"
lane_count: 3
sensor_class_name: MicroWizardFastTrack

Any ideas??

@nilbus

This comment has been minimized.

Show comment
Hide comment
@nilbus

nilbus Feb 11, 2015

Owner

That "actor" that crashes is assigned to reading data from the USB serial device. ENXIO is an error that means the device is not there, which is expected but not handled directly, thus you see the error. After that actor crashes, it should remove that device and stop trying to talk to it. Then every 5 seconds, it continues to try to open the device again and start communicating with it. In other words, despite that error, I would expect it to continue to read times from the track sensor. Have you tried it afterward to see if it works?

I will investigate the separate issue of the "Sensor Unplugged" notice not showing.

Owner

nilbus commented Feb 11, 2015

That "actor" that crashes is assigned to reading data from the USB serial device. ENXIO is an error that means the device is not there, which is expected but not handled directly, thus you see the error. After that actor crashes, it should remove that device and stop trying to talk to it. Then every 5 seconds, it continues to try to open the device again and start communicating with it. In other words, despite that error, I would expect it to continue to read times from the track sensor. Have you tried it afterward to see if it works?

I will investigate the separate issue of the "Sensor Unplugged" notice not showing.

@nilbus nilbus closed this in c164995 Feb 11, 2015

@nilbus

This comment has been minimized.

Show comment
Hide comment
@nilbus

nilbus Feb 11, 2015

Owner

I just pushed a fix for the sensor unplugged notification. Glad you pointed this out to me. Thanks!

Owner

nilbus commented Feb 11, 2015

I just pushed a fix for the sensor unplugged notification. Glad you pointed this out to me. Thanks!

@everetteallen

This comment has been minimized.

Show comment
Hide comment
@everetteallen

everetteallen Feb 11, 2015

I have tried afterward and still does not work. Tried following the
plug sequence completely, unplug, wait 10 -20 seconds plugin again and
get now response. It is like the code did not recover tho not sure what
logs I should look at.

On 2/10/15 9:58 PM, Edward Anderson wrote:

That "actor" that crashes is assigned to reading data from the USB
serial device. ENXIO is an error that means the device is not there,
which is expected but not handled directly, thus you see the error.
After that actor crashes, it should remove that device and stop trying
to talk to it. Then every 5 seconds, it continues to try to open the
device again and start communicating with it. In other words, despite
that error, I would expect it to continue to read times from the track
sensor. Have you tried it afterward to see if it works?

I will investigate the separate issue of the "Sensor Unplugged" notice
not showing.


Reply to this email directly or view it on GitHub
#57 (comment).

Everette Gray Allen Systems Programmer II
Office of Information Technology Macintosh Support Specialist
2620 Hillsborough St, Campus Box 7109
Raleigh, NC 27695-7109 AIM: EveretteAlln
919-515-4558 Everette_Allen@ncsu.edu

everetteallen commented Feb 11, 2015

I have tried afterward and still does not work. Tried following the
plug sequence completely, unplug, wait 10 -20 seconds plugin again and
get now response. It is like the code did not recover tho not sure what
logs I should look at.

On 2/10/15 9:58 PM, Edward Anderson wrote:

That "actor" that crashes is assigned to reading data from the USB
serial device. ENXIO is an error that means the device is not there,
which is expected but not handled directly, thus you see the error.
After that actor crashes, it should remove that device and stop trying
to talk to it. Then every 5 seconds, it continues to try to open the
device again and start communicating with it. In other words, despite
that error, I would expect it to continue to read times from the track
sensor. Have you tried it afterward to see if it works?

I will investigate the separate issue of the "Sensor Unplugged" notice
not showing.


Reply to this email directly or view it on GitHub
#57 (comment).

Everette Gray Allen Systems Programmer II
Office of Information Technology Macintosh Support Specialist
2620 Hillsborough St, Campus Box 7109
Raleigh, NC 27695-7109 AIM: EveretteAlln
919-515-4558 Everette_Allen@ncsu.edu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment