- Posts: 271
Support for walkera telemetry.
- linux-user
- Offline
I can do, but what could we expect?PhracturedBlue wrote: can you try the build I provided? It really should resolve the issue..
Regardless whether it solves the issue or not, I would never see the "loss of connection", simply because you reset the CYRF from time to time.
We might need some sort of time indicator in the log. (a fast growing log-file may be indication enough)PhracturedBlue wrote: Let's say your Tx loses signal every 100 times that the bad-transmit condition happens. Let's also suppose I report this on serial but do not correct for it.
If you are testing for the right flag, I would expect the following in the log:
First (CYRF recovers by itself from the situation):
- only occasional occurrence of 'bad tx' messages
Later: (CYRF does not recover by itself):
- "infinite" occurrence of 'bad tx' messages
Than we have lost.PhracturedBlue wrote: i.e. there may not be an indicator that means 'we need to reset the CYRF chip now'.
Although, it seems that I am the only one who can reproduce the issue, this post from cmpang indicates that this issue is not unique.PhracturedBlue wrote: Also, recall that noone but you can actually duplicate the problem so far.
BTW:
If, what you are testing for, is an illegal CYRF state, that you think should never occur than you have actually reproduced a problem.
Edit:
I will test your build anyway.
Edit 2: It is running, let us see what it does.
Please Log in or Create an account to join the conversation.
- PhracturedBlue
- Offline
- Posts: 4402
If you are right, it will write out a large number of messages if the tx gets LOS. If that is the case, you really want to get the serial port working before testing.
I'm going to merge the reset code into the trunk though, since we've shown it doesn't cause any issues.
Please Log in or Create an account to join the conversation.
- vlad_vy
- Offline
- Posts: 3333
vlad_vy wrote: The more and more I think it is a hardware problem. Now I run long time test for Devo protocol with telemetry enabled:
Hardware: Devo 12s without any mods, RX1202, WK-CTL01-D telemetry module, Walkera GPS sensor, elevator servo. All powered permanently.
Software: nightly build with some changes: www.deviationtx.com/forum/protocol-devel...etry?start=240#30974 or PB test build www.deviationtx.com/downloads-new/catego...o-fixes-for-devo-dsm
Test results:
Day 1, 24 hours = still connected
Day 2, 48 hours = still connected
Day 3, 72 hours = still connected
Day 4, 96 hours = still connected
Day 5, 120 hours = still connected
Day 6, ....
be continued...
Test do nothing for 'connection lost' issue, but can demonstrate code stability. Next I will continue the test with linux-user method. Devo 12s powered on from beginning to end..
Please Log in or Create an account to join the conversation.
- PhracturedBlue
- Offline
- Posts: 4402
I was not previously trying to imply this issue should not be fixed, just that at some time we're going to get to the point where the current testing methods are not sufficient to determine if the issue is fixed, and that more advanced testing methods are hard to test given that not all hardware can reproduce the issue.
I should add, that from what I've seen, an always on test (by linux-user) should behave exactly like his mostly-off case. The tx seems to get stuck such that it does not transmit packets, and that will have little or nothing to do with whether it received a telemetry response. Because it can take many hours to trigger the issue, it is hard to evaluate one testing method against another. This one has been ood enough to get us this far at least.
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
the test build from PB has been running now for 16.5h without a single 'Rst CYRF' message or "loss of connection" event.
I need to interrupt this now for some flying.
I will try another test run this evening.
Telemetry values are often inverted. I know this is not to be tested here, but may be related in preventing to trigger my issue.
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
I remember reports, that early releases of original Walkera Devo10 FW could have this issuePhracturedBlue wrote: I dunno if anyone has tested the stock firmware, but I'll bet it does not have the same LOS we have in Deviation.
Please Log in or Create an account to join the conversation.
- vlad_vy
- Offline
- Posts: 3333
} else {
//int reg = CYRF_ReadRegister(0x07);
//if ((reg & 0x23) == 0x22)
if(CYRF_ReadRegister(0x07) & 0x20) { // this won't be true in emulator so we need to simulate it somehow
CYRF_ReadDataPacket(packet);
parse_telemetry_packet(packet);
delay = 100 * (16 - txState);
txState = 15;
}
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
Second test run for another 14h:linux-user wrote: Hi,
the test build from PB has been running now for 16.5h without a single 'Rst CYRF' message or "loss of connection" event.
- hit 'Rst CYRF' 3 times within 5h
- connection to RX still possible
Now I will try PB's "DEVO Telemetry LOS fix" build without reset CYRF and see what it does.
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
- Got lots of "128 CYRF bf bf000000" messages. ~15 per second on serial, right from the first occurrence.
- And, LOS
Exactly as expected
Please Log in or Create an account to join the conversation.
- PhracturedBlue
- Offline
- Posts: 4402
I think we still need Indigo's telemetry changes though?
Please Log in or Create an account to join the conversation.
- vlad_vy
- Offline
- Posts: 3333
Please Log in or Create an account to join the conversation.
- PhracturedBlue
- Offline
- Posts: 4402
Please Log in or Create an account to join the conversation.
- vlad_vy
- Offline
- Posts: 3333
www.deviationtx.com/forum/protocol-devel...etry?start=240#30974
Please Log in or Create an account to join the conversation.
- Indigo
- Offline
- Posts: 230
The fix is including TXBERR (Buffer Error) as a reason to exit the WAIT_LOOP.
while (! tx_state && ++i < NUM_WAIT_LOOPS) {
- tx_state |= (CYRF_ReadRegister(CYRF_04_TX_IRQ_STATUS) & 0x02);
+ tx_state |= (CYRF_ReadRegister(CYRF_04_TX_IRQ_STATUS) & 0x06);
TXBERR is cleared by setting the TX CLR bit (0x40) in TX_CTRL_ADR, which is all ready being done.
void CYRF_WriteDataPacketLen(const u8 dpbuffer[], u8 len)
{
CYRF_WriteRegister(CYRF_01_TX_LENGTH, len);
CYRF_WriteRegister(CYRF_02_TX_CTRL, 0x40);
WriteRegisterMulti(CYRF_20_TX_BUFFER, dpbuffer, len);
CYRF_WriteRegister(CYRF_02_TX_CTRL, 0xBF);
}
This additional reason to exit the WAIT_LOOP was already being done in J6_Pro protocol:
case J6PRO_BIND_03_START:
{
int i = 0;
while (! (CYRF_ReadRegister(0x04) & 0x06))
if(++i > NUM_WAIT_LOOPS)
break;
}
I would like linux-user and cmpang to test version bb10550 I've uploaded to Test Builds to see if this does indeed fix LOC.
Please Log in or Create an account to join the conversation.
- Indigo
- Offline
- Posts: 230
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
Not working with Devo! (DSMX seems to work)Indigo wrote: I've re-uploaded test version bb10550 with CYRF Reset fix and debug logging included into the build.
- feels like one frame were sent every 5sec
- telemetry stays inverted
edit: with telemetry OFF it seems to work.
Please Log in or Create an account to join the conversation.
- Indigo
- Offline
- Posts: 230
Please try new version 55d20bd.
Please Log in or Create an account to join the conversation.
- linux-user
- Offline
- Posts: 271
But no debug page.
Does this include the CYRF-reset from PB?
Please Log in or Create an account to join the conversation.
- Indigo
- Offline
- Posts: 230
I don't know why no debug page.
Please Log in or Create an account to join the conversation.
- PhracturedBlue
- Offline
- Posts: 4402
Please Log in or Create an account to join the conversation.
- Home
- Forum
- Development
- Protocol Development
- Support for walkera telemetry.