iqaudio / tools

Sample CLI tools for IQaudio products
http://www.iqaudio.com
35 stars 11 forks source link

Fork #3

Open alidaf opened 8 years ago

alidaf commented 8 years ago

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

iqaudio commented 8 years ago

I'll check this out later - thanks.

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub.

iqaudio commented 8 years ago

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

alidaf commented 8 years ago

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

iqaudio commented 8 years ago

Run away :-)

I tried to make it thread safe by having critical sections, if your already in the critical (ISR) section then exit.

Gordon

On 30 Oct 2015, at 16:36, Darren notifications@github.com wrote:

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152580607.

alidaf commented 8 years ago

I probably should run away. I think though that the interrupts happen so fast that the function is called multiple times before the critical section flag is set and each call runs it’s own copy of the function. That’s just a guess though based on printing out some info from within the function itself. Typically there’s anything between 3 and 7 printouts before the direction flag is set. I could be totally wrong though but I’ve asked the wiringPi author for a bit if help in understanding his routines. He doesn’t take kindly to questions that he deems a bit idiotic, which is quite often what my questions are!

Would you like me to put you in as originator or co-author or something?

On 30 Oct 2015, at 16:57, IQaudIO notifications@github.com wrote:

Run away :-)

I tried to make it thread safe by having critical sections, if your already in the critical (ISR) section then exit.

Gordon

On 30 Oct 2015, at 16:36, Darren notifications@github.com wrote:

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152580607.

— Reply to this email directly or view it on GitHub.

iqaudio commented 8 years ago

co-author or whatever is fine.

Some people’s attitude makes me upset - how did they learn, how do we empower people to progress and deliver benefits to others if you sit on a thrown and don’t share. :-(

keep striving.

Gordon

On 30 Oct 2015, at 17:11, Darren notifications@github.com wrote:

I probably should run away. I think though that the interrupts happen so fast that the function is called multiple times before the critical section flag is set and each call runs it’s own copy of the function. That’s just a guess though based on printing out some info from within the function itself. Typically there’s anything between 3 and 7 printouts before the direction flag is set. I could be totally wrong though but I’ve asked the wiringPi author for a bit if help in understanding his routines. He doesn’t take kindly to questions that he deems a bit idiotic, which is quite often what my questions are!

Would you like me to put you in as originator or co-author or something?

On 30 Oct 2015, at 16:57, IQaudIO notifications@github.com wrote:

Run away :-)

I tried to make it thread safe by having critical sections, if your already in the critical (ISR) section then exit.

Gordon

On 30 Oct 2015, at 16:36, Darren notifications@github.com wrote:

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152580607.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152589509.

alidaf commented 8 years ago

Agreed. I do apologise for losing your name. I rewrote one of the headers and copied it over all of the others and didn’t do anything to get it back. I’ll add you to all of the code that has the rotary function in it and then sit on the naughty step for an hour!

Take care and chime in if you need or think of anything.

Darren

On 30 Oct 2015, at 17:23, IQaudIO notifications@github.com wrote:

co-author or whatever is fine.

Some people’s attitude makes me upset - how did they learn, how do we empower people to progress and deliver benefits to others if you sit on a thrown and don’t share. :-(

keep striving.

Gordon

On 30 Oct 2015, at 17:11, Darren notifications@github.com wrote:

I probably should run away. I think though that the interrupts happen so fast that the function is called multiple times before the critical section flag is set and each call runs it’s own copy of the function. That’s just a guess though based on printing out some info from within the function itself. Typically there’s anything between 3 and 7 printouts before the direction flag is set. I could be totally wrong though but I’ve asked the wiringPi author for a bit if help in understanding his routines. He doesn’t take kindly to questions that he deems a bit idiotic, which is quite often what my questions are!

Would you like me to put you in as originator or co-author or something?

On 30 Oct 2015, at 16:57, IQaudIO notifications@github.com wrote:

Run away :-)

I tried to make it thread safe by having critical sections, if your already in the critical (ISR) section then exit.

Gordon

On 30 Oct 2015, at 16:36, Darren notifications@github.com wrote:

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152580607.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152589509.

— Reply to this email directly or view it on GitHub.

iqaudio commented 8 years ago

not an issue Darren.

Enjoy the weekend.

Gordon

On 30 Oct 2015, at 17:27, Darren notifications@github.com wrote:

Agreed. I do apologise for losing your name. I rewrote one of the headers and copied it over all of the others and didn’t do anything to get it back. I’ll add you to all of the code that has the rotary function in it and then sit on the naughty step for an hour!

Take care and chime in if you need or think of anything.

Darren

On 30 Oct 2015, at 17:23, IQaudIO notifications@github.com wrote:

co-author or whatever is fine.

Some people’s attitude makes me upset - how did they learn, how do we empower people to progress and deliver benefits to others if you sit on a thrown and don’t share. :-(

keep striving.

Gordon

On 30 Oct 2015, at 17:11, Darren notifications@github.com wrote:

I probably should run away. I think though that the interrupts happen so fast that the function is called multiple times before the critical section flag is set and each call runs it’s own copy of the function. That’s just a guess though based on printing out some info from within the function itself. Typically there’s anything between 3 and 7 printouts before the direction flag is set. I could be totally wrong though but I’ve asked the wiringPi author for a bit if help in understanding his routines. He doesn’t take kindly to questions that he deems a bit idiotic, which is quite often what my questions are!

Would you like me to put you in as originator or co-author or something?

On 30 Oct 2015, at 16:57, IQaudIO notifications@github.com wrote:

Run away :-)

I tried to make it thread safe by having critical sections, if your already in the critical (ISR) section then exit.

Gordon

On 30 Oct 2015, at 16:36, Darren notifications@github.com wrote:

Hi Gordon.

It has become a bit of a project. I’ve switched between ALSA mixer controls and high level controls and I’m now switching back after reading up a lot on ALSA! I may keep the high level controls as a fallback because I’ve started a balance routine but the Pi’s card only has a mono mixer control.

I’ve started looking more in depth at the interrupts and wondering whether I can multithread or write my own interrupts because I think there is a bit of a race condition going. Both pins fire the function plus having it fire on both rising and falling edge causes two function calls each. On top of that there are multiple pulses between indents! My testInt routines are attempts to understand it but I’m new to C and threading so it may take a while. You may have some ideas on this.

Regards

Darren.

On 30 Oct 2015, at 16:26, IQaudIO notifications@github.com wrote:

Wow Darren, just getting to this now. Looks like you’ve been very busy.

More than happy for you to take “ownership” of this going forward. I’ll likely delete my version and just clone it on my github page.

Thanks,

Gordon

On 6 Oct 2015, at 11:26, Darren notifications@github.com wrote:

Hi, I forked your code and have added command line input and a bit more functionality. I broke the fork because I don't know how to use git very well and couldn't get rid of some files that I uploaded. If you want to pull it back then feel free or just leave it with me to develop a bit more. It's at alidaf/raspberryPi. I took a bit of a liberty by licensing it as GPL2. If that isn't compatible with any licensing restrictions you have then let me know. I've renamed it as rotencvol as it can be used without the IQaudioDAC. Regards.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152580607.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152589509.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/iqaudio/tools/issues/3#issuecomment-152594230.