Commit Graph

13 Commits

Author SHA1 Message Date
Ben V. Brown
c6918093fb Larger OLED Support (#1713)
* Update header to declare full buffer size

* Strip refactoring

* Refactor the OLED scrolldown part 1

* High res capable scroll down

* Allow button press to skip scroll

* Bunch of Misc Fixups
2023-06-18 22:50:31 +10:00
Ben V. Brown
d3d8e3d2d5 TS101 (#1695)
* Refactor I2C_SOFT to new #define

* Stitch in some of TS101

Update ShowStartupWarnings.cpp

Update OLED.hpp

Update stm32f1xx_hal_msp.c

Update Setup.cpp

Update Power.cpp

Update Pins.h

Update configuration.h

Power Muxing

Working dual input Voltage handler

Scan mode required for differing injected channels

Inject both dc readings

Update configuration.h

Update configuration.h

Use htim4 for adc control on TS101

Refactor htim names

Add ADC_TRIGGER

Speed up BB I2C a lil

Update configuration.h

Update startup_stm32f103t8ux.S

Update configuration.h

Add LIS2DH clone

LIS2DH gains another clone

Create tooling to allow mapping accelerometers onto different buses

Update startup_stm32f103t8ux.S

Ensure PD IRQ is pulled up

* Stitch in some of TS101

Update ShowStartupWarnings.cpp

Update OLED.hpp

Update stm32f1xx_hal_msp.c

Update Setup.cpp

Update Power.cpp

Update Pins.h

Update configuration.h

Power Muxing

Working dual input Voltage handler

Scan mode required for differing injected channels

Inject both dc readings

Update configuration.h

Update configuration.h

Use htim4 for adc control on TS101

Refactor htim names

Add ADC_TRIGGER

Speed up BB I2C a lil

Update configuration.h

Update startup_stm32f103t8ux.S

Update configuration.h

Add LIS2DH clone

LIS2DH gains another clone

Create tooling to allow mapping accelerometers onto different buses

Update startup_stm32f103t8ux.S

Ensure PD IRQ is pulled up

Allow toggle which button enters PD debug

* Update Pins.h

* Fix hard coded IRQ Pin

Update stm32f1xx_it.c

* Enable EPR

* Tip resistance measurement

* TS101 is a direct drive tip

Update BSP.cpp

* Add S60 and TS101 to builds

Update push.yml

* Update MOVThread.cpp

* Refactor power menu handler

* Correct prescaler

Forgot to update since I changed the period

* Tune in the timer divider for tip control to make PWM less audible

---------

Co-authored-by: discip <53649486+discip@users.noreply.github.com>
2023-06-18 21:58:20 +10:00
Ben V. Brown
286afad919 S60 Support (#1692)
* Mock S60

* cleanup

* Start refactor of OLED init

* Setup timers roughly

* Set Vector table offset correctly

Update system_stm32f1xx.c

* Update OLED.cpp

* Update stm32f1xx_hal_msp.c

* Update configuration.h

* I2C init before GPIO

From Errata

Update stm32f1xx_hal_msp.c

Update Software_I2C.h

Allow no hardware I2C

* I2C BB run bus unlock at init

* cleanups

* Software I2C for now

* Mildly more graceful Interpolate

* Handle is powered by DC

Update Power.cpp

Update drawPowerSourceIcon.cpp

Update configuration.h

Update Setup.cpp

* Cleanup HomeScreen

* Segment remap oled at init

* Cleanup

* Update MOVThread.cpp

* Fix PWM Init

* Fix adc2 trigger

* Update configs

* Fixup warning

* Saner default config

* Update ThermoModel.cpp

* Util for current@voltage

* Hub238 warning

* Add hub238 handling in power mode

* Update USBPDDebug_FUSB.cpp

* HUSB238 debug

* Hook PSU Limit

* Use wrapping section of GRAM for scroll

Update OLED.hpp

* Update NTC table

* Fix HUB voltage picker

* Cleanup

* Larger tip filter

* Calibrate in a bunch closer

Update ThermoModel.cpp

* Update configuration.h

* Update HUB238.cpp

* Update configuration.h

* Movement Pin

* Update BSP.cpp

* tim2 irq

* Rough timer conversion (adc broken) but movement working

* Fix tim2 start

* Faster base PWM

* Ensure utils grabs config

* Add wattage limiter tolerance for device

* Speed up PWM and enable PWM current limiting

* tune for 12v

* Prevent start until PD done

* Update configuration.h

* Add HUB238 check for have re-negotiated

* Adjust timer to avoid noise when its possible
2023-06-03 20:05:31 +10:00
discip
a5975b3385 Update Power.cpp 2022-05-04 00:13:46 +02:00
Ben V. Brown
3594604efc Fixes for I2C on Pinecil + USB-PD stack (#1099)
* Remove unused includes

* Adding in submodule

* Move fusb functions to the BSP

* Remove old code

* Creating IronOS PD integration wrapper

* Redirect to wrapper

* pd lib updates

* fix Docker build

* Finish linking across

* Cleanup

* Update Makefile

* Update push.yml

* Update push.yml

* PD -> Compensate for different tick rates

* Update codeql-analysis.yml

* Fix PD #define for @Firebie

* Check irq low at start

* Update BSP.h

* Update main.cpp

* Closer delay

* Update OLED.cpp

* Bugfix trying to start QC too early

* Missing fusb shouldnt hang qc

* Update FreeRTOSConfig.h

* Update the GD drivers

* Update Pinecil IRQ setup

* Redirect printf() to uart

* Update Power.cpp

* Adding extras to PD state

* Update USBPD.cpp

* Delay in printf

* Iterate once before delay on start

* Update usb-pd

* master usb-pd now

* Format gd libs

* Update gd32vf103_bkp.c

* Guard with PD timeout

* Remove CodeQL

* Slow for testing, fix runt pulses at start

* Fix runt pulse in read size 1

* Cleaner probing setup

* Testing delay during stop gen in read 1

* Update I2C driver

* Update gd32vf103_i2c.c

* Cleaning up i2c wrapper a little, given up on dma for rx

* Update preRTOS.cpp

* Update Setup.cpp

* Update MOVThread.cpp

* Slow down UART to work with new clock config

* Better ack setup for 2 byte read

* Cleanup POW_PD so cant be lost in #includes

* tipResistance -> TIP_RESISTANCE

* handle NOP race on len==2

* Update configuration.h

* Dont use neg timeout to mask anymore

* Not required for MHP

* Fix up source display Miniware

* Fix race on PD init

* Update POWThread.cpp

* Update formatting

* MHP format

* Update push.yml

* Faster TS80P I2C

* Bugfix for IRQ handlers

* Correctly handle I2C race on PD access

* Fix CI error (unused var) and MHP IRQ

* Test Pinecil alt ADC mode
2021-10-02 14:48:58 +10:00
Ben V. Brown
2bfb8a6535 Unify settings for each model into once place 2021-09-15 20:24:41 +10:00
Ben V. Brown
8fd2f6e95c Second pass 2021-09-12 14:03:09 +10:00
Varga Zsolt
a75d97360f Suggestions mostly corrected 2021-06-07 01:09:41 +02:00
Ben V. Brown
26ad63b03b Followthrough of the cleanup 2021-05-01 13:29:26 +10:00
Ben V. Brown
f12ed98991 Cache FUSB polls 2021-04-05 15:53:29 +10:00
Ben V. Brown
9f0054f7b0 WiP PPS 2021-04-05 00:02:10 +10:00
Ben V. Brown
f786901da0 Formatting the C/C++ files 2021-01-17 10:48:52 +11:00
Ben V. Brown
184b2c909f ./workspace/TS100 -> ./source/ 2021-01-17 09:43:55 +11:00