Skip to content
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

PWM control receiving error in log #485

Closed
mrplow opened this issue May 25, 2018 · 1 comment
Closed

PWM control receiving error in log #485

mrplow opened this issue May 25, 2018 · 1 comment

Comments

@mrplow
Copy link

mrplow commented May 25, 2018

Mycodo Issue Report:

  • Specific Mycodo Version: 6.1.2

Problem Description

PWM control receiving error in log

  • I'm trying to control an externally powered 4pin 12V CPU fan via PWM control. Eventually I'll set it up to control temperature (but I haven't set that part up yet)
  • bcm pin: 5, library: any pin, frequency 20000 hz.
  • fan is plugged into an acdc 12v adapter and is running, control pin is connected to bcm pin 5.

Errors

When I set a duty cycle and press Turn on I receive the following error

 2018-05-24 21:51:39,681 - mycodo.daemon - ERROR - Could not turn output on: unorderable types: str() > int()
Traceback (most recent call last):
  File "/var/mycodo-root/mycodo/mycodo_daemon.py", line 780, in output_on
    trigger_conditionals=trigger_conditionals)
  File "/var/mycodo-root/mycodo/controller_output.py", line 479, in output_on_off
    duty_cycle=duty_cycle)
  File "/var/mycodo-root/mycodo/controller_output.py", line 587, in check_conditionals
    if self.is_on(output_id) and on_duration > 0:
TypeError: unorderable types: str() > int()

Additional Notes

I tested this exact same setup a while ago. I've log since trashed that install after upgrading my pi. I may have been 5.7 or an early version 6 mycodo. I didn't have the sensors installed so I haven't played with setting up a controller yet.

@mrplow
Copy link
Author

mrplow commented May 31, 2018

Turns out my ground between the pi and the fan has become disconnected.

This fixed the actual issue of the fan speed not changing but I still receive the error.

So really this issue is just cosmetic. Although I assume that error output could lead to sanitizing some code.
I looked but I'm not well versed enough in Python to correct it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant