Skip to content
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

Allow access to eighth sequence slot #28

Merged
merged 1 commit into from
Jan 11, 2022
Merged

Allow access to eighth sequence slot #28

merged 1 commit into from
Jan 11, 2022

Conversation

tekktrik
Copy link
Member

Addresses Issue #15 by opening up access to the eighth sequence slot. Data sheet as posted by @caternuson does allow for this.

@caternuson
Copy link
Contributor

@tekktrik Did you test this? The 8th slot works as expected, etc.? Just wondering if original author ran into something weird that could explain why only 7 were being used.

(can't remember if i ever tested when writing issue)

@tekktrik
Copy link
Member Author

@caternuson no not yet but was going to see if you had the hardware or otherwise I was going to pick it up. My best guess is the datasheet got accidentally misinterprutted as saying that only 7 registers were used for sequences, when it's really the eight registers, which each use 7 of the bits. The accompanying graphic in the datasheet regarding the registers made me think that anyway until I re-read it and realized.

@caternuson
Copy link
Contributor

OK, I tested real quick. I had some DRV2605's I needed to repair anyway.

Adafruit CircuitPython 7.1.0 on 2021-12-28; Adafruit QT Py RP2040 with rp2040
>>> import board
>>> import adafruit_drv2605
>>> drv = adafruit_drv2605.DRV2605(board.I2C())
>>> drv.sequence[0] = adafruit_drv2605.Pause(1)
>>> drv.sequence[1] = adafruit_drv2605.Effect(1)
>>> drv.sequence[2] = adafruit_drv2605.Pause(1)
>>> drv.sequence[3] = adafruit_drv2605.Effect(1)
>>> drv.sequence[4] = adafruit_drv2605.Pause(1)
>>> drv.sequence[5] = adafruit_drv2605.Effect(1)
>>> drv.sequence[6] = adafruit_drv2605.Pause(1)
>>> drv.sequence[7] = adafruit_drv2605.Effect(1)
>>> drv.play()
>>> 

I get the expected 4 rumbles with 1 sec pause between each. So seems to work. Looks good. Thanks for PR!

@caternuson caternuson merged commit 32ae578 into adafruit:main Jan 11, 2022
@tekktrik
Copy link
Member Author

Hooray! Thank you for the quick help!

adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Jan 12, 2022
Updating https://github.com/adafruit/Adafruit_CircuitPython_DRV2605 to 1.2.0 from 1.1.13:
  > Merge pull request adafruit/Adafruit_CircuitPython_DRV2605#29 from tekktrik/doc/typing-and-documentation
  > Merge pull request adafruit/Adafruit_CircuitPython_DRV2605#28 from tekktrik/feature/add-eight-slot
  > update rtd py version

Updating https://github.com/adafruit/Adafruit_CircuitPython_HTS221 to 1.1.7 from 1.1.6:
  > Merge pull request adafruit/Adafruit_CircuitPython_HTS221#10 from tekktrik/feature/add-typing
  > update rtd py version

Updating https://github.com/adafruit/Adafruit_CircuitPython_PCA9685 to 3.4.0 from 3.3.9:
  > Merge pull request adafruit/Adafruit_CircuitPython_PCA9685#42 from tekktrik/doc/add-typing
  > Merge pull request adafruit/Adafruit_CircuitPython_PCA9685#43 from tekktrik/feature/add-mode2-reg
  > update rtd py version

Updating https://github.com/adafruit/Adafruit_CircuitPython_Wiznet5k to 1.12.0 from 1.11.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_Wiznet5k#49 from AdamCummick/main

Updating https://github.com/adafruit/Adafruit_CircuitPython_AVRprog to 1.4.2 from 1.4.1:
  > Merge pull request adafruit/Adafruit_CircuitPython_AVRprog#31 from aarontusko/fix-write_fuses-busy_wait

Updating https://github.com/adafruit/Adafruit_CircuitPython_OneWire to 1.2.8 from 1.2.7:
  > Merge pull request adafruit/Adafruit_CircuitPython_OneWire#24 from tekktrik/doc/add-typing
  > update rtd py version

Updating https://github.com/adafruit/Adafruit_CircuitPython_PIOASM to 0.5.4 from 0.5.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_PIOASM#34 from dannystaple/mov_operators

Updating https://github.com/adafruit/Adafruit_CircuitPython_Requests to 1.10.5 from 1.10.4:
  > Merge pull request adafruit/Adafruit_CircuitPython_Requests#94 from kevincon/fix-93

Updating https://github.com/adafruit/Adafruit_CircuitPython_Waveform to 1.3.9 from 1.3.8:
  > update rtd py version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants