To verify the working of my own receiver I tested some transmitters and the LEGO receiver. 

갖고있는 리시버가 제대로 동작하는지 확인하기 위해

몇개의 트랜스미터랑 레고 리시버를 테스트한다

Below are some results from measurements.

아래에는 분석한 결과들이다

All measurements of IR data were made using a TSOP4136 receiver 

and viewing the output on my scope.

TSOP4136리시버로 분석하고 내 스코프에 분석된 모든 IR결과를 보여준다



--------------------------------

Which transmitter uses which commands?

트랜스미터가 사용하는 명령어(command)는?

8879 (dual jog)

8879 (듀얼 조그)

This remote uses ‘increment PWM’ and ‘decrement PWM’ commands from Single Channel Mode 

when jog wheels are turned. 

조그휠이 돌아가면 'PWM증가'나 'PWM감소' 명령이 싱글채널모드에서 동작한다


when only one ‘stop’ button is pressed this is sent using the ‘Brake Then Float’ command 

from Single Channel Mode (PWM mode), 

한개의 '스톱'버튼이 눌려지면 'Brake Then Float'명령어를 사용하여 전송한다. 

싱글채널모드에서(PWM모드)


when both ‘stop’ buttons are pressed  Combo Direct Mode is used with both channels set 

as ‘Brake Then Float’.

두개의 '스톱'버튼이 눌려지면 '콤보 다이렉트모드'는 두 채널과 함께 사용된다. 'Brake Then Float'처럼 설정되어...


---------------------------------

8885 (dual joystick)

8885 (듀얼 조이스틱)

This remote uses Combo Direct Mode for all commands. 

이방식은 모든 명령어(command)를 콤보 다이렉트모드를 사용한다.

This remote sends the joystick state continuously if one of the joysticks is used. 

이것은 하나의 조이스틱이 사용되면 조이스틱의 상태를 계속 보낸다 

I found it remarkable that it sent the command ‘float’ to the output 

이것 'float' 명령을 출력으로 보낸다는것을 찾아냈다.

when the joystick was released, as this is the default action if a timeout happens 

조이스틱이 릴리스되면 타임아웃이 일어났을때 처럼 기본액션같다면

(i.e. when no joystick is pressed or when IR reception is interrupted).

(예를들어, 조이스틱이 아무것도 눌려지지 않았거다 IR 수신이 방해받았을 때)

Edit: at first I assumed that missing one IR message would cause a timeout. 

Then Philo  pointed out that it takes more than a second to timeout, 

so the float command DOES make sense!

주 : 처음 가정하기를 하나를 놓쳤다. IR메세지의 원인이 타임아웃일거라는.

그런데 필로가 지적해줬다 그것이 1초보다 더 걸렸다고.

그래서 float 명령이 맞아떨어졌다

(이게 당췌 뭔뜻인지...)


----------------------------------

IR Transmission timing

IR전송 시점(타이밍)

On the last page of the LEGO IR specification a lot of figures 

and text is dedicated to a very nice timing schedule 

많은 기능들과 글자로 정의된 매우 멋진 타이밍스케줄이 

레고 IR 스펙에 마지막페이지에 있다

where the outputs of different transmitters do not overlap in time

when several channels transmit at the same time 

여러 채널에서 같은 전송이 동시에 일어날 때

거기에 서로다른 트랜스미터의 출력들을 시간내에 겹치지 않아야 한다 


(see the spec for a clearer choice of words ;) ) . 



Although this scheme is very nice, 

물론 이 방법은 꽤 좋다

it is not implemented in both measured PowerFunction transmitters.

이것은 구현되지 않았다. 파워평션 트랜스미터에서



Upper drawing: from norm. 

상단 그림 : normal(일반?)

Lower drawing: how LEGO remotes are implemented 

하단 그림 : 레고 리모트가 구현됨

(not to scale, just illustrating the difference in timing principle)

(스케일이 아니라 타이밍규칙에서 다르게 그려짐)



------------------------------

The time between messages is increasing at higher channel numbers, but the delay is fixed;

