Hla spi

Hello all,

I’m trying to write a custom HLA for TFT displays using SPI as the LLA. I’ve already managed to identify some commands sent to the display. Nevertheless I don’t know how to check the status of the line “Data/Command” that is not part of SPI. Any guides on this regard?

on a different topic, following this tutorial: High-Level Analyzer (HLA) Extensions - Saleae Support
I see a different output on the analyzer bubbles text than expected.

With the following code:

result_types = {
‘match’: {
‘format’: ‘{{data.command}}’
}
}

                    return AnalyzerFrame('match', frame.start_time, frame.end_time, {"command": COMMANDS[ch]} )

I expected only the command name, for example “MADCTL”:
but I get “match(command=MADCTL)”

is it possible to get the expected output?

looking forward your reply,
Best regards, Mauro.

@maurosmartins Sorry for the late reply! We’re just returning from the holidays now. For your question below:

Nevertheless I don’t know how to check the status of the line “Data/Command” that is not part of SPI. Any guides on this regard?

Can you let me know a little more about the “Data/Command” line? Our HLAs are limited to working with the frames that the underlying LLA produces. It unfortunately doesn’t have the ability to check the status of channels that are not attached to the LLA.

For your question on the analyzer bubble text output, I’ll review it with the team here and will follow up with you.

Sorry for jumping in here.

There are lots of SPI based displays like: ILI9341, ILI9488, ST7735, ST7789, … That use a D/C pin as part of their communications, that use this pin like logically an SPI 9 bit communications, where the pin (or 9th bit) signifies if the byte is a command or data bytes associated with the pin. For example from the ILI9341 manual:

Hello @timreyes,

thank you for your reply, I’ll be waiting for the comments on the analyzer bubble.

regarding previous question, as @KurtE explained (thank you), the “Data/Command” line is an extra line that tells the display if current information on SPI is Data or a command. Can’t the raw status of all channels be checked when running the “decode” function?

looking forward your reply,
Best regards, Mauro.

@KurtE Thanks for jumping in! The image helped a ton. It makes sense now.

@maurosmartins To my best knowledge, the raw status of any channel cannot be checked by HLAs. In addition to your other question about the analyzer bubble, I’m going to double check this with the team here to see if they know of a workaround.

Apologies in advance as I most likely won’t be able to review this with the team until early next week due to the New Year holidays coming up. I’ll follow up again once I’ve had a chance to discuss this with them.

We don’t have a way to read the raw digital states in the python HLA API at this time.

This is something we want to fix! If you have a moment, we would appreciate if you add your interested to the feature suggestion here: High-level analyzer: combine data from multiple sources - Logic 2 - Ideas and Feature Requests - Saleae. Any use case information you can add in the comments would be great too.

In the meantime, you would need to modify the C++ SPI analyzer to include the extra channel, and to indicate the channel state in the FrameV2 object that’s passed up into the HLA.

We’re in the process of making the C++ FrameV2 API public right now, however it can be used to day simply by looking at the existing SPI analyzer source code, which is already using the new API feature: GitHub - saleae/spi-analyzer at alpha

Unfortunately, this is a good bit more complicated than just adding a few extra lines of code to your python HLA. We’re focused on analog features at the moment, and unfortunately won’t be back on extension development for a while. (Our SW team is 3 developers)

1 Like

Sounds like an interesting approach, which I have thought of wanting for awhile, who knows maybe at some point will take a look. Wonder how common it is for devices to use this… As I mentioned earlier have seen it on many displays.