Skip to content

Instantly share code, notes, and snippets.

View Gomi-coder's full-sized avatar

gomi Gomi-coder

  • sswu
  • seoul
View GitHub Profile
@Gomi-coder
Gomi-coder / gomi_gist_index.md
Last active September 17, 2025 07:58
blob mode link dummy
@Gomi-coder
Gomi-coder / 1_bluetooth_uart_uuid.md
Last active September 17, 2025 07:21
basic networking, Bluetooth, and serial communication concepts

Bluetooth & UART & UUID ⚡️

블루투스 + UART + UUID + NUS 설명

Tip

블루투스=도로 / UART=교통법규 / UUID=차량번호판


📡 블루투스 (Bluetooth)

무선 1:1 연결
무선 전송 기술(비유하자면 "도로" - 자동차가 다닐 수 있는 길)

@Gomi-coder
Gomi-coder / glossary.md
Created September 17, 2025 06:36
전문 용어 빠르게 찾기 위해 짧게 요약하여 모아둔 파일
  • 라디오
    • 무선 송수신기(transceiver)
    • 즉, 전파를 쏘고 받는 장치를 그냥 라디오라고 부름.
  • LoRa 모듈
    • LoRa 무선 기술을 쓸 수 있는(지원하는) 칩(또는 작은 회로)
    • 예: Semtech SX1262, SX1276 같은 칩
    • 이 칩 하나 만으로는 못 쓰고 마이크로컨트롤러(작은 컴퓨터) + 전원 + 안테나 같은 게 있어야 실제 동작 가능.
  • ESP32
    • 블루투스/와이파이 되는 작은 컴퓨터 칩
  • 메시
@Gomi-coder
Gomi-coder / JetpackComposeNavigation.markdown
Created April 11, 2023 04:17
jetpack compose navigation argument

Jetpack Compose Navigation

In Jetpack Compose Navigation, the navArgument function is used to define an argument that can be passed to a destination when navigating. The function takes two parameters: the name of the argument, and an optional block of configuration options.

The configuration options can be used to specify the type of the argument and provide default values or other settings. The type option is required to specify the data type of the argument. In the code you provided, the type is set to NavType.StringType, which means that the argument will be a string value.

To pass an argument to a destination, you can use the navigate function on the NavController object, like this:

navController.navigate("plantDetail/123")
@Gomi-coder
Gomi-coder / python_list_pop.py
Created February 15, 2023 06:14
python-list의 요소 삭제
user_1 = ['Jason', 'Smith', 'Kevin']
#del 리스트명[인덱스]
del user_1[1]
del user_1[1:3]#1,2번 인덱스 삭제
#리스트명.pop(인덱스)
user_1.pop(1)
user_1.pop()
@Gomi-coder
Gomi-coder / find_index.py
Created February 15, 2023 01:12
find() vs index()
## 공통점
# 둘 다 찾은 첫 번째 자리를 출력
'asdf문자열'.find('d')
'asdf'.index('d')
#시작점, 종료점 지정 (찾을 문자열, 시작점, 종료점) 혹은 (찾을 문자열, 시작점)
'asdfasd'.index('d', 2)
'asdfasdf'.find('d',1,3)
## 차이점
'hello'.find('o',1,3) #찾는 값 없으면 -1
@Gomi-coder
Gomi-coder / queByDeque
Last active February 6, 2023 04:18
Queue
from collections import deque
queue = deque()
queue.append(5)
queue.append(2)
queue.append(3)
queue.popleft()
queue.append(1)
@Gomi-coder
Gomi-coder / lambda.markdown
Last active February 1, 2023 06:17
python의 lambda(람다)

lambda?

람다 형식.
인공지능 분야나 AutoCAD라는 설계 프로그램에서 쓰이는 Lisp 언어에서 물려받음.
함수를 딱 한 줄만으로 만들게 해줌.
사용 방법은 lambda 매개변수 : 표현식으로 콜론을 기준으로 좌측이 입력 파라미터, 우측이 return값
언제 사용? 반복적이고 직관적으로 특정 기능을 구현하기 위해 작성하는 함수를 굳이 일회성으로 써야 할 때(메모리 낭비 유발을 방지)

  • 예_두 수를 더하는 함수
@Gomi-coder
Gomi-coder / bisect.markdown
Created January 31, 2023 07:30
Python의 bisect??

bisect library?

원소들이 정렬된 리스트에서 특정 원소를 찾을 때 효과적으로 사용할 수 있음(리스트 내 정렬 순서를 유지함.)

  • 종류
    • bisect_lift(list, data) : 리스트에 데이터를 삽입할 가장 왼쪽 인덱스를 찾는 함수
    • bisect_right(list, data) : 리스트에 데이터를 삽입할 가장 오른쪽 인덱스를 찾는 함수
from bisect import bisect_left, bisect_right