Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Emulates the SID sound-chip in software. The C++ emulation code was copied over from libsidplayfp.
Requirements for installation from source:
Install the latest version using
python -m pip install pyresidfp
Build from source and install using
python -m pip install .
For the example, NumPy and soundcard python packages are required. The example is ported from the section Sample Sound Program, Commodore 64 User's Guide, page 80:
from datetime import timedelta
import numpy as np
import soundcard as sc
from pyresidfp import SoundInterfaceDevice, Voice, ControlBits, Tone
# program SID
sid = SoundInterfaceDevice()
sid.Filter_Mode_Vol = 15 # Maximum volume
sid.attack_decay(Voice.ONE, 190) # 800 ms attack, 15 s decay
sid.sustain_release(Voice.ONE, 248) # sustain peak, 300 ms release
sid.tone(Voice.ONE, Tone.C4)
sid.control(Voice.ONE, ControlBits.TRIANGLE | ControlBits.GATE)
# sample attack phase
attack_phase = timedelta(seconds=0.32)
raw_samples = sid.clock(attack_phase)
# reprogram SID for release phase and sample
release_phase = timedelta(seconds=0.3)
sid.control(Voice.ONE, ControlBits.TRIANGLE)
raw_samples.extend(sid.clock(release_phase))
# convert audio format and play
samples = np.array(raw_samples, dtype=np.float32) / 2.0**15
spkr = sc.default_speaker()
spkr.play(data=samples, samplerate=int(sid.sampling_frequency), channels=1)
We like to thank all contributors of libsidplayfp
, especially:
FAQs
Emulates the SID sound-chip
We found that pyresidfp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.