-
-
Notifications
You must be signed in to change notification settings - Fork 74
Auto-PTT and Auto-COS Feature (Built-in High-Performance Low Latency VOX) #19
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
Comments
I started working on this feature in pull request #25. I implemented a very basic thresholding mechanism both on the data that is being sent and received by the AIOC. This means that with this change, you can
I have attached a firmware file that you can use for testing purposes. Note that this is purely for testing and not a release (will follow later). Automatic PTT (to be renamed) works quite well. Tested with direwolf. However from my testing so far there are the following issues with the Automatic COS:
Feel free to play around with the new features and let me know what works for you and what doesn't. I have actually not tested this feature with real data transmission between to APRS nodes. I invite you to do so. I thought about using the DCD pin of the virtual COM port as a COS input to the PC, but I had some issues with the USB stack. Do you think this feature is worthwhile, then I will try again and find out what exactly the problem is. If not, COS via CM108 is currently the only way to get COS to the PC. EDIT: Also we still need a new name for this feature, since Auto-PTT is taken (and trademarked) by SignaLink. There was already a suggestion for "CATless PTT" by ITCMD (#17 (comment)). For symmetry reason I would love something that applies to PTT as well as COS. Such as APTT and ACOS (for Automatic PTT and Automatic COS), but that might be too close to the AutoPTT(tm) from SignaLink. Any suggestions? |
Regarding the name, what about virtual PTT/COS? VPTT and VCOS? |
Just cuz I like catless PTT, what about "Catless PTT" and "Autocat COS?" I really appreciate your hard work on the VOX mode! |
Any updates on this? How stable does the virtual ptt firmware seem to be? Could I get a version that has the automatic ptt but none of the COS stuff? I don't think many of us have a use for COS. |
Have not gotten any feedback so far. From my limited testing it works.. feel free to test 😁 |
@skuep does the linked file have COS stuff that hasn't been working also enabled? Also, side note, I talked with John on wb2osz/direwolf#448 (he's in the same radio club as me) a few weeks ago and he's looking into the issue! Edit: Looks like he's already had some back and fourth with you, which is good! |
@ITCMD yeah, thanks for getting him into contact with me, much appreciated 😁 say thanks to him from me. What do you mean with "COS stuff that hasn't been working"? The firmware file has both the automatic PTT and COS enabled, yep. |
I think it comes from my misunderstanding of what the COS does or would be for. If it doesn't interfere with basic use of the VOX function out and receiving audio in, then it should be perfect for what we need. I'm assembling and installing the firmware on some today. |
Ah, yeah. The COS stuff doesn't interfere with the functionality, you are right. It's just an indicator (a virtual CM108 input gpio reflecting whether there is audio coming from the radio. It's basically VOX in the other direction as an information there for the PC. If the PC doesn't read this information, it's just fine. |
Gotchya makes sense. Flashed it and it works, although for all my HTs the rfi seems to be messing with it. It transmits for a sec then disconnects if I have more than 1w out. Might be the usb hub vs the AIOC, however. Does make me wish the usb c port pointed down instead of up so the usb cable wasnt next to the antenna. |
3 more questions for you:
|
Interesting.. was it different with the regular firmware? Other than that there have been some reports hinting that the USB cable works as a tiger tail, which introduces high RF currents into the USB Line. Still not sure what to do about it, other than inserting a ferrite into the aioc-to-radio ground line. Still needs to be tested tho
No, CAT PTT is disabled, exactly for the reason you stated.
I am a Linux user myself, so I don't actually know. From what I have heard, zadig might not even be necessary to install the driver? But I am unsure
Anyone is free to make and sell them. I have not thought about doing an actual authorized seller list. Do you think it's beneficial? |
I found that using a right-angle cable solves the problem. Im selling cables with RFI clips on my website for the AIOCs. I also have extra connector options, notes, driver instructions, optional heat-shrink wrapping, and accessories on the site. I'd say an authorized seller would be beneficial. That way the buyer knows:
Also
|
After further testing of this firmware I'd say the automatic ptt is ready for action. Customers agree. As far as a CLI to change between the two modes of operation, while that'd be super helpful, I'd say it isn't a must since the command to switch firmware versions is just one line of simple code with dfu-util. However, the hardcoded 10ms time-out could be restrictive in some environments, for example morse code operation. Having some way to configure that is definitely a must-have feature. However, if you're tight on time you could have it as hacky as you want. For example, you could create an individual version of the firmware for 10ms, 20ms, 60ms, 100ms, 200ms, and 300ms. Yeah, it's hacky and kind of stupid, but it works, and I've learned that shipping something is what's most important. I'm still working on a Windows TUI that switches between firmware versions, so that could act as a config console for you basically. Alternatively, some hacky command to change it would also be fine because again a simple program can run that command for the user. Finally, Having support for a physical switch of some kind to switch firmware, or a potentiometer to change timeout would also be powerful. Just a few of my thoughts. Let me know what you think! |
That's quite curious, I would not have guessed this to be a radiated EMI problem (99% of EMI problems are conducted EMI in practice e.g. what I have described above). Good information that an angled cable might help. This could be something for a "known issues" or similar section in the README.
I'll take that into consideration. Since I am not interested in turning this thing into a "commercial product first - open-source tinkerability second" (truSDX.. cough), I want to keep this kind of advertisement limited. But a list of trusted vendors in the README might be a good idea. I (as the maintainer) would rather like to see the project grow naturally than have a lot of "sales", but being able to buy this thing easily of course helps.
That sounds good! Out of curiosity, what was the size of group of people testing the feature and with what software? So far I did not receive any feedback from someone else, so I am not so keen on pushing this feature out, yet. Maybe as a preview firmware. You did say in the pull-request, that programming the radio didn't work. Is that so? Should not be an issue, just the COM PTT (and CM108 PTT) is disabled, and virtual PTT is enabled. (Basically via a pre-processor directive)
Nah, that's a lot of work and a big mess. If I, at some point, would like to add another distinction, the number of firmwares I need to generate go up exponentially. I have made some provisions to use vendor calls on the HID endpoint for sending or receiving some small data blocks to/from the AIOC. For linux based operating systems, connecting to this endpoint should be no problem at all. I don't know yet, how difficult this would be on Windows. I assume, the AIOC HID endpoint is listed in the Device Manager as a real HID device? Can you confirm? In that case, maybe it's quite easy to send HID messages to this endpoint from a python script. (I am thinking I am not a ham myself, so I am unsure how important manual PTT (i.e. COM PTT or CM108 PTT) is for people, or whether virtual PTT is universally a good idea for everyone (or at least 99%). I am currently thinking of doing to following steps
For a product, that's true. This is, so far, just a hobby project ;-)
Sounds nice, let me know if I can have a look at it somewhere.
Thanks for all the input, I will think about it! |
I created a new issue regarding the configuration interface. Your help is appreciated! |
Happy I've been able to help out! I think in this case the Vox functionality will be what many people will want, but the manual ptt is still very useful. Some modes play much better with manual ptt. One extreme example is Morse code, where you want to just leave the ptt on while sending out morse instead of constantly triggering ptt. Neither is a winner over the other, they're both very useful for very different use cases. Quickly being able to switch modes would be powerful. Have not tested programming, I will. Will also test the HID stuff in Device Manager. One great thing is that as a programming cable your chips work much better than the current commercial options. Theyre a mess with drivers and outdated support. AIOC just plugs in and works. I do have one user where whenever he connects his AIOC with the vox firmware to any android device, the device lags like crazy and no matter what he does he cant get it to trigger ptt on audio. Works fine on windows / laptops. Working with him more now. As far as test size, probably about 8 users, soon to be more like 15. Only one user with an issue so far, and nothing to report from that one, yet. |
I've thought that a few hundred times. It would be better for two reasons: keep the USB cable away from the antenna and wouldn't put stress on the USB cable going down to the PC. BTW.. I've been silently following these two issues around the auto-PTT. I need to try the new firmware; I'm trying to use the AIOC with Allstar. We're going to deploy about 30 of them around the state to support Skywarn operations. |
So far, only very few people have had problems with this and I am not sure why. In general the coaxial cable should not have any current running on the outside of the shield, thus the proximity to the USB cable should not be a problem. If it is s problem, your antenna is not working/behaving correctly anyway, so you should fix that issue first. Having said that, I know that in (amateur) radio you are very often satisfied with a non optimal antenna solution (such as a monopole on a galvanically isolated ungrounded HT. I am think if it's possible to flip the layout without much effort to realize a reverse-k1-aioc. Gotta test this.
That is really cool! You can try the beta firmware hidden in the issue and report any problems you encounter. I am especially interested in your feedback of the virtual COS. As far as I can tell as an outsider, Allstar is where you need something like this. In the future, these functionalities will be integrated in the main firmware and activated and configured (e.g. virtual-COS threshold) using a separate python application. |
You're assuming there is a coaxial cable. In my testing, this issue only occurs when using an antenna on the HT (like the included rubber ducky), not an external one attached over a coax cable. When using an external antenna up in a tree or something like that there was no issue. The AIOC is super compact, making it very attractive for on-the-go HT-based operations. |
I want to test the auto ptt / auto cos with a Alinco mobile radio and Allstar. Any suggestions for connections? The DB9 "data" connector on the radio offers a COR signal that is active-low and requires a pull-up. It has both 9600 baud and 1200 baud audio inputs and outputs and PTT input that is active-low. Here's the connections I think I need: DB9 pin 4 audio output connect to AIOC Radio-Spk line. DB9 pin 7 radio PTT connect to AIOC PTT1 (or PTT2?), why is PTT2 listed twice on the schematic? DB9 pin 9 microphone input connect to AIOC Radio-Mic. In Allstar I would use the usbradio module? Any hints on settings? |
@gordonthree - that doesnt sound related to this issue on interfence. I'd start a new issue. |
Is the firmware linked here: https://github.com/skuep/AIOC/files/11524529/aioc-fw-1.2.0-autopttcos.zip The latest firmware with a software VOX enabled? Apologies if it's a dumb question, it's not appartent to me if a 'live' version is in the main git repository. |
Yes, that is the current testing version still 🙂 |
Regarding Auto-COS, you may want to consider the SIGLEV approach that svxlink employs. Basically you leave the squelch open and listen to the noise. If it suddenly gets quieter you assume there is a signal. To quote from their man page:
This works surprisingly well compared to just trying to detect voice. You have the added benefit of triggering easily when there is no voice, just carrier, and not missing the first syllable because the squelch (Auto-COS in our case) was slow to open. |
I just pre-released the new v1.3.0 firmware that contains a lot of new features, such as Auto-PTT and Auto-COS. It has to be enabled using some python scripting (for now, that is). |
Name it CAPTTain -- CAtless PTTalkin Kidding. ;) But: This virtual auto PTT thingy is a must have. So we can use this APPs: https://play.google.com/store/apps/developer?id=aicodix+GmbH&hl=en_US With an OTG cable AIOC device should work as a external soundcard for Android smartphone. So CAPTTain -- uhm -- virtual auto vox PTT should work. Or am I wrong here? Thank you very much for your work! de DO7OO |
:-)
Yeah, pretty much correct. The AIOC should work as a soundcard for your Android phone. I tried it with APRSdroid and it worked, others tried and had mixed results (there are some issues open for this stuff, but it is really hard to debug the problem). You can try the old testing firmware above or use the v1.3.0-rc.1. However this firmware requires some python magic to select the virtual PTT and store it back to the AIOC. If there is enough interest in trying this out, I can help with that. |
I would like to try the new 1.3.0rc1 firmware, but I do not know how to configure it for my purpose. I would like to try it with my Anytone and AprsDroid on the Samsung A32. Can you tell me how to configure the script to switch AutoPTT on? |
in an ideal symmetric antenna this is correct, but in real world no antenna is exactly symmetric and there are always more or less sheath waves. (a common mode filter after the antenna should block them) |
You can find a generic script in the v1.3.0-rc.1 Release page on Github.
You need to install the |
Hello Simon, Traceback (most recent call last): The "hid" package is working. With another script i got the infos from the AIOC. Thx for feedback. Martin |
Thanks for testing.. this looks like you're the first one on Windows to try this. From a quick search the problem is, that Windows is really strict about the HID reports. I think the AIOC firmware currently does not list the "feature reports" (that are used for transferring configuration data) in its own HID report descriptor. Which windows notices as soon as you try to request a feature report and blocks you from doing so. Interesting, it appears that Linux doesn't care about this 😁 I will try to update the firmware in the near future and release an RC.2 version. |
Thank you for your feedback and the adapted new FW in the near future. happy easter |
Can you have a quick test of this new firmware? I added an entry in the report descriptors, but I am not entirely sure if Windows is satisfied with this. If not, I need to spin up a Windows machine and dig deeper. Happy easter holidays! ;-) |
Will test asap today evening. |
Hi Simon, unfortunately the test was negative. Same output. Traceback (most recent call last): Regards Martin |
It's not the same error 😁 it's now "wrong Parameter" but it looks like I have to be more specific with the descriptor.. I will set up a Windows station and need to play around a bit. In the meantime you could use the virtual PTT test firmware I posted earlier in this issue. |
Tested that virtual PTT test firmware but without success. Maybe i toke the wrong one? martin |
Hello Simon, any further update for us? |
Sorry for the late reply, I am currently swamped with work. What does "without success" mean? No PTT action? Which one did you use? This should be the correct one, if I am not mistaken: |
Hi Simon, Work comes first, clearly. Thank you here for your commitment. "without success" mean? No PTT action? YES. I will try the linked one and report back to you. Many thanks martin |
Update: |
That's cool! Now I got to work on making the new firmware work on Windows so that you can also configure the thresholds for Auto PTT 😁 |
Back into the swing of things for this project again. Once you have an updated Windows and linux script let me know, happy to test on both. Obviously when work, allows the extra time! :D |
hi Simon, |
I'm waiting for my AIOC module shipping from shenzhen. In this while, I wonder if anyone tried to use AIOC to made FT8 possible by using FT8CN and Quansheng-UV-K5 ? |
@ITCMD that's exaxtly what I wrote in my comment: :-) |
Would it be possible to still allow serial control over PTT while running in automatic firmware, or alternatively allowing it to at least control PTT2? I notice the light comes on but it does not key up from serial. |
@ITCMD sorry for the late reply.. you can theoretically select multiple sources for the PTT signal, such as Auto PTT and serial. All enables sources will be logically or'ed. You need to set up the aioc configuration using the script. |
Referencing comment #11 (comment)_
The idea is to implement AIOC-based "Auto-PTT", which is basically a fancy VOX feature for digital modes, with very low latency.
Ideas/comments/feature welcome!
EDIT: Branching off of issue #17
The "plan" from #17 (comment):
The text was updated successfully, but these errors were encountered: