Skip to content

Commit 980529c

Browse files
committed
minor: Change 6SC2-CarRemote to MIC6SC2-CarRemote
1 parent c9e8eb2 commit 980529c

4 files changed

Lines changed: 14 additions & 14 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ See [CONTRIBUTING.md](./docs/CONTRIBUTING.md).
397397
[309] Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (No Sync, 1667 bit/s)
398398
[310] Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (PIWM, 2500 bit/s)
399399
[311] Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (PIWM, 5000 bit/s)
400-
[312] 6SC2 Car Remote (-f 315.1M)
400+
[312] MIC 6SC2 Car Remote (-f 315.1M)
401401
[313] GM ABO1502T Car Remote (-f 314.9M)
402402
[314] Siemens 5WY72XX Car Remote (-f 315.1M)
403403
[315] Alps FWB1U545 Car Remote

conf/rtl_433.example.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ convert si
550550
protocol 309 # Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (No Sync, 1667 bit/s)
551551
protocol 310 # Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (PIWM, 2500 bit/s)
552552
protocol 311 # Microchip HCS361 KeeLoq Hopping Encoder based remotes (-f 315.1M) (PIWM, 5000 bit/s)
553-
protocol 312 # 6SC2 Car Remote (-f 315.1M)
553+
protocol 312 # MIC 6SC2 Car Remote (-f 315.1M)
554554
protocol 313 # GM ABO1502T Car Remote (-f 314.9M)
555555
protocol 314 # Siemens 5WY72XX Car Remote (-f 315.1M)
556556
protocol 315 # Alps FWB1U545 Car Remote

src/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ add_library(r_433 STATIC
4343
sdr.c
4444
term_ctl.c
4545
write_sigrok.c
46-
devices/6sc2.c
4746
devices/abmt.c
4847
devices/acurite.c
4948
devices/acurite_01185m.c
@@ -200,6 +199,7 @@ add_library(r_433 STATIC
200199
devices/maverick_xr50.c
201200
devices/mebus.c
202201
devices/megacode.c
202+
devices/mic6sc2_car_remote.c
203203
devices/missil_ml0757.c
204204
devices/mueller_hotrod.c
205205
devices/neptune_r900.c
Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/** @file
2-
6SC2 - Car Remote.
2+
MIC 6SC2 - Car Remote.
33
44
Copyright (C) 2024 Ethan Halsall
55
@@ -12,10 +12,10 @@
1212
#include "decoder.h"
1313

1414
/**
15-
6SC2 - Car Remote (315 MHz).
15+
MIC 6SC2 - Car Remote (315 MHz).
1616
1717
Manufacturer:
18-
- Unknown
18+
- Unknown, MSOP-10 perhaps from MIC (Master Instrument Corporation)
1919
2020
Supported Models:
2121
- 6SC2 CMGU
@@ -58,20 +58,20 @@ static int six_sc_two_car_remote_decode(r_device *decoder, bitbuffer_t *bitbuffe
5858
return DECODE_ABORT_LENGTH;
5959
}
6060

61-
uint8_t *bytes = bitbuffer->bb[row];
61+
uint8_t *b = bitbuffer->bb[row];
6262

63-
if (bytes[0] != 0x55 || bytes[1] != 0x54) {
63+
if (b[0] != 0x55 || b[1] != 0x54) {
6464
return DECODE_FAIL_SANITY;
6565
}
6666

67-
if (xor_bytes(bytes + 2, 9)) {
67+
if (xor_bytes(b + 2, 9)) {
6868
return DECODE_FAIL_MIC;
6969
}
7070

7171
// The transmission is LSB first, big endian.
72-
uint32_t encrypted = (uint32_t)reverse8(bytes[5]) << 24 | (uint32_t)reverse8(bytes[4]) << 16 | (uint32_t)reverse8(bytes[3]) << 8 | reverse8(bytes[2]);
73-
int button = reverse8(bytes[6]) & 0xf;
74-
int sequence = (reverse8(bytes[8]) << 8) | reverse8(bytes[7]);
72+
uint32_t encrypted = (uint32_t)reverse8(b[5]) << 24 | (uint32_t)reverse8(b[4]) << 16 | (uint32_t)reverse8(b[3]) << 8 | reverse8(b[2]);
73+
int button = reverse8(b[6]) & 0xf;
74+
int sequence = (reverse8(b[8]) << 8) | reverse8(b[7]);
7575

7676
char encrypted_str[9];
7777
snprintf(encrypted_str, sizeof(encrypted_str), "%08X", encrypted);
@@ -90,7 +90,7 @@ static int six_sc_two_car_remote_decode(r_device *decoder, bitbuffer_t *bitbuffe
9090

9191
/* clang-format off */
9292
data_t *data = data_make(
93-
"model", "model", DATA_STRING, "6SC2-CarRemote",
93+
"model", "model", DATA_STRING, "MIC6SC2-CarRemote",
9494
"encrypted", "", DATA_STRING, encrypted_str,
9595
"button_code", "Button Code", DATA_INT, button,
9696
"button_str", "Button", DATA_STRING, button_str,
@@ -114,7 +114,7 @@ static char const *const output_fields[] = {
114114
};
115115

116116
r_device const six_sc_two_car_remote = {
117-
.name = "6SC2 Car Remote (-f 315.1M)",
117+
.name = "MIC 6SC2 Car Remote (-f 315.1M)",
118118
.modulation = OOK_PULSE_MANCHESTER_ZEROBIT,
119119
.short_width = 250,
120120
.reset_limit = 10000,

0 commit comments

Comments
 (0)