메세지 사이의 시간은 증가한다 가장 높은 채널 번호들에서 하지만 지연(delay)는 정해져있다. 

the spec describes a different time delay between message 1-2, 2-3 

and message 3-4,4-5 and 5  to subsequent messages. 

스펙에서는 메세지 1-2, 2-3과 메세지 3-4,4-5 그리고 5 사이의 다른 시간 지연(delay)은 다음 메세지로 간다


Only one delay time is used in the ‘real’ transmitters. 

오직 한 지연(delay)시간은 '실제(real)' 트랜스미션 안에서 사용된다


At first I thought the delay between messages would dictate the timeout time 

for the receiver 

처음에 생각하기를 메세지들 사이의 지연(delay)은 리시버의 타임아웃을 위해 나뉠것이다 

(some functions have timeout, 

which means that if no IR messages arrive anymore, 

the output is turned off). 

몇몇 기능들은 타임아웃이 있다

그 의미는 IR메세지들이 더이상 도착하는게 없으면 출력은 꺼진다



My assumption was that missing one message would ‘time out’ the receiver,

내 가정은 잃어버린 한 메세지는 리시버에서 '타임아웃'일 것이다 

but later I found that the timeout  is given as 1.2s. 

하지만 나중에 찾은 타임아웃은 1.2초로 주어졌다

This also clarifies the transmission of ‘output float’ by the joystick transmitter,

이것으로 조시스틱 스랜스미터의 "outof float"의 전송은 분명해졌다

that makes the receiver more responsive that waiting for a timeout.

그것이 리시버를 타임아웃을 대기하여 더 응답하게 만든다

Values below were measured from startbit to startbit for both power functions transmitters.

아래에 측정된 값들은 시작비트(startbit)사이에서 두개의 파워펀션트랜스 미터들이다



 오늘은 졸려서 여기까지 ㅠㅠ


------------- 2차

Characterization IR Receiver

IR 리시버 정의하기


After I implemented the firmware for my own receiver 

내 리시버를 위해 펌웨어를 올린 뒤에

I wanted to check some properties of the LEGO IR Receiver. 

나는 레고 IR리시버의 몇가지 속성을 체크하고 싶었다


One of Tkkrlab‘s members owns the 8884 LEGO receiver 

Tkkrlab의 한 멤버가 8884 레고 리시버를 갖고 있었다

so I was able to see what exactly the LEGO receiver is doing. 

그래서 레고리시버가 어떻게 동작하는지 제대로 볼 수 있었다


This was very interesting; 

이것은 매우 흥미롭다

the LEGO norm is sometimes not completely clear in how things should be implemented. 

레고 늠은 때때로 어떤 것이 설치됨에 따라 완전히 클리어(제대로 동작)하지 않는데

Verifying with the ‘original’ receiver showed some inconsitensies, 

and raised some questions.


오리지날 리시버도 아래 대로 검사해보니 

몇몇 일관되지 않는 결과를 보여주고 궁금중이 생겼다


PWM, frequency, duty cycle and number of steps

PWM, 주파수, 동작사이클, 스텝의 수


The first step was looking at the output PWM frequency. 

첫번째 단계는 PWM 주파수를 살펴봤다

I monitored the ‘C1′ and ‘C2′ signals which drive the motor

나느 드라이브 모터의 C1과 C2 신호를 모니터했다


The used PWM frequency is 1150Hz. 

그것의 PWM 주파수는 1150Hz였다.


I’m using 13kHz myself (necessary to enable servo control from same timer), 

내꺼는 13KHz를 쓰는데(같은 시간에 servo조작이 가능함은 필수다)


I’ll have to see if this gives any change in power efficiency.

나는 전원가지고 몇가지 변경을 주어 결과를 봐야했다



DutyCycle, jog remote control

DutyCycle(동작주기), 조그 리모컨


Next, I used the 8879 ‘speed remote control’ to step through the PWM cycles. 

다음으로 나는 8879의 '속도조절'을 사용해 PWM 사이클을 살펴봤다


First, a bit of background info. 

첫째로 작은 배경지식하나.

I read the LEGO protocol document, and in all PWM descriptions the description 

레고 프로토콜 문서안의 모든 PWM설명에는

‘PWM 1′ to ‘PWM 7′ are used between stop and full throttle. 

PWM1에서 PWM7은 멈춤과 모두사용 스로틀(밸브)를 사용한다


These are PWM values (duty cycles) I recorded when moving the jog forward / backward

조그를 앞으로/뒤로 움직일 때 내가 기록한 PWM 값들은(동작주기는) 


Now this is weird; 

결과는 조금 이상하다

first of all, 

첫째로

we’re seeing that only 6 levels of PWM are used. 

PWM은 그저 6레벨만 사용하는것을 볼 수 있다

This is not only unexpected from the documentation, 

이것은 문서에 적혀있는 내용과는 달랐다

it is also giving less resolution for control to the users. 

또한 사용자들이 제어(control)하는데 적은 결정사항을 준다.

(결국 문서와는 달리 6가지 레벨만 사용가능하다는 거구만?)


Secondly, 

둘째로

the PWM is starting at 26%. 

PWM은 최소한 26%에서 시작한다

Why? I plotted the percentages, 

왜냐면 나는 퍼센테이지를 나열해봤다(플롯을 짜봤다)


and it seems that the fist step (13%) seems to be missing, for some reason. Weird.

그리고 그것은 이상하게도 몇가지 이유에 의해

첫번째 스템(13%)에서는 동작하지 않는것으로 보였다(missing)


Edit:  Philo pointed out that 

Edit: Philo가 다음사항을 지적해줬다.

in large builds the friction in the motor +  attached drive chain might be too large. 

커다란 빌드 안에서 모터안의 마찰(friction) + 부착된 드라이브 체인이 너쿠 컸다


To be sure that 

확실히 하기위해

the motor doesn’t stall at low PWM values this first step might  have been skipped. 

모터는 낮은 PWM값에서 한칸(stall)이 아니었다. 이 첫번째 단계는 아마 스킵되었나보다


In my receiver I do not skip it, 

내 리시버는 스킵하지 않았다

I’m guessing that lighter loads will be used, 

나는 낮은 부하에서 사용되었을거라고 추측하고

and I’d like to be able to give more control of PWM or servo position 

with the original remote.

원래 리모컨으로 PWM이나 servo 위치의 몇가지 제어(control)를 추가하고 싶었다.


Edit 2: Indeed I found that with lower voltages (7V) 

the first step of PWM generation gives very little torque. 

Edit 2: 사실 나는 낮은전압(7V)을 찾았다

PWM 세대(generation)의 첫번째 단게에서 아주 작튼 토크다


BUT: when you return from a higher PWM ratio, 

it gives you the possibility to let the motor ‘coast’ for a while.

“Brake then Float”


BUT: 더 높은 PWM 비율(ratio)에서 돌아왔을 때, 

그것은 잠시동안 모터 'coast'에 "Brake then Float"(딱점에서 멈춤??)의 가능성을 준다.

In the protocol, 

프로토콜에 따르면

two ways of disabling the motor are mentioned: 

모터를 정지(disabling)시키는데에는 두가지 방법이 있다

‘float’ and ‘Brake then float’. 

'float'와 'Brake then float'이다


With an H-bridge motor controller, 

both ‘float’ and ‘brake’ can easily be implemented, 

H-bridge 모터 컨트롤러에서 'float'과 'brake'는 쉽게 장착할 수 있다


but the timing for ‘brake then float’ was not described in the protocol. 

하지만 프로토콜에서는 'brake then float'에 타이밍은 설명되지 않았다


I struggled a bit myself with this feature,

나는 이 기능에서 분투했다 

because all other messages (PWM, direct pin control, float, full forward / backward)

 can be turned into output signals to the H-bridge without memorizing previous states. 

왜냐하면 모든 다른 메세지(PWM, 직접 핀제어, float, 전진/후퇴)는 

출력신호에서 H-bridge까지 이전상태의 기억없이   바뀔수 있다



The ‘brake then float’ state should take care that the receiver first brakes, then floats.

'brake then float' 상태는 첫번째 brake(로) 관리해야한다. 그러면 float이다

 

But then again,  how long should you brake? 

히지만 다시하면 얼마나 오랫동안 'brake'해야하는가?


Also, when floating and receiving a ‘brake then float’ command (red button on 8879 remote),

 should you brake again? Questions, questions. 

물론 floating과 수신(receiving)할 때 하나의 'brake then float' 명령(8879리모컨의 빨간버튼)은

brake를 다시 해야하는가? 질문들. 질문들.(질문만 늘어가는구만)


I connected a 5V supply to the C1 and C2 connections, current limited by 2 12kOhm resistors.

나는 5V를 공급하도록 C1과 C2연결사이에 연동했다, 2개의 12K옴저항이 현재 제한이다 

Now, the receiver could pull low, drive high, and float. 

지금 리시버는 낮음으로 끌어내리고(pull low), 높음으로 올리고(drive high), float이 가능하다


‘Float’ would mean both outputs were going to 5V, 

'Float'는 5V로가는 두가지 출력을 의미한다

brake would mean both outputs would be going to GND.

brake는 GND로 가는 두가지 출력을 의미한다

I captured a series of remote control actions in one picture to show what happens.

나는 리모콘의 액션의 연속을 한장의 그림으로 캡쳐해서 어떤 변화가 일어나는지 보여주겠다.


1. we’re coming from a ‘brake’ situation

1. 우리는 'brake' 상태에서 시작한다

2. Gradually moving forward and backward with jog knob, motor keeps running forward. 

   조그 손잡이(knob)로 점차 앞으로 그리고 점차 뒤로 움직이고 모터는 앞으로 동작을 계속하면

(모터방향이 앞으로고 조그로 왔다갔다)

PWM details are lost in the limited scope resolution

 제한된 범위(scope) 솔루션에서 PWM 세부사항들은 사리진다(리미티드 스코프 리솔루션에서 PWM 상세 조건들 몇개를 알 수 없다는 얘기인가)


3. Transition from going forward to backward; 

전진(forward)에서 후진(backward)로가는 전이; 

here the receiver ‘floats’ the output, it is neither pulled to GND nor pulled to battery voltage!

여기 리시버는 'floats' 출력이다, 이것은 GND로 당기지도 배터리 볼터로 당기지도 않는다


4. Gradually moving forward and backward with jog knob, motor keeps running backward

조그 손잡이로 점차 앞으로 점차 뒤로 움직이고 모터가 뒤로 계속 동작하면고 

(모터방향이 뒤로이고 조그로 왔다갔다)


5. Again transition to running forward, floating

  다시 전진으로 전이, floating


6. Running forward in PWM

   PWM에서 전으로 동작시킨다


7. Stop button pressed-> braking, and NOT going to float!

   정지버튼이 눌리고 -> braking(멈춤), 그리고 float로는 가지 않음


8. Going backward with 8885 remote control; full throttle

   8885리모콘 뒤로가도록 ; full throttle(밸브를 최대로)

9. Release joystick, output is floating

   조이스틱을 푼다(Release), 출력은 floating

10. Going forward with 8885 remote control; full  throttle

   8885리모콘 앞으로가도록; full throttle

11.Release joystick, output is floating

   조이스틱을 푼다(release), 추력은 float



Now what have we learned? 

우리가 배운게 무엇이냐

The LEGO engineers were probably confused themselves aswell 

레고의 엔지니어들도 아마 잘 헤깔린다는거


by the protocol description and did not implement a float action after a brake. 

프로토콜 설명과 아직 구현되지 않은 하나의 brake이후의 float 액션이


You don’t need a scope to verify this, 

당신은 이것을 검증하려고 스콥은 필요하지 않다

given that you’ve got both remotes 

당신이 가지고 있는 두개의 리모컨으로 -> 

-> try to rotate the axle of a (LEGO) motor after stopping;

한개의 (레고)모터가 멈춘뒤에 축을 돌려보려고 해 봐라;

 in ‘float’  it rotates with less friction than in ‘brake’. 

'float'에서는 그것이 'brake'일 때보다 적은 마찰로 돈다(rotates)

