Closed merlinmb closed 9 years ago
Hi @merlinmb - I really like the idea of making the library more complete.
To submit patches directly you'll want to fork the repository, then make changes in a new branch before submitting a pull request. I'll review the code (after some automated style checking) and if everything looks good the code is added.
Rather than using 2 functions I think it might make more sense to have one setter with a parameter like
def set_disp_lco(self, display):
self.read_data()
if display:
self.set_byte(0x08, (self.registers[0x08] | 0x80))
else:
self.set_byte(0x08, (self.registers[0x08] & 0x7F))
time.sleep(0.002)
It might even be paired with another function to get the status of the flag as well.
Thoughts?
Thanks for the assistance - new to python and Git, I'm receiving errors while trying to publish a new branch with my changes... will research more online on howto accomplish this with Git for Windows destop.
On Wed, Jan 7, 2015 at 9:30 PM, Phil Fenstermacher <notifications@github.com
wrote:
Hi @merlinmb https://github.com/merlinmb - I really like the idea of making the library more complete.
To submit patches directly you'll want to fork the repository, then make changes in a new branch before submitting a pull request https://help.github.com/articles/using-pull-requests/. I'll review the code (after some automated style checking) and if everything looks good the code is added.
Rather than using 2 functions I think it might make more sense to have one setter with a parameter like
def set_disp_lco(self, display): self.read_data() if display: self.set_byte(0x08, (self.registers[0x08] | 0x80)) else: self.set_byte(0x08, (self.registers[0x08] & 0x7F)) time.sleep(0.002)
It might even be paired with another function to get the status of the flag as well.
Thoughts?
— Reply to this email directly or view it on GitHub https://github.com/pcfens/RaspberryPi-AS3935/issues/14#issuecomment-69077140 .
Relates to PR #16
Closed/fixed as part of #16 and #18.
Hi @pcfens - I have written two methods in python to put the module into calibration mode to find the frequency, tried committing, seems I have no rights. Perhaps you would consider including these methods into RPi_AS3935.py