Skip to content
This repository was archived by the owner on Jan 28, 2021. It is now read-only.

Just an observation: sendCommand will always timeout with custom ubxPackets #23

Closed
PaulZC opened this issue Jun 22, 2019 · 3 comments
Closed

Comments

@PaulZC
Copy link
Collaborator

PaulZC commented Jun 22, 2019

Hi,
This is just an observation that will (hopefully) be trumped by multi-valset #20

If you define a custom ubxPacket which holds (e.g.) a UBX-CFG-VALSET message and then send it with sendCommand, it will always timeout as the commandAck checking in processUBXpacket (called from waitForResponse \ checkUblox \ checkUbloxI2C \ process \ processUBX) expects the packet class and ID to be defined in packetCfg, not the custom packet.

The offending line is:
if (msg->id == UBX_ACK_ACK && msg->payload[0] == packetCfg.cls && msg->payload[1] == packetCfg.id)

It would be possible to correct this by passing the requestedClass and requestedID from waitForResponse further down the food chain.

Cheers,
Paul

@nseidle
Copy link
Member

nseidle commented Jun 25, 2019

I see what you mean. If you've got a proposed solution (here or on #20) I'm all ears.

@PaulZC
Copy link
Collaborator Author

PaulZC commented Jul 1, 2019

Strictly this Issue should probably stay open as I haven't actually fixed it with PR #30 but the problem has gone away as the new newCfgValset, addCfgValset and sendCfgValset functions for Issue #20 work on packetCfg and don't require a custom packet.

I propose we close this though as life really is too short!

Thanks!
Paul

nseidle added a commit that referenced this issue Aug 7, 2019
#23)

Updated setVal, added 'multi' setVal and an Example (supersedes #28)
@nseidle nseidle closed this as completed Dec 27, 2019
@PaulZC
Copy link
Collaborator Author

PaulZC commented Apr 22, 2020

Finally resolved once and for all in #97!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants