Author Topic: HP3548 / HP3457 OLED display  (Read 49632 times)

0 Members and 3 Guests are viewing this topic.

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #225 on: February 06, 2025, 03:30:25 am »
I'm not sure if it helps but I played a bit with the oled_clear() function and I changed pari2c_writebyte_bc(0x00); to pari2c_writebyte_bc(0xd5); just to see where it writes. I've also changed the number of iterations from for (uint8_t i=0; i<128; i++) to for (uint8_t i=0; i<2; i++) to see what happens. The conclusion is that it does not increment the page, it always increment the segment number. Please see below.

Code: [Select]
void oled_clear(void)
{
//ssd1306_set_region(0, 3, 0, 127);
ch1115_set_location(0, 0);

pari2c_start();
pari2c_writebyte_bc(OLED_SLADDR);
pari2c_writebyte_bc(0x40);
for (uint8_t i=0; i<128; i++)
{
pari2c_writebyte_bc(0xd5);
pari2c_writebyte_bc(0xd5);
pari2c_writebyte_bc(0xd5);
pari2c_writebyte_bc(0xd5);
}

pari2c_stop();

}

Edit: The set_location function doesn’t work. No matter if I change x or y, nothing changes on the screen.
« Last Edit: February 06, 2025, 03:59:37 am by Miti »
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #226 on: February 06, 2025, 06:23:58 am »
We have to take inspiration from this file.
That one is made however for a different display resolution, but the same controller.
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Offline Kean

  • Supporter
  • ****
  • Posts: 2651
  • Country: au
  • Embedded systems & IT consultant
    • Kean Electronics
Re: HP3548 / HP3457 OLED display
« Reply #227 on: February 06, 2025, 06:35:39 am »
I wonder why the flickering. Is the data input from the meter connected? Can you disconnect it? It shouldn’t matter though because it should ignore the RAM content in this state.

Yes, it was connected to the meter.  All reverted and packed away now though as the bench is now taken up with a client job.  But Terra's response that he didn't see flickering is good.

I am getting corrupt SELF TEST OK message at startup, as some others mentioned.  Changing various fuse settings didn't help, so I suspect my alternate choice of switching PSU components (from stock) are a bit slow to start up.  I might reduce the bulk capacitor as the ones I had in stock are a bit large in size (Wurth E case 100uF 35V).

FWIW, my OLED's have the following written on the back:

L2832TSWV
P2413077-11-A***

This is the same as the 60 pcs I bought.

Interesting that you saw nearly 200mA draw on the 8V supply with all pixels lit on 12 displays.  That is about 1.6W, when I only measured 800mW when using the 13V unregulated input...
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #228 on: February 06, 2025, 08:28:50 am »
Hi Miti,

I found out that the CH1115 seems to require that you send always 0x80 before a command. This was not done correctly, thus the function could not have worked properly indeed as you reported.

That part is fixed in the attached one. I also adjusted the oled_clear based on the fact that the increment at the end of one page to the next page seems not to happen as it does for SSD1336 displays.

So you should see some changes now.

I did not adjust the touch sequence in the oled.c, But (and a big one):
I think your init code is not taking care of that 0x80 value. I'd suggest to look into the .txt file I shared in my previous post and see if you can take that init sequence and adjust it to your resolution.

Crossing fingers,

Kai
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 
The following users thanked this post: Kean

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #229 on: February 06, 2025, 01:27:42 pm »
Nope, the same page over and over again. I modified the init sequence as well with control byte before every command, nope. I think this chip is a POS that is advertised as compatible with SSD1306, but is not, and is not properly documented. I may cut my losses, and save your time, and buy whatever Kean bought.
Before that, I may try some of the functions in that .txt file, just to see if I can get it to show anything.

Cheers,
Miti

Edit: I'm not sure about that 0x80 control byte before every command. If you look in the oled data sheet from LCSC, there's a sample code that doesn't have that. It may be just the wrong understanding of the programmer who wrote that code. But, there are differences between his init sequence and mine, I'll compare tonight.
« Last Edit: February 06, 2025, 01:44:55 pm by Miti »
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #230 on: February 06, 2025, 04:41:48 pm »
Hmm, the lcsc datasheet does also not state that it's a ch1115 controller.
But yeah, I think also best is to just buy the right display.

Did you spot criterias to detect that "bad" display?
« Last Edit: February 06, 2025, 04:52:19 pm by Xyphro »
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #231 on: February 06, 2025, 05:02:53 pm »
Hmm, the lcsc datasheet does also not state that it's a ch1115 controller.
But yeah, I think also best is to just buy the right display.

Did you spot criterias to detect that "bad" display?

Yes it does, page 5, by the drawings, bottom right corner, page12 top of the page.
I don’t think they are defective, it’s just hard to understand how to control them.
Fear does not stop death, it stops life.
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #232 on: February 07, 2025, 02:01:05 am »
Am I an engineer or what?  ;D

Edit: A big "Thank you" to Xyphro, he coded the new functions, I just corrected one thing that was missing and adjusted the init sequence.
« Last Edit: February 07, 2025, 02:26:22 am by Miti »
Fear does not stop death, it stops life.
 
The following users thanked this post: robert.rozee

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #233 on: February 07, 2025, 03:49:23 am »
Mirroring the characters wasn't too hard but the annunciators are displayed vertically and every time an annunciator is displayed, it starts scrolling.
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #234 on: February 07, 2025, 06:18:56 am »
Wow great, you got into the 5 minutes of dopamine rush after x hours of hard engineering work, that we engineers all love :-)

Will check your code. It seems to get a scroll command somehow.

Update: no scroll conmand, but also no mirroing. Just the oage adrresses have to be set.
« Last Edit: February 07, 2025, 09:18:14 am by Xyphro »
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #235 on: February 07, 2025, 08:30:10 am »

