Skip to content

Instantly share code, notes, and snippets.

@daykin
daykin / override-relative-dbd-path
Created March 30, 2022 16:03
Patch allows relative path for softIoc to be overriden (current behavior by default)
Index: epics-base/configure/CONFIG_SITE
===================================================================
--- epics-base.orig/configure/CONFIG_SITE
+++ epics-base/configure/CONFIG_SITE
@@ -178,5 +178,8 @@ LINKER_USE_RPATH = YES
# All root directories are considered to be the same.
LINKER_ORIGIN_ROOT = $(INSTALL_LOCATION)
+# Compile in absolute path to softIoc.dbd as default, instead of relative
+ABSOLUTE_DBD = NO
@daykin
daykin / pico8-lockup
Created June 15, 2021 21:29
PICO8 Debug info
epicsMutexShowAll 1
ellCount(&mutexList) 13396 ellCount(&freeList) 18
#^This remains constant every time command is sent^
-----------------------------------------------------------------
(gdb) info threads
Id Target Id Frame
* 1 Thread 0x7f98200dfc80 (LWP 14920) "st.cmd" 0x00007f9823d9c151 in __pselect (nfds=1, readfds=0x7ffc12c46b10, writefds=0x0, exceptfds=0x0, timeout=<optimized out>, sigmask=<optimized out>) at ../sysdeps/unix/sysv/linux/pselect.c:69
2 Thread 0x7f981f8d3700 (LWP 14922) "errlog" futex_wait_cancelable (private=0, expected=0, futex_word=0x55efe80a9054) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
3 Thread 0x7f981f852700 (LWP 14924) "Reader" futex_wait_cancelable (private=0, expected=0, futex_word=0x55efe8183760) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
@daykin
daykin / camonitor_example.py
Last active March 24, 2020 14:04
camonitor callback
from pkg_resources import require
require('cothread')
import cothread
from cothread import Timedout
from cothread.catools import caput, camonitor
done = cothread.Event()
def callback(value):
if value == "whatever value I'm looking for":
@daykin
daykin / Todo.java
Last active November 30, 2015 17:43 — forked from eppleton/Todo.java
Knockout API Tutorial - Sample 1
package com.dukescript.tutorial;
import net.java.html.json.Model;
import net.java.html.json.Property;
@Model(className = "VStringList",properties = {
@Property(name = "vsname", type = VString.class, array = true) //replace string with wrapper?
})
public class ViewModel {
@daykin
daykin / Sample.java
Created November 10, 2015 21:15 — forked from jtulach/Sample.java
Spinning Duke by Ivar
package dew.demo.duke2brwsr;
import net.java.html.json.*;
@Model(className = "Data", properties = {
@Property(name = "image", type = String.class),
@Property(name = "buttonText", type =String.class),
@Property(name = "on", type = boolean.class)
})
class Duke2Brwsr {
static {