Neil McKechnie
0118aa037d
Merge branch 'devel-nmck' of https://github.com/DCC-EX/CommandStation-EX into devel-nmck
2023-02-15 22:29:28 +00:00
Neil McKechnie
21c82b37b0
Allow frequency of PWM to be set for PCA9685 drivers.
...
It's a parameter on the create() call, e.g.
PCA9685::create(vpin, npins, address, frequency);
2023-02-15 22:29:21 +00:00
pmantoine
67bd886a98
USB Serial fixes for EX-RAIL & debug
2023-02-15 08:51:21 +08:00
Neil McKechnie
3292c93192
Update I2CManager.cpp
...
Report address 0x3d as (probably) OLED Display.
If an I2C probe for a device times out, assume that there's a bus problem on the MUX sub-bus, and skip the rest of the devices on that bus. This reduces the impact of the long timeout on some Wire implementations.
2023-02-14 21:56:11 +00:00
Harald Barth
7311f2ce64
LCN bugfix
2023-02-12 20:38:03 +01:00
Harald Barth
2ada89f918
LCN bugfix
2023-02-12 20:35:57 +01:00
Neil McKechnie
f1f1be8ad9
Oops- forgot to push this one. Name changes again.
2023-02-12 09:18:02 +00:00
peteGSX
0b0aba7aef
Merge pull request #305 from DCC-EX:41-feature-request-enable-servo-animations-in-ex-ioexpander
...
Fix myHal example for EX-IOExpander
2023-02-12 19:14:59 +10:00
peteGSX
9c95eb6905
Servo animation moved to EX-IO
2023-02-12 19:06:46 +10:00
Neil McKechnie
ec73ac69d9
A few more name changes to more generic names
2023-02-12 09:01:16 +00:00
peteGSX
47cda83210
Disabled servo animations
2023-02-12 10:36:26 +10:00
Neil McKechnie
35f3cca9b3
Rename LCDDisplay class to Display; renameEXRAIL LCD2 macro to SCREEN
2023-02-11 23:37:09 +00:00
Neil McKechnie
65f7a4917f
Separate out lcd (write to default display) and lcd2 (any display).
2023-02-11 17:04:18 +00:00
Neil McKechnie
8be9d9e0b0
Support for multiple displays (OLED etc).
...
New EXRAIL command LCD2(display,row,"text"). Display 0 is the usual one, other displays can be configured through HAL.
2023-02-11 15:47:50 +00:00
Neil McKechnie
a9971968c0
Update I2CManager_NonBlocking.h
...
Reduce platform-specific part of ATOMIC_BLOCK definition to one inline function _getInterruptState()
2023-02-10 22:58:58 +00:00
Neil McKechnie
e498915b28
Update I2CManager_AVR.h
...
Avoid loop in I2C_sendStart function.
2023-02-10 19:57:42 +00:00
Neil McKechnie
c315895cd9
Update I2CManager_NonBlocking.h
...
Rework ATOMIC_BLOCK to further simplify and clarify.
2023-02-10 19:52:24 +00:00
Neil McKechnie
1cfe5a1e46
Update I2CManager_STM32.h
...
Fix some merge errors.
2023-02-10 18:22:35 +00:00
Neil McKechnie
ad4cedfccf
Update I2CManager_NonBlocking.h
...
Rationalise ATOMIC_BLOCK macro definition and remove reliance on atomic.h.
2023-02-10 18:21:50 +00:00
Neil McKechnie
98697427a3
Update I2CManager_SAMD.h
...
Fix compile errors following other changes
2023-02-10 18:21:06 +00:00
Neil McKechnie
f5b5809ba5
Merge branch 'devel-nmck' of https://github.com/DCC-EX/CommandStation-EX into devel-nmck
2023-02-10 15:57:57 +00:00
Neil McKechnie
0b307a67e4
I2CManager: Update native drivers for MUX support from the common code.
2023-02-10 15:47:44 +00:00
Neil McKechnie
553a94bf67
I2CManager: Refactor common driver code.
...
Put mux handling into I2CManager_NonBlocking.h to keep the native (controller-specific) drivers more simple.
Remove almost all but one of the static definitions, in preparation for supporting multiple I2C buses.
2023-02-10 15:46:50 +00:00
Neil McKechnie
18b148ed1f
IO_EXFastClock - fix compile error due to closing brace outside of #if block.
2023-02-10 15:35:17 +00:00
Neil McKechnie
1ffb3a9836
Update IO_OLEDDisplay.h
...
Round up number of characters per line, so that the last few pixels on the line are erased when writing blanks.
2023-02-10 15:34:13 +00:00
Neil McKechnie
f358880f30
IO_VL53L0X: Some bug fixes.
...
Modify state model, and improve recovery after <D HAL RESET>.
2023-02-10 15:32:41 +00:00
Neil McKechnie
5f9705d1b7
Improve IODevice::reset function
...
Ensure that the _loop() function is able to run after a device is reset.
2023-02-10 15:30:35 +00:00
Neil McKechnie
7e2487ffbb
Avoid compiler error when no HAL installed.
2023-02-10 15:29:09 +00:00
pmantoine
fd07402aec
STM32 better I2C still work in progress
2023-02-09 15:12:16 +08:00
peteGSX
d8d785877e
Fix myHal example for EX-IOExpander
2023-02-09 13:38:06 +10:00
peteGSX
3b82a94d83
Merge pull request #304 from DCC-EX:ex-io-28-feature-request-enable-pwm-support
...
Ex-io-28-feature-request-enable-pwm-support
2023-02-09 13:20:46 +10:00
peteGSX
acadf241e6
Update version
2023-02-09 13:15:04 +10:00
peteGSX
8cc5f7ddf4
Merge branch 'ex-io-28-feature-request-enable-pwm-support' of https://github.com/DCC-EX/CommandStation-EX into ex-io-28-feature-request-enable-pwm-support
2023-02-09 13:08:34 +10:00
peteGSX
f1c17c3606
Add more state checking
2023-02-09 13:03:00 +10:00
peteGSX
d36ac7dcfd
Revert IODevice.h change
2023-02-09 12:58:48 +10:00
peteGSX
6b67760db1
Fix dynamic RAM allocation
2023-02-09 12:58:48 +10:00
peteGSX
6874ddca9b
Servo functional
2023-02-09 12:58:48 +10:00
peteGSX
06827a42b7
Remove excess drivers
2023-02-09 12:58:48 +10:00
peteGSX
f59fe6e83b
Some success
2023-02-09 12:58:48 +10:00
peteGSX
c768bdc361
Start adding servo to EX-IO
2023-02-09 12:58:48 +10:00
peteGSX
ad97260055
Add extra error checking
2023-02-09 12:58:48 +10:00
peteGSX
938b4cfbd6
Update version
2023-02-09 12:58:48 +10:00
peteGSX
2a3d48dc00
Fix digital read bug
2023-02-09 12:58:48 +10:00
peteGSX
5efb0c5013
Basic PWM working
2023-02-09 12:58:48 +10:00
peteGSX
e53ed7b46d
Brief start on PWM
2023-02-09 12:58:48 +10:00
peteGSX
4d31cd64a5
Add new drivers
2023-02-09 12:58:48 +10:00
peteGSX
6031a0fb7f
Fix mess after rebase and conflicts
2023-02-09 12:58:48 +10:00
peteGSX
d375723a13
Cleaned up PWM start
2023-02-09 12:57:30 +10:00
peteGSX
fa38583772
Brief PWM start
2023-02-09 12:57:30 +10:00
peteGSX
984ef6fead
Refactored, analogue tested
2023-02-09 12:57:29 +10:00