-
-
Notifications
You must be signed in to change notification settings - Fork 745
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for SEQURE S99, and new Rev. of S60P #1920
base: dev
Are you sure you want to change the base?
Conversation
Co-authored-by: discip <53649486+discip@users.noreply.github.com>
Co-authored-by: discip <53649486+discip@users.noreply.github.com>
Hia, This is great progress. The black screen at startup is odd. PD negotiation shouldn't block boot. Is it possible its being restarted rapidly with flaky USB-PD? (Do you have any tools for debugging USB-PD)? I haven't really worked on the |
Hey, yeah. It seems to restart rapidly. It seems to be especially with the Apple Chargers. Another charger I tried let the iron boot straight up. Sadly I don't have special USB-PD tools. Maybe I need to get something or build something to hook a logic analyzer on? As I could see with the debug menu, when it comes up it gets all available PD modes, but stays in 5V mode. I think I need to take a look at the measurement of the tip for the power calculation? Maybe you can give me a hint on that? |
@Ralim I'm currently digging a bit through the code and debug outputs of the iron. I wondered why it reports Regarding the PD negotation problem with my Apple 60W USB-C PSUs I tried to increase the PROTOCOL_TIMEOUT to 200 ms, which helped. The Iron boots instantly. PD Debug First Shows I hope I can make some progress tomorrow. |
Ah heck, yes that will fix the issue
|
@Ralim It's a bit unclear to me. In the Settings.cpp
How did you determined the value for the OP_AMP_GAIN_STAGE? |
Ah sorry, I think we raised the default later on.
In the S60, its two sequential op-amps chained. Input op-amp has feedback resistors of 9.31K and 1K. (therefore gain is 10.31) So 10.31 * 50 = 536.12; so the define is set to 536 |
* Enable PD Options * Make PDNegTimeout configureable * Add default value for PDNegTimeout, also for S60 and S60P * Add basic DC detection / correct debug readings while powered via DC * Add basic ThermoModel for C245 Tips * Modify op-amp gain
bool getIsPoweredByDCIN() { return false; } | ||
bool getIsPoweredByDCIN() { | ||
#if POW_PD_EXT == 2 && defined(POW_DC) | ||
if (!FS2711::has_run_selection()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍🏼
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems sane to me at a read.
Let me know when you are happy with this by marking it ready for review 🙇🏼 |
Nice! |
I compared the temperature at a setpoint of 320°C to a original JBC station. In my eyes the coefficient is okay for a first shot. Then I observed that the name and description for PDNegTimeout and USBPDMode are not shown in the menu. I quite don't get it. The menu Item is here I got a second S99 which is V1.5 instead of V1.4, it seems that they changed something. Although a FS2711 is used, it does not negotiate PD. I quickly took two picutes: |
@Ralim, I tried your increased pwm speed. Works great on the S99! No more restarts, even with power limit set to 60W on a 60W USB-C charger. What I got so far regarding v1.5
|
Works on my (v1.1 PCB) S60P with a steamdeck charger and a lenovo 65W charger |
@discip What charger are you using? Ill try this locally |
@Ralim |
https://github.com/jonasius/IronOS/actions/runs/10709046785/job/29692775793 Works on my new S99 (PCB v1.5) with a 65W charger |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As already mentioned, in the current state this unfortunately does not work for the S60P
.
To move on I'm planning to create a few versions for you to test. Maybe the initialization of i2c1 or the probing isn't working properly on your hw rev. |
@discip If the fw in Hexfile_noI2C1.zip isn't working on your S60P, that would indicate a problem with the I2C-probing on I2C2. |
After flashing Hexfile_noI2C1.zip the OLED stayed off. After flashing Hexfile_noI2C1_noprobing.zip @Ralim |
PD Debug State 1 means that the I2C communication with the PD-IC is working. That should be the same behavior as with the current dev branch. The OLED off with the version with probing means that the probing on I2C2 fails. I'll think about how we could further investigate on that. |
Hmm; PPS evaluation could be involved, it would be my rough guess as its probably the pain part of the protocol. Is it possible to disable PPS for testing? |
@Ralim But for testing purposes this could be disabled. |
@discip I've quickly put together a fw which shows the i2c devices it can find on startup instead of the usb-pd menu. Maybe you could flash it and enter the usb-pd debug menu. It should show numbers on the left and right side of the screen. |
@jonasius Here are the numbers:
|
@discip okay, thats good, 90 is there as expected. |
@jonasius
s60p_probing_delay_startwith90.zip
|
@discip |
@jonasius
|
@discip that version should be able to communicate with the pd-ic. I'm not happy with the solution. Maybe one probe before the real probing should be enough. |
@jonasius Unfortunately now is says:
allowing only 5.2 V |
@discip just for clarification. The latest build of dev branch negotiates with 12V?! |
Sorry, I'm not able to follow here. What exactly is this supposed to tell me? 😊 |
Sorry. |
@jonasius
Nothing else (There is no option I can go through like e.g. with the Pinecil). And it negotiates for |
Just tested on my new S99 after my Pinecil V1 USB PD decided to die on me, seems to work decently. Haven't tested a lot, though. Thanks a lot for your work! I'll see if I can RE the schematics of it, to be able to properly fix it in case. |
|
||
#ifdef I2C_SOFT_BUS_1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why insert a check here? The names of the entities are different anyway.
(SOFT_SCL1_HIGH
and SOFT_SCL2_HIGH
respectively)
What is the new behavior (if this is a feature change)?
IronOS booting on Sequre S99
Other information:
Currently work in progress.
Problems / Todo
State 0 0 21
multiple times, with blinking/resetting screen, after a while showingState 4 1 21
.OP_AMP_GAIN_STAGE 536
needs to be adjusted according to the 22k resistor instead of 51ksource/Code/BSP/Sequre_S60
folder should be renamed toSequre
?