Still active?
scd31 opened this issue · comments
Is this project active? I'd like to submit 2 PRs and am wondering of they would be accepted.
- Migrate from libfap to the aprs-parser crate - mainly so that message packets are supported
- Allow sending packets. I'm thinking this would be done by having the callback function return a vec of packets, which would be sent(empty vec if there's nothing to send)
Yes it's still active. I've looked at aprs-parser in the past - I think that it fails with some packets as it expects them to be valid strings (and aprs packets aren't always valid strings). I've been wondering about switching the parser though; are those packets ones I really care about, and if so how hard it would be to fix that in aprs-parser?
As for sending packets - yes, would love to have this functionality. I think the callback approach should work while also being quite simple.
Interesting. What would an APRS packet look like that's not a valid string?
Getting late here in the UK so a proper investigation will have to wait, but I'm seeing errors a lot with packets containing "ø" (at least that's what aprsdirect thinks is in the packets at that point).
You can have a look yourself by modifying the example code to do this when a parsed packed is matched:
match String::from_utf8(packet.raw) {
Ok(msg) => (),
Err(err) => println!("Error converting APRS packet to UTF8: {}", err),
}
I was printing out parsed.source before this so I could look them up, but actually it's probably better to convert the raw packet to hex in order to find out what's in there (or just debug and inspect it).
Ok, looked a little bit more - first issue I found was 0xB0 (unicode degree symbol). So I think the problem I would have seen when I looked at using aprs-parser would be that I just converted the bytes to a string with ::from_utf8
and that won't always work. So, I think the problem is in simple-aprs which should make it easier to fix and switch to using aprs-parser.
Now I really am going to log off for the night.
I was able to find some packets with random bytes - in particular, message packets. At minimum I think aprs-parser will need to be updated to support non-string messages. This shouldn't be too difficult though.