EXOTIC SILICON
“Enhancing, tweaking and adding features”
Software patches from Exotic Silicon
EXOTICSILICONLOAD /REWIND
INTERACTIVE!!! Press LOAD/REWIND to start the tape drive with the patches tape!
Miscellaneous patchsets
Here at Exotic Silicon, we make local changes to a lot of the opensource software that we use. Although we try to upstream the most useful ones, sometimes that doesn't happen either because we're too busy, or because the changes are too specific to be of wider interest.
Some of our more recent patchsets have their own dedicated pages elsewhere on the site together with comprehensive notes and usage instructions.
This page provides download links for a few which do not.
No warranty
Although we take pride in the quality of our work, and strive to deliver only code of the highest standards, the following patches are provided AS IS and with NO WARRANTY. We make no guarantees that they will work as described, or that they won't break other functionality, possibly in subtle ways that might not be immediately obvious.
Be aware that all of our local patches were originally written for our own internal use, and our requirements are likely to be different to yours.
Signify key
All of the patches on this page have been signed with the following signify key:
Index
Bold and italic font rendering on the OpenBSD console
FileChangesDescription
dev/wscons/wsemul_vt100_subr.c
+6 lines
Add escape sequences to set and reset the italic flag.
dev/wscons/wsdisplayvar.h+1 line
Add a define for an italic flag.
dev/wscons/wsconsio.h
+3 lines
Add pointers to bold, italic and bold-italic versions of the glyph data.
dev/wsfont/wsfont.c
+72 lines
Render the bold, italic, and bold-italic versions of the font.
Free the memory allocated for the glyph data for the additional font variations when the font is unlocked.
dev/rasops/rasops.c
~2 lines
-6 lines
Pass the correct flags from the wscons code to the rasops code.
Remove unused lookups and flag setting for grey colors.
dev/rasops/rasops32.c
~1 line
+19 lines
Select the correct font before painting a glyph to the framebuffer.
Notes
Patch formatUnified diff with signature
Patch size6764 bytes
Patch hashSHA512 (patchset_bold_italic_7.2.sig) = TZQ+q0BEyUOxDCWQ20k26oioO2Ez8zoswMfqxqtulR21z5vZa3/oXipCtG/o0gDtffVjboqTZ6d7uR46WFMYnw==
Applies toThis diff will apply cleanly to OpenBSD 7.2-release.
Downloads
patchset_bold_italic_7.2.sigPatch with embedded signify signature
This patch adds the ability to use true bold and italic text on the OpenBSD console.
Once applied, the terminal will respond to the following control sequences which were previously not implemented:
␛[3m - Enable italics
␛[23m - Disable italics
Note that the default terminal type of 'vt220' does not define the sitm and ritm sequences, so programs which rely on parsing the terminfo terminal description will not support italics even using this patch, without further re-configuration.
Existing file supplement flag for cp
FileChangesDescription
src/bin/cp/cp.c
+3 lines
~3 lines
Add s to getop.
Add int sflag.
src/bin/cp/extern.h~1 line
Add int sflag.
src/bin/cp/utils.c
+7 lines
~2 lines
If a file exists with the same name in the destination directory, return 1 and do not perform the copy.
Otherwise, allow the copy to proceed and print a diagnostic message to stderr.
Add s flag to the usage information.
src/bin/cp/cp.1
+4 lines
~3 lines
Document the new -s flag in the manual page.
Notes
Patch formatUnified diff with signature
Patch size2861 bytes
Patch hashSHA512 (patchset_cp.sig) = JMw2G54RD5IduolZxvw3I6gZdUAKV7o2BbnLxW5fGll9B0pDh6V/UWOH6HZ800nUPbCdZubztXbCZ3oCDshNWw==
Applies toThis diff will apply cleanly to OpenBSD 6.8-release and OpenBSD 6.9-release.
Downloads
patchset_cp.sigPatch with embedded signify signature
This patch adds a new -s flag to cp. When used, the files in the destination directory are supplemented by the files being copied, rather than being overwritten.
For example, if we have two directories, source and dest, containing the following files:
# ls -l source
total 6
-rw-r--r-- 1 root wheel 12 Jan 1 1970 bar
-rw-r--r-- 1 root wheel 26 Jan 1 1970 baz
-rw-r--r-- 1 root wheel 6 Jan 1 1970 foo
# ls -l dest
total 0
-rw-r--r-- 1 root wheel 0 Jan 1 1970 foo
#
 
Then the output and result of cp -psv source/* dest/ will be:
# cp -psv source/* dest/
dest/bar doesn't already exist, copying
source/bar -> dest/bar
dest/baz doesn't already exist, copying
source/baz -> dest/baz
# ls -l source
total 4
-rw-r--r-- 1 root wheel 12 Jan 1 1970 bar
-rw-r--r-- 1 root wheel 26 Jan 1 1970 baz
-rw-r--r-- 1 root wheel 0 Jan 1 1970 foo
#
 
The file ‘foo’ in the destination directory was not overwritten.
Call recording and announcement for SXMO
FileChangesDescription
bin/sxmo_modemcall.sh
+11 lines
Make $HOME/call_rec if it doesn't already exist.
Create a base filename using the template YYYYMMDD_HHMMSS_{number}.
Record audio data to a wav file.
Write some cellular network data to a text file
Play an announcement from $HOME/answer.wav file to incoming calls
Notes
Patch formatStandard diff with embedded signify signature.
Patch size1843 bytes
Patch hashSHA512 (patchset_call_recording.sig) = 58X2DJ3mO7PBDuLYUHroZGbuBymi+liAF5fDQuyfteUm16oKslzKC9xbDIuK74i6M1ql5Vi+3ZEwIzio/+M3TQ==
Applies toSXMO 1.4.1 as included in postmarketOS v21.03 20210605-0335.
Tested onPinephone.
KNOWN ISSUESThere are a couple of known issues with this patch:
  • In-call audio quality is negatively affected locally, due to the re-sampling method used to convert 8000 Hz to 48000 Hz. Samples are simply duplicated rather than being interpolated, causing spurious high frequencies.
  • The wav file header is written with an incorrect length, as the recording is not cleanly stopped when the recording process is terminated.
Downloads
patchset_call_recording.sigPatch with embedded signify signature
This patch implements a simple automatic PSTN call recording and announcement function in SXMO.
Once this patch is applied, all PSTN calls placed or received will be recorded.
Call audio is written to a wav file in $HOME/call_rec/ using the following filename template:
YYYYMMDD_HHMMSS_{number}_[inc|out].wav
Call audio filename template
In which number is either the telephone number dialed for outgoing calls, or that provided by the network for incoming calls. Incoming calls are further identified with inc, and outbound calls are identified with out.
Some information provided by the cellular network is written to a text file with a similar name:
YYYYMMDD_HHMMSS_{number}_[inc|out].log
Call metadata filename template
If no telephone number is provided by the network for incoming calls, the number is replaced with the string “unknown”.
Additionally, if the file $HOME/answer.wav exists, and is a valid wav file, it will be played to the remote party when inbound PSTN calls are answered. This can be used, for example, to advise calling parties that the call is being recorded.
Call recordings are dual-channel, which when played as stereo places the local audio on the left channel and the remote audio on the right channel.
As supplied, the patch records 48 Khz, 16 bit audio. This has the advantage of recording the local audio in higher fidelity than it is likely being sent to the remote party. However, remote audio is converted to 48 Khz sampling by simple sample duplication, causing audible artifacts at the local end only, sounding like high frequency scratching during a call and on the recording. These artifacts can be trivially removed from the recording with post-processing.
The recording process is simply terminated when the call is ended, rather than being shut down cleanly. As a result, the wav file contains a header set to the maximum possible duration of recording. This can also trivially be fixed by writing a new header based on the actual length of the file.
You should check applicable regulations regarding the recording of PSTN telephone calls before using this patch.