Check this file. I have put the same method in there for the annuciators as for the digits. It is based on the latest oled.c that you shared. I did not throw this thing through the compiler yet, so typos might be there.

It seems that Display has 2 I2C addresses. 0x80 (which is 0x40 in 7-bit format) for sending commands and 0x3f for sending data? Don't get that full concept yet on how it differentiates between commands and data in i2c mode.
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Offline Kean

  • Supporter
  • ****
  • Posts: 2651
  • Country: au
  • Embedded systems & IT consultant
    • Kean Electronics
Re: HP3548 / HP3457 OLED display
« Reply #236 on: February 07, 2025, 09:00:12 am »
Am I an engineer or what?  ;D

Edit: A big "Thank you" to Xyphro, he coded the new functions, I just corrected one thing that was missing and adjusted the init sequence.

Yay, well done!
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #237 on: February 07, 2025, 11:33:42 am »
Check this file. I have put the same method in there for the annuciators as for the digits. It is based on the latest oled.c that you shared. I did not throw this thing through the compiler yet, so typos might be there.

Thanks, I'll give it a try soon.

It seems that Display has 2 I2C addresses. 0x80 (which is 0x40 in 7-bit format) for sending commands and 0x3f for sending data? Don't get that full concept yet on how it differentiates between commands and data in i2c mode.

Yes, A0, which in I2C mode is called SA0, is part of the slave address, same as SSD1306.
BTW, it does not need 0x80 before each command. The sequence of commands from the data sheet works, with the slave address followed by one 0x00, and with with the correct parameters, of course.
Fear does not stop death, it stops life.
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #238 on: February 07, 2025, 12:06:59 pm »
Ha ha, bull's-eye! Thanks Kai! I've also selected the correct annunciators.
Two things I observed:
1. It does not show the annunciators when pressing SHIFT -> RESET, as mentioned by TERRA.
2. It does not clear the annunciators, at least SHIFT, after the reset. Is the reset a HW reset which this design cannot catch?

Edit: And no more scrolling.
« Last Edit: February 07, 2025, 12:46:24 pm by Miti »
Fear does not stop death, it stops life.
 
The following users thanked this post: TERRA Operative

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #239 on: February 07, 2025, 12:17:47 pm »
Are those 2 issues a general issue, or newly introduced by rhe changes?
Just want to see where to put my search-scope!
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #240 on: February 07, 2025, 12:30:22 pm »
Yes, the 0x80 is just the "command slave address". I did not interpret the .txt file correctly.
So yes and no. It has to be sent, but not as data value, but as slave address at the end.

Happy that it works now for you. Gives me also a small adrenaline kick, though a smaller one than experiencing it myself :-D
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #241 on: February 07, 2025, 12:52:06 pm »
Are those 2 issues a general issue, or newly introduced by rhe changes?
Just want to see where to put my search-scope!

I don't think they are new, at least not showing the annunciators after reset was seen before with the original code by other members.
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #242 on: February 07, 2025, 12:56:36 pm »
I checked it once with my 3457a:
https://youtu.be/VUZxWYohl38?si=Zg9qbPTjzVtnXP-2

It turns all annuciators on and also clears shift.

Could it be hp3458 specific?

In case you have some logic analyzer capturing all signals like this would be grear:
Precobdition: ensure the display does not continously change its content, e.g. select manual trigger
Start capturing press shift then reset
« Last Edit: February 07, 2025, 01:04:03 pm by Xyphro »
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #243 on: February 07, 2025, 02:05:02 pm »
Sorry, no logic analizez on this side of the pond.  ;D
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #244 on: February 07, 2025, 02:06:15 pm »

In case another user has one and also that issue, letme know :-)
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #245 on: February 07, 2025, 02:41:15 pm »
I could use the scope. It is SPI , isn’t it? Rigol can decode SPI.
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #246 on: February 07, 2025, 04:16:45 pm »
It's not spi unfortunately. Capturing it with a scope might not be easy cause it cannot capture many muliple seconds at high samplerates :-(
You can give it a try, maybe it works, but it can end up in frustrations. Exporting a waveform as csv or so would enable me to decode.

Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #247 on: February 07, 2025, 04:52:17 pm »
@Terra, do you maybe have a logic analyzer to capture a shift->reset sequence of your device by capturing all data lines with it?

Just to understand why e.g. the shift annuciator does not clear.
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 

Online Miti

  • Super Contributor
  • ***
  • Posts: 1530
  • Country: ca
Re: HP3548 / HP3457 OLED display
« Reply #248 on: February 07, 2025, 05:52:57 pm »
I suspect that, rather than updating the annunciators, there’s a special command that reset the front panel and you don’t have it in your list. However, the digits are updated.  :-//
Fear does not stop death, it stops life.
 

Offline XyphroTopic starter

  • Regular Contributor
  • *
  • Posts: 191
  • Country: de
Re: HP3548 / HP3457 OLED display
« Reply #249 on: February 07, 2025, 05:58:05 pm »
Me too, that's exactly why I look for a logic analyzer trace to get to know that cmd.
My hp3547 seems to behave as expected and I did not see unhandled commands during development. It is very well possible that there is even a bigger set of commands which is missing for full compatibility.
« Last Edit: February 07, 2025, 05:59:46 pm by Xyphro »
Looking for a unique, cheap versatile USB to GPIB adapter with standard USBTMC interface? Build it yourself :-) https://github.com/xyphro/UsbGpib
Interested in I3C protocol? Check this out: https://github.com/I3CBlaster
https://github.com/xyphro/XyphroLabs-I3C-Saleae-Protocol-Analyzer
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf