Skip to content

Instantly share code, notes, and snippets.

@akirayou
akirayou / RunOnUbuntu_UDPToROS_TF.py
Created June 29, 2018 07:57
Vive postion transport via UDP
#!/usr/bin/env python
import socket
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
sock.bind(('0.0.0.0',13593))
import rospy
import tf
import bson
from threading import Thread, Lock
rospy.init_node("vtrans")
@akirayou
akirayou / 40-NTTLTE.rules
Last active August 8, 2018 04:41
How to use LTE modem NTT L03F
#must be in /etc/udev/rules.d directory
#/dev/ttyNTTLTE will be able to recive AT command
ACTION=="add",\
ATTRS{idVendor}=="1004",\
ATTRS{idProduct}=="6367",\
RUN+="/usr/sbin/usb_modeswitch --std-eject --default-vendor 0x1004 --default-product 0x6367 --target-vendor 0x1004 --target-product 0x6366"
ACTION=="add|change",\
ATTRS{idVendor}=="1004",\
# -*- coding: utf-8 -*-
"""
Created on Thu Aug 9 22:50:30 2018
@author: akira
"""
import time
import socket
import numpy as np
# -*- coding: utf-8 -*-
"""
Created on Thu Aug 9 22:50:30 2018
@author: akira
"""
import time
import socket
import numpy as np
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.Globalization;
using System.Net.Sockets;
public partial class Data
{
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.Globalization;
using System.Net.Sockets;
public partial class Data
{
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.Globalization;
using System.Net.Sockets;
public partial class Data
{
@akirayou
akirayou / img.cs
Last active October 18, 2018 05:51
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Video;
public class ImgDump : MonoBehaviour {
public RenderTexture tex;
public VideoPlayer player;
public List<VideoClip> clip;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.Globalization;
using System.Net.Sockets;
public partial class Data
{
@akirayou
akirayou / dummy.cs
Last active October 31, 2018 02:54
void FillDummyLED()
{
Units = new UnitData[4];
float width = 9;
float height = 6;
if (false)
{
Units[0] = new UnitData("127.0.0.1", 1250);
Units[1] = new UnitData("127.0.0.1", 1250);
Units[2] = new UnitData("127.0.0.1", 1250);