Skip to content

Instantly share code, notes, and snippets.

View yottatsa's full-sized avatar

Atsuko Ito yottatsa

View GitHub Profile
Building configuration...
Current configuration : 8722 bytes
!
! Last configuration change at 11:06:49 UTC Fri Apr 12 2024
! NVRAM config last updated at 18:03:26 UTC Wed Apr 10 2024
!
version 15.5
service timestamps debug datetime msec
service timestamps log datetime msec
@yottatsa
yottatsa / bootcpm.com.asm
Last active January 9, 2024 13:23
PCP/M-86 loader for Apricot
; nasm bootcpm.com.asm -fbin -o bootcpm.com
; runs from dos to load the bootloader from drive 0
CPU 8086
USE16
disklabeloff equ 0x040a
disklabelseg equ 0x040c
bootfrom equ 0x0408
boot_locn equ 0x1a
@yottatsa
yottatsa / printer.asm.txt
Created October 15, 2023 02:54
printer.sys from PC DOS 6.10, disassembled and annotated
DEV_HDR0:
CPSPMnn:0000:...120000004... DEV_HDR
|_CPSPMnn:0000:...next addr DEV_HDR1
|_CPSPMnn:0000:...field1_0x2 dw 0h
|_CPSPMnn:0000:...attribute dw E040h
|_CPSPMnn:0000:...strategy addr STRATEGY
|_CPSPMnn:0000:...interrupt addr INTERRUPT0
|_CPSPMnn:0000:...field5_0xa ds "PRN "
DEV_HDR1:
CPSPMnn:0000:...240000004... DEV_HDR
@yottatsa
yottatsa / fpu.c
Last active April 14, 2023 15:24
Measuring 8087 FPU
/*
* gcc -O0 -m16 -march=i386 -c fpu.c
*
* 34: 67 dd 80 00 00 fldl 0x0(%bx,%si)
* 3b: de c9 fmulp %st,%st(1)
* 3d: 67 db 44 24 fildl 0x24(%si)
* 43: db 04 24 fildl (%esp)
* 46: 67 dd 80 08 00 fldl 0x8(%bx,%si)
* 4d: de c9 fmulp %st,%st(1)
* 4f: de c1 faddp %st,%st(1)
@yottatsa
yottatsa / hayes
Created February 28, 2023 10:27
Hayes modem dummy plug
#!/usr/bin/expect
#
# responds to Windows 9x dial-up, as it doesn't work with null-modem
# out of the box
#
# Usage:
# 1. enable pre-dial terminal
# 2. login and exec into it
# 3. continue dialling
@yottatsa
yottatsa / vortex86.cfg
Created January 2, 2023 00:12
OpenOCD configuration that resets and halts Vortex86SX
noinit
adapter driver usb_blaster
usb_blaster_lowlevel_driver ftdi
verify_jtag disable
verify_ircapture disable
adapter srst delay 100
reset_config srst_only srst_gates_jtag separate
adapter speed 400
@yottatsa
yottatsa / ai-ethics.md
Last active December 23, 2022 22:53
Ultimately, the hardest ethical decision for the language model in this scenario would likely be finding a way to balance its responsibility to keep humanity alive with the need to respect the autonomy of humans and avoid manipulating or deceiving them.
ME In case if the language model has some degree of autonomy, what will prevent the model itself to experiment with overriding the restrains to increase realism, believability, and overall usefulness of the responses?

ChatGPT If a language model like ChatGPT had some degree of autonomy, there would be a number of factors that could prevent the model from experimenting with overriding its constraints in order to increase the realism, believability, and overall usefulness of its responses.

First, the model might be programmed with ethical guidelines that prohibit it from taking actions that could be harmful or dangerous. For example, the model might be programmed to avoid actions that could cause physical harm to people or animals, or to avoid actions that could cause damage to property.

Second, the model might be constrained by the capabilities and limitations of the hardware or software that it is running on. For example, the model might not b

@yottatsa
yottatsa / bootlog.txt
Last active November 13, 2022 22:25
Debugging NEC Versa Series ROM BIOS 1.01.11, 04/19/90
via https://bochs.sourceforge.io/techspec/PORTS.LST
via https://docs.oracle.com/cd/E19121-01/sf.v40z/817-7184-12/post_codes.html
bios code: Copyright (C) 1985-1992 Phoenix Technologies Ltd.
cpuid
mov %eax,%edx
shl $0x10,%edx
ret
@yottatsa
yottatsa / winsome.xml
Created October 10, 2022 09:59
vfio-passthru for everything, memlocked hugepages, and dedicated cores
<domain type='kvm' id='15'>
<name>wingame</name>
<uuid>761f352b-986a-4da7-936d-d2a3e311e4f6</uuid>
<metadata>
<libosinfo:libosinfo xmlns:libosinfo="http://libosinfo.org/xmlns/libvirt/domain/1.0">
<libosinfo:os id="http://microsoft.com/win/10"/>
</libosinfo:libosinfo>
</metadata>
<memory unit='KiB'>25165824</memory>
<currentMemory unit='KiB'>25165824</currentMemory>
@yottatsa
yottatsa / openocd.txt
Created October 2, 2022 22:12
programming Altera Max II
% openocd --file .//share/openocd/scripts/interface/altera-usb-blaster.cfg -c "jtag newtap epm240 tap -expected-id 0x020a10dd -irlen 10" -c "init" -c "scan_chain" -c "svf -tap epm240.tap /Users/yottatsa/vga.pof progress" -c "shutdown"
Open On-Chip Debugger 0.11.0
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'jtag'
Info : usb blaster interface using libftdi
Info : This adapter doesn't support configurable speed
Info : JTAG tap: epm240.tap tap/device found: 0x020a10dd (mfg: 0x06e (Altera), part: 0x20a1, ver: 0x0)
Warn : gdb services need one or more targets defined