'잡동사니'에 해당되는 글 13850건

  1. 2025.03.17 SCardListReadersA 함수(winscard.h)
  2. 2025.03.16 ace combat 7 멀티 플레이 첫 시도 2
  3. 2025.03.15 ace combat 7 sp mission완료
  4. 2025.03.15 한놈 털 밈
  5. 2025.03.14 low batt
  6. 2025.03.13 아내몰래 지름 ㅋㅋ 2
  7. 2025.03.13 libmodbus backend
  8. 2025.03.12 NTAG
  9. 2025.03.11 내 노트북 쓸만하네?
  10. 2025.03.11 NDEF 읽기

특이하다면 특이한 함수인데

mszReaders 변수의 길이를 포인터인 pcchReaders에 넘겨주어야지 정상적으로 작동한다.

LONG SCardListReadersA(
  [in]           SCARDCONTEXT hContext,
  [in, optional] LPCSTR       mszGroups,
  [out]          LPSTR        mszReaders,
  [in, out]      LPDWORD      pcchReaders
);

 

그래서 조금 편하게 쓰라고 SCARD_AUTOALLOCATE (-1)을 해주면 알아서 할당해서 던져주는 듯.

LPTSTR          pmszReaders = NULL;
LPTSTR          pReader;
LONG            lReturn, lReturn2;
DWORD           cch = SCARD_AUTOALLOCATE;

// Retrieve the list the readers.
// hSC was set by a previous call to SCardEstablishContext.
lReturn = SCardListReaders(hSC,
                           NULL,
                           (LPTSTR)&pmszReaders,
                           &cch );