('brake'는 'break'의 과거형임)


For your information, 

my remote receiver DOES implement a brake, 

and then a float <grudge mode on>

내 리모트 리시버는 brake에서 장작되지 않는다

그리고 그러면 하나의 float <grudge 모드가 온>으로 된다

because I didn’t know the LEGO implementation in advance 

왜냐하면 나는 레고 장착을 먼저 알 수 없다

and spent quite some time programming this…<grudge mode off>.

그리고 <grude mode 오프>를 하는데 꽤 시간을 보냈다



728x90
나의 손길을 며칠째 기다리고 있는것들
(택배로 온 지 벌써 일주일가까이 되었다 ㅋ)
과연 제작자의 의도대로 만들어 질 것인가




iPhone 에서 작성된 글입니다.
728x90


나의 35번째 생일.
축하해 주는 사람들이 많아서
(회사에서 늦게까지 일하고 왔지만) 행복하네~~
어제부터 손수 미역국과 갈비찜,잡채에서부터 오늘 저녁으로 케익과 직접만든 지갑까지 1빅2일에 걸친 이벤트를 한 MJ에게 무한한 감사와 종진이, 중찬행님, Djo, Aubree, 그리고 부모님 고맙습니다

thank you ~~


생일상 ㅋ

iPhone 에서 작성된 글입니다.
728x90

이사하는 날

2013. 11. 9. 01:13
어디보자 ...
2005년부터 살았으니 한 8년정도 살았구나.
처음엔 작은누나와 살다가 2008년에 잠깐 나갔다오고 나서
지금까지
집이란 그저 잠자는 곳이라는 생각이지만 그래도 내집이라는 쉼터가 있어 마음은 늘 든든했다.
누구 눈치 볼 것도 없고 타의로 집을 나가야하는 경우도 없고
뉴스에서 나오는 부동산 얘기에서 자유로와서 좋았다.
새로운 집으로 가면서 보니 참 집을 어지럽게 쓴 것 같고
제대로 청소도 안해서 좀 미안하다
큰 불만없이 지내다 작년에 차를 사면서 고민에 빠졌다.
주차공간의 부족인데 그러다 더 큰집으로 가기로하고 진행하고나니 이사하기로 결정(계약)하니까 잔금이 모자르다 ㅠㅠ
회사에서의 대출이 나왔으면 딱이었는뎅... 결국 모자란 돈은 차를 팔아서 메꿔야만 했다.
애초에 주차때문에 이사를 생각했는데
이사하려니 차를 팔아야했다는...
어쨌거나 앞으로 잘 살면 되겠지
이제 눈을 감았다 뜨면 이삿짐센터 사람들이 올 것이고 그들차에 내 몸을 싣고 새 집으로 가겠지
그래도 송내집 너에게 참 고맙다
이 말은 남기고 갈께 ㅎ 잘자

iPhone 에서 작성된 글입니다.
728x90

파이도착

2013. 11. 8. 18:48
파이가 배달됐다 
지난주 토요일 주문했는데...
주소를 한글로 써놨더니 모르겠다며 메일을 보내왔다 ㅡㅡ 
다시 영어로 보내서 오늘 도착


그나마 재성이형이 책 한 권 줬으니 그걸로 공부

근데... 메모리를 안끼워놔서...쩝


itistory-photo-1



itistory-photo-2




iPhone 에서 작성된 글입니다.




728x90
BLOG main image
"그게 뭐 어쨌다는 거냐?" 늘 누가 나에게 나에대한 말을할 때면 이말을 기억해라. by nobang

카테고리

nobang이야기 (1933)
Life With Gopro (7)
Life With Mini (79)
Diary (971)
너 그거 아니(do you know) (162)
난 그래 (159)
Study (290)
속지말자 (10)
Project (34)
Poem (15)
Song (0)
Photo (113)
낙서장 (45)
일정 (0)
C.A.P.i (2)
PodCast (0)
nobang (27)
고한친구들 (4)
recieve (0)
History (0)
android_app (2)

최근에 올라온 글

최근에 달린 댓글

최근에 받은 트랙백

Total :
Today : Yesterday :