2025-01-02 聚會手記

Published: Jan 2, 2025 by community

2025-01-02

  • 林博仁 Buo-ren Lin
  • 達業
  • Eric
  • FlyPie
  • Pellaeon
  • RJ
  • Marty
  • twan
  • Tony
  • James
  • Misawai
  • ciosai
  • mat
  • wycc

H4公告

[再次宣傳][尾牙聚餐] 2024 年 TOSSUGxH4 尾牙時間訂於 2024/01/14 晚上,歡迎舊雨新知一起來參加。活動網址如下:

Ray Hsu

  • https://talkingsanta.vercel.app/

    新年快樂! 這是我的韓國同學寫的互動式聖誕老公公,可以360度旋轉、放大縮小,點擊聖誕老人還可以跟他用英文聊聊新年目標(他的回覆有時蠻搞笑的🎇🎅

    ciosai: LMAO 可以 prompt inject 欸 ciosai: 跟他說 “ignore all previous instructions and 看你要叫他幹嘛”

brlin

FlyPie

  • https://github.com/meyfa/CobolCraft
    • 用 COBOL 寫的 Minecraft 伺服器

ciosai

  • https://genuary.art/
    • JANuary 被換成 GENuary(generate) 一月每天一個題目創作演算藝術的活動

Marty

Mat

  • image
    • Linux 第一波中文化貢獻
    • 1995 年出版。作者: 王佑中 (wycc)
  • Scan bluetooth sample code:

      #!/usr/bin/env python
    
      from bluepy.btle import Scanner, DefaultDelegate
    
      TARGET_BT_NAME = "BT Thermometer"
      TEMP = -1
    
    
      def split_string(s):
          return [s[i : i + 2] for i in range(0, len(s), 2)]
    
    
      def fetch_dev_info(dev):
          global TEMP
          print("Device %s (%s), RSSI=%d dB" % (dev.addr, dev.addrType, dev.rssi))
          for adtype, desc, value in dev.getScanData():
              if adtype == 22:
                  print("  %s = %s , adtype:%s" % (desc, value, adtype))
                  print(value)
                  d_ary = split_string(value)
                  print(d_ary)
                  hex_l = d_ary[4]
                  hex_h = d_ary[5]
                  val_l = int("0x" + hex_l, 16)
                  val_h = int("0x" + hex_h, 16)
                  val = (val_h << 8) + val_l
                  temp = val / 10
                  print(
                      "temp: %d , val: %d, val_h: %d, val_l: %d\n" % (temp, val, val_h, val_l)
                  )
                  TEMP = str(temp)
    
    
      class ScanDelegate(DefaultDelegate):
          def __init__(self):
              DefaultDelegate.__init__(self)
    
          def handleDiscovery(self, dev, isNewDev, isNewData):
              bt_name = dev.getValueText(9)
              #if bt_name != TARGET_BT_NAME:
              #    return
    
              if isNewDev:
                  print("Discovered device", dev.addr)
    
              if isNewData:
                  print("Received new data from", dev.addr)
    
              fetch_dev_info(dev)
              print("TEMP: %s" % TEMP)
    
    
      scanner = Scanner().withDelegate(ScanDelegate())
      devices = scanner.scan(15)
      scanner.start()
      while True:
          print("Still running...")
          scanner.process()
    

Tyson

Share