[링크 : https://learn.microsoft.com/ko-kr/windows/win32/api/winscard/nf-winscard-scardlistreadersa]

'하드웨어 > rfid_nfc_smartcard' 카테고리의 다른 글

NDEF 데이터 읽기  (0) 2025.03.17
ntag 213, 215 그리고 13.25MHz CUID 카드  (0) 2025.03.17
NTAG  (0) 2025.03.12
NDEF 읽기  (0) 2025.03.11
mifare desfire 인증 프로세스  (0) 2025.03.11
Posted by 구차니
게임/ace combat2025. 3. 16. 16:58

무기 언락해보려고

두드려 맞을 각오로 f-16 끌고 가서 4등 달성 ㅋㅋ

 

다른 사람들은 다크스타에 X-02에 아주 난리 ㅋㅋㅋ

 

아무튼 1회 해서 멀티무기 언락!

싱글에서 벌어서 해도 되고 반대로 멀티해서 싱글 쪽 풀어도 되고(?)

'게임 > ace combat' 카테고리의 다른 글

잘가 ace combat 7  (0) 2025.04.30
ace combat 7 normal 난이도 끝  (0) 2025.04.06
ace combat 7 sp mission완료  (0) 2025.03.15
ace combat 7 - 미션 20, 엔딩  (0) 2025.03.11
ace combat 7 - 미션 19  (0) 2025.03.10
Posted by 구차니
게임/ace combat2025. 3. 15. 23:57

어우.. 마지막껀 템빨로 겨우 꺰

겁나 두드려 맞아도 50% 이하로 체력이 안 깍여서 SP 미션 깨는데 엄청 도움이 된다.

 

'게임 > ace combat' 카테고리의 다른 글

ace combat 7 normal 난이도 끝  (0) 2025.04.06
ace combat 7 멀티 플레이 첫 시도  (2) 2025.03.16
ace combat 7 - 미션 20, 엔딩  (0) 2025.03.11
ace combat 7 - 미션 19  (0) 2025.03.10
ace combat 7 F-22 구매!  (0) 2025.03.09
Posted by 구차니

어우 내일 또 한놈 또 밀어야.. ㅠㅠ

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

휴가  (0) 2025.03.24
오늘은 외식데이  (0) 2025.03.22
컴백  (0) 2025.03.02
피곤하다 -_ㅠ  (0) 2025.03.01
해운대  (0) 2025.02.16
Posted by 구차니

졸려!!

'개소리 왈왈 > 직딩의 비애' 카테고리의 다른 글

피곤한데 짜증까지  (0) 2025.04.03
3월 끝!  (0) 2025.03.31
아내몰래 지름 ㅋㅋ  (2) 2025.03.13
k-pass 다자녀 혜택 + 횟수 제한  (0) 2025.03.10
2 스택  (0) 2025.03.07
Posted by 구차니

RFID 종류별로 질러봄

NTAG는 몰라서 한번 사보는데 어디서 인식이 되려나..

 

'개소리 왈왈 > 직딩의 비애' 카테고리의 다른 글

3월 끝!  (0) 2025.03.31
low batt  (0) 2025.03.14
k-pass 다자녀 혜택 + 횟수 제한  (0) 2025.03.10
2 스택  (0) 2025.03.07
정신이 늙었어..  (2) 2025.02.20
Posted by 구차니

예전 작업을 다시 찾아보는데

워낙 자동화가 잘된녀석이라 slave 모드에서 외부에 read / write 명령을 추가로 처리할 방법을 찾고 있는데 영 안보여서 고민하다

소스뜯어보기로 결정!

 

rtu나 tcp에서 아래와 같이 modbus_new 명령을 통해 수행중에

backend에 기본적인 녀석들을 추가해주는데

modbus_t* modbus_new_rtu(const char *device,
int baud, char parity, int data_bit,
int stop_bit)
{
_modbus_init_common(ctx);
ctx->backend = &_modbus_rtu_backend;
ctx->backend_data = (modbus_rtu_t *)malloc(sizeof(modbus_rtu_t));
if (ctx->backend_data == NULL) {
modbus_free(ctx);
errno = ENOMEM;
return NULL;
}
ctx_rtu = (modbus_rtu_t *)ctx->backend_data;

 

해당 backend 구조체는 아래와 같이 여러개의 함수 포인터 들을 포함하고 있고

const modbus_backend_t _modbus_rtu_backend = {
_MODBUS_BACKEND_TYPE_RTU,
_MODBUS_RTU_HEADER_LENGTH,
_MODBUS_RTU_CHECKSUM_LENGTH,
MODBUS_RTU_MAX_ADU_LENGTH,
_modbus_set_slave,
_modbus_rtu_build_request_basis,
_modbus_rtu_build_response_basis,
_modbus_rtu_prepare_response_tid,
_modbus_rtu_send_msg_pre,
_modbus_rtu_send,
_modbus_rtu_receive,
_modbus_rtu_recv,
_modbus_rtu_check_integrity,
_modbus_rtu_pre_check_confirmation,
_modbus_rtu_connect,
_modbus_rtu_close,
_modbus_rtu_flush,
_modbus_rtu_select,
_modbus_rtu_free
};
const modbus_backend_t _modbus_tcp_backend = {
_MODBUS_BACKEND_TYPE_TCP,
_MODBUS_TCP_HEADER_LENGTH,
_MODBUS_TCP_CHECKSUM_LENGTH,
MODBUS_TCP_MAX_ADU_LENGTH,
_modbus_set_slave,
_modbus_tcp_build_request_basis,
_modbus_tcp_build_response_basis,
_modbus_tcp_prepare_response_tid,
_modbus_tcp_send_msg_pre,
_modbus_tcp_send,
_modbus_tcp_receive,
_modbus_tcp_recv,
_modbus_tcp_check_integrity,
_modbus_tcp_pre_check_confirmation,
_modbus_tcp_connect,
_modbus_tcp_close,
_modbus_tcp_flush,
_modbus_tcp_select,
_modbus_tcp_free
};

 

그중 하나 찍어서 보면 static 함수로 되어있다.

static ssize_t _modbus_rtu_send(modbus_t *ctx, const uint8_t *req, int req_length)

 

진짜로 전송하고 보내는 쪽이라 신경안써도 되려나?

'프로그램 사용 > libmodbus' 카테고리의 다른 글

mbpoll  (0) 2025.08.06
libmodbus pi 함수들  (0) 2022.05.10
libmodbus modbus_mapping_new()  (0) 2022.05.10
libmodbus poll 적용  (0) 2022.05.04
modbus tcp  (0) 2022.05.04
Posted by 구차니

옥션에서 먼가 구매하려고 보다 보니

NTAG 213 / 215를 따로 팔고 있길래 먼가 해서 검색

얘는.. RFID 리더는 못 읽고 NFC 리더에서만 읽을수 있으려나?

 

NTAG203 : 보급형,  137 bytes , 다양한 형태로 사용이 가능하다.
NTAG212 : 메모리사이즈가 128 bytes. NTAG203를 개선하여 속도나 거리에서 개선된 제품.
NTAG213 : 읽기 속도 개선, 메모리 사이즈가 144 bytes. 암호 보호, 가격도 싸고 성능도 좋다.
NTAG215 : 메모리 사이즈가 504 bytes, 암호 보호 기능 강화.
NTAG216 : 메모리 사이즈가 888 bytes. 속도는 빠르나 가격이 비싸다.

[링크 : https://blog.naver.com/iamsmartin/220727540584]

 

14443 Type A 를 충족한다고 하면 acr1252u 로도 읽힐 것 같네?

NTAG® 213/215/216: NFC Forum Type 2 Tag Compliant IC with 144/504/888 Bytes User Memory

NTAG 213, NTAG 215, and NTAG 216 have been developed by NXP® Semiconductors as standard NFC tag ICs to be used in mass-market applications such as retail, gaming, and consumer electronics, in combination with NFC devices or NFC-compliant Proximity Coupling Devices. NTAG 213, NTAG 215, and NTAG 216 (from now on, generally called NTAG 21x) are designed to fully comply to NFC Forum Type 2 Tag and ISO/IEC14443 Type A specifications.

[링크 : https://www.nxp.com/products/NTAG213_215_216]

'하드웨어 > rfid_nfc_smartcard' 카테고리의 다른 글

ntag 213, 215 그리고 13.25MHz CUID 카드  (0) 2025.03.17
SCardListReadersA 함수(winscard.h)  (0) 2025.03.17
NDEF 읽기  (0) 2025.03.11
mifare desfire 인증 프로세스  (0) 2025.03.11
libnfc, libfreefare  (0) 2025.02.28
Posted by 구차니
개소리 왈왈/컴퓨터2025. 3. 11. 23:10

요즘껀 더 얼마나 좋을까 궁금하면서도

이정도의 성능을 개인이 가지는게 옳은가? 라는 고민도 든다.

 

나름 쓰레드리퍼인데 2017년 3분기 나온녀석을, 2021년에 나온 모바일 cpu가 웬만큼 따라잡아 버린다.

(그래서 중고로 가져볼까 하다가 내 노트북이 전기소모등 몇배 낫네! 싶어서 마음을 비우게 됨)

올 코어 터보 때문인지(PBO?) 코어 갯수는 같지만 풀 코어 벤치하면 간격이 벌어지긴 하는데

 

[링크 : https://cpu.userbenchmark.com/Compare/AMD-Ryzen-TR-1900X-vs-AMD-Ryzen-7-5800U/m340638vsm1433044]

 

TDP 로만 따지면 노트북 쪽이 넘사벽..도대체 4년 사이에 무슨일이...(!)

[링크 : https://technical.city/en/cpu/Ryzen-Threadripper-1900X-vs-Ryzen-7-5800U]

'개소리 왈왈 > 컴퓨터' 카테고리의 다른 글

케이블 도착  (2) 2025.03.26
미니랩 프로토타이핑  (0) 2025.03.19
모니터 줍줍  (0) 2025.03.03
10g NIC 도착  (0) 2025.02.24
mx4 4g 써멀 지름  (0) 2025.02.24
Posted by 구차니

아니.. chatGPT로는 못했는데 claude 만세 -_ㅠ

 

What are these commands?
The first command (90 60 00 00 00) is a MIFARE DESFire GetVersion command (wrapped command set). This seems to be specific to the NXP-based Android NFC stack and is not part of a typical NFC tag detection procedure.
The second command (00 A4 04 00 07 D2 76 00 00 85 01 01 00) is a SELECT APDU that tries to select the NFC Forum Type 4 tag application (version 2.0) by its AID. This is part of the typical tag detection procedure for ISO 14443-4 (ISO-DEP) based tags/smartcards.
Why are these commands sent before apps are notified about the presence of a tag and even if no app is active at all?
A typical NFC device will automatically discover the presence of NFC tags that contain NDEF messages. Usually such NDEF messages then trigger actions on the device (e.g. start an app). As your tag seems to be an ISO 14443-4 (ISO-DEP) compliant tag/smartcard, the NDEF discovery procedure for an NFC Forum Type 4 tag is started. This procedure normally contains of the following steps:
  1. Select the NFC Forum Type 4 tag application (version 2.0)
  2. If application selection is successful, continue with reading the capability container file and the NDEF data file.
  3. If application selection fails, continue with selecting the NFC Forum Type 4 tag application (version 1.0)
  4. If application selection is successful, continue with reading the capability container file and the NDEF data file.
  5. If application selection fails, tag is not an NFC Forum Type 4 tag.
  6. Typically the connection to the tag is reset at this point so that any communication that an app performs with a tag is started right after a fresh activation of the tag.
The additional command before step 1 indicates that the NXP's NFC stack additionally tries to find out if the Type 4 tag is an NXP product (NXP's MIFARE DESFire or DESFIRE EV1). It is not related to peer-to-peer mode protocols.
Remark on the Broadcom NFC stack: There is a known issue that seems to still exist on Android 4.4: Even after the tag is passed to an app and the app started IsoDep communication the NFC stack arbitrarily sends READ BINARY commands interleaved with the app's communication. This frequently results into protocol errors due to invalid command sequences. This does not happen with NXP's NFC stack.
Can I prevent this initial processing of a tag?
Yes, but only since Android 4.4. On that platform you can use the NfcAdapter's enableReaderMode method to bring the device into a reader mode without NDEF discovery.

[링크 : https://stackoverflow.com/questions/21121149/bytes-automatically-send-by-android-nfc-to-an-emulated-card]

 

8. MIFARE DESFire EV1 GetVersion command 1
Command: 90 60 00 00 00h
Expected Response: XX XX XX XX XX XX XX 91 AFh

9. MIFARE DESFire EV1 GetVersion command 2. The Storage Size code (SS) value indicates the storage size, in particular: 1Ah indicates 8192 bytes, 18h indicates 4096 bytes and 16h indicates 2048 bytes
Command: 90 AF 00 00 00h
Expected Response: XX XX XX SW XX SS XX 91 AFh

10. MIFARE DESFire EV1 GetVersion command 3
Command: 90 AF 00 00 00h
11. Expected Response: XX XX XX XX XX XX XX XX XX XX XX XX XX 91 00

[링크 : https://www.nxp.com/docs/en/application-note/AN11004.pdf]

'하드웨어 > rfid_nfc_smartcard' 카테고리의 다른 글

SCardListReadersA 함수(winscard.h)  (0) 2025.03.17
NTAG  (0) 2025.03.12
mifare desfire 인증 프로세스  (0) 2025.03.11
libnfc, libfreefare  (0) 2025.02.28
ATQA, SAK  (0) 2025.02.28
Posted by 구차니