Skip to content

Instantly share code, notes, and snippets.

@changtimwu
changtimwu / setupqlogic.md
Last active October 25, 2021 01:57
instruction of set QLogic FastLinQ QL45211 to force 25G mode on windows server

based on official qlogic adapter user guide

  • Downloa and install the utility QCScli.
  • find the adapter's PCI ID

image

  • show adapter's info via below command
C:\Program Files\QLogic Corporation\QCSR>QCScli.exe -t phyports -f bdf -i 01:00.00 "bootcfg -t MBA -o show"
#正經八百
def uniqnum( num):
digits=[]
while num>0:
r = num % 10
if r in digits:
return False
digits.append(r)
num = num // 10
return True
@changtimwu
changtimwu / qformd.md
Created July 15, 2021 02:00
Questions about Mobile Drive
  • 鴻海這兩年電動車佈局頗多, 不知道富智捷(Mobile Drive) 與 鴻華(Foxtron) & MIH 聯盟, 之間的關係為何? 有哪些共享或區隔的資源呢?
  • 老師點到的重點項目, 與 MIH 開出來了的職缺很相近, 不知道是不是其實就是同一個單位?
  • Stellantis 投資 Mobile Drive, 一定有不小期望, 好奇是否有被賦予中短期任務, 不管是產品上或財務上.
  • 從 Mobile Drive 形象影片來看, 重點放在 vehicle infotainment 與 app 應用加值, 不知道是否方便列舉幾個已經確定的細部方向與項目?
  • Mobile Drive 公司目前的管理模式為何? 現有組織架構, 鴻海高層如何與Stellantis 共同管理公司?
* Vochie -- cloud-based interactive karaoke service
- A social singing platform. Users can sing and share their recreation with others.
- provides extensive streaming APIs for third-party integration. Successeful apps published on AppleTV, Roku platforms. (有連結會更有說服力)
* KaraX(要取個名字) -- Professional Karaoke Machine solution
- First RISC based full-function karaoke machine solution supporting all main stream song formats(MV, MP3/LRC, MID).
- In-house developed high-accurate AV synchronization technology. Multiple media sources including HD video, multi-track audio, user recordings and lyric could be simultaneously played back with little latency.
- Intuitive and user-friendly on-screen UI.
import random, time
from randcrack import RandCrack
import string
random_id_characters = string.ascii_letters + string.digits
random.seed(time.time())
rc = RandCrack()
for i in range(624):

Study the Protocol High-availability Seamless Redundancy Protocol (HSR)

HSR is a Layer 2 redundancy protocol for Ethernet. HSR adds a header to each frame, and duplicates the frame, sending it along two directions of a ring. Nodes in the ring pass the frame along the ring, using the header to discard duplicates.

Example traffic

@changtimwu
changtimwu / 5gmecsurvey.md
Last active August 22, 2020 02:08
5G MEC survey

simple illustration

https://zhuanlan.zhihu.com/p/33324744

sumarry

https://www.zhihu.com/question/322228254/answer/667226755

  • 到 2020 年全球连接到网络的设备将达到约 208 亿台,移动端应用将迫切需要一个更有竞争力、可扩展,同时又安全和智能的接入网。而提供网络服务是运营商的主体业务。
  • 所以互联网公司是希望运营商可以提供覆盖全国的丰富边缘计算节点资源,他们可以从中选择部分边缘点弹性的租用/调用MEC服务
  • 务,但是互联网公司对边缘节点的位置及业务量的需求均是高度动态的,运营商很难在这种不确定性中规划MEC的建设规模与规格,MEC的业务利用率也不一定有保证,从而商业收益也存在不确定性,
  • 这种情况下运营商会稳妥起见就会仍然以本地区域性的ICT客户项目为主按需建设部署MEC。
@changtimwu
changtimwu / t4tensortsurvey.md
Last active April 26, 2020 00:54
T4 and TensorRT Survey

Prepare

reference: https://github.com/NVIDIA/retinanet-examples

CLI session dump

if you see retinanet_rn50fpn.pth crashed, please see solution here

root@4f884f99f02d:~/work# odtk export retinanet_rn50fpn.pth  retinanet_rn50fpn.plan
Loading model from retinanet_rn50fpn.pth...

please paste the following commands

set mtdids 'nand0=armada-nand'                                                                                                 
set mtdparts 'mtdparts=armada-nand:16m(boot)ro,-(rootfs)'                                                                      
set usbType 3                                                                                                                  
set dtbfile armada-385-qnap.dtb                                                                                                
set ubifn 'ubifs_128.img'                                                                                                      
set ubiroot 'ubi0'                                                                                                             
set bootcmd 'run ubiboot'                                                                                                      
@changtimwu
changtimwu / dma_init_fail.md
Last active March 1, 2019 23:20
description of the eth1 DMA initialization fail problem
  • code clip of the error message. drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
   /* DMA initialization and SW reset */
    ret = stmmac_init_dma_engine(priv);
    if (ret < 0) {                                                                                  
        pr_err("%s: DMA initialization failed\n", __func__);
        goto open_error;
    }