Up-Link for ER9X [Magi(C)] a vision...
Up-Link for ER9X [Magi(C)] a vision...
Down link exists (telemetry), but there is no solution up link to it!
The non-time-critical applications have an idea. Modulated signal of one PWM channel with serial data.
Thus, a channel can be controlled by many switch. I've given it a name as well:
The transmission would certainly be slow, but in many applications this is not critical.
In return, we do not use the normal fast PWM to these ports. Only one!
The focus should be on the PWM Modulation!
State 1.
This is logic 0.
State 2.
This is logic 1.
Sure to be a dead zone is not what we interpret.
An example of a possible data transmission:
Of course, the final protocol also refine necessary!
The decoder could the open project!
I can handle it with PIC.
The ER9X side of the program, however, only you know!
Sorry, my English very bad.
The non-time-critical applications have an idea. Modulated signal of one PWM channel with serial data.
Thus, a channel can be controlled by many switch. I've given it a name as well:
The transmission would certainly be slow, but in many applications this is not critical.
In return, we do not use the normal fast PWM to these ports. Only one!
The focus should be on the PWM Modulation!
State 1.
This is logic 0.
State 2.
This is logic 1.
Sure to be a dead zone is not what we interpret.
An example of a possible data transmission:
Of course, the final protocol also refine necessary!
The decoder could the open project!
I can handle it with PIC.
The ER9X side of the program, however, only you know!
Sorry, my English very bad.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
- MikeB
- 9x Developer
- Posts: 17990
- Joined: Tue Dec 27, 2011 1:24 pm
- Country: -
- Location: Poole, Dorset, UK
Re: Up-Link for ER9X [Magi(C)] a vision...
I had thought about this myself. There is a problem with timing between the rate at which er9x sends the PPM frame, the rate at which it is sent to the Rx and the rate at which it is sent out by the Rx. There might also be the occasional loss of a transmission from the Tx module to the Rx.
I think we could encode more than 1 bit in a single PPM pulse, I reckon we could get 4 bits into a pulse, together with some control values. So pulse widths of (in uS):
1000 logic 0000
1050 logic 0001
1100 logic 0010
1150 logic 0011
1200 logic 0100
1250 logic 0101
1300 logic 0110
1350 logic 0111
1400 logic 1000
1450 logic 1001
1500 logic 1010
1550 logic 1011
1600 logic 1100
1650 logic 1101
1700 logic 1110
1750 logic 1111
1800 control 1
1850 control 2
1900 control 3
1950 control 4
2000 control 5
Now we send a new value pulse every (say) 100mS. This will allow several transfers from the Tx module to the Rx, and the pulse to appear on the Rx output several times. We use a control value as a 'clock', so we send something like:
control 1 - start of frame
4 bits of data
control 2 - clock
4 bits of data
control 3 - check follows
complement of first 4 bits of data
control 2 - clock
complement of second 4 bits of data
control 4 - end of frame
control 5 - idle, nothing to send or control 1 - start of next frame
So we send 8 bits of data every second (or 0.9 second), with a sort of checksum.
We may be able to send more frequently than every 100mS, maybe every 50mS. If the pulse widths are too close together, we could reduce the number of bits in a pulse to 3 or 2 and send more data pulses to get a byte.
Mike.
I think we could encode more than 1 bit in a single PPM pulse, I reckon we could get 4 bits into a pulse, together with some control values. So pulse widths of (in uS):
1000 logic 0000
1050 logic 0001
1100 logic 0010
1150 logic 0011
1200 logic 0100
1250 logic 0101
1300 logic 0110
1350 logic 0111
1400 logic 1000
1450 logic 1001
1500 logic 1010
1550 logic 1011
1600 logic 1100
1650 logic 1101
1700 logic 1110
1750 logic 1111
1800 control 1
1850 control 2
1900 control 3
1950 control 4
2000 control 5
Now we send a new value pulse every (say) 100mS. This will allow several transfers from the Tx module to the Rx, and the pulse to appear on the Rx output several times. We use a control value as a 'clock', so we send something like:
control 1 - start of frame
4 bits of data
control 2 - clock
4 bits of data
control 3 - check follows
complement of first 4 bits of data
control 2 - clock
complement of second 4 bits of data
control 4 - end of frame
control 5 - idle, nothing to send or control 1 - start of next frame
So we send 8 bits of data every second (or 0.9 second), with a sort of checksum.
We may be able to send more frequently than every 100mS, maybe every 50mS. If the pulse widths are too close together, we could reduce the number of bits in a pulse to 3 or 2 and send more data pulses to get a byte.
Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
The difficult we do immediately,
The impossible takes a little longer!
Re: Up-Link for ER9X [Magi(C)] a vision...
Sort of like Mike's suggestions, here's my input: Instead of an 8-bit word I'd truncate it down to 4-bit (16 on/off devices) to reduced the overhead time. Also it may help to use 2.0mS for start, 1.0ms for stop, 1.75ms for logic one and 1.25ms for logic zero. This would allow a more relaxed asynchronous decoding. A parity bit (versus Checksum) might be sufficient data protection if the expanded channels were not critical.
Before involving the ER9X side software this idea can be fully prototyped with a dedicated microcontroller doing the work in the Tx. BTW, there was a commercial 16-32 channel expander product for Futaba PCM Tx's that was sold years ago. Too bad I don't have any technical details to offer because it would have been great to not have to re-invent this wheel.
- Thomas
Before involving the ER9X side software this idea can be fully prototyped with a dedicated microcontroller doing the work in the Tx. BTW, there was a commercial 16-32 channel expander product for Futaba PCM Tx's that was sold years ago. Too bad I don't have any technical details to offer because it would have been great to not have to re-invent this wheel.
- Thomas
- MikeB
- 9x Developer
- Posts: 17990
- Joined: Tue Dec 27, 2011 1:24 pm
- Country: -
- Location: Poole, Dorset, UK
Re: Up-Link for ER9X [Magi(C)] a vision...
Not sure how you get 16 on/off devices from 4 bits, that is only 4 on/off bits.
Decoding for my suggestion is:
(PULSE_WIDTH - 975) / 50
gives you an integer result from 0 to 20. 0 to 15 is data, 16 to 20 is control.
Mike.
Decoding for my suggestion is:
(PULSE_WIDTH - 975) / 50
gives you an integer result from 0 to 20. 0 to 15 is data, 16 to 20 is control.
Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
The difficult we do immediately,
The impossible takes a little longer!
Re: Up-Link for ER9X [Magi(C)] a vision...
I think you would easily be able to get ten channels at 100 microsecond intervals out of the pulse as it is, if you want confirmation of the command just compare a number of samples, before execution.
“A good politician is quite as unthinkable as an honest banker”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
Re: Up-Link for ER9X [Magi(C)] a vision...
Good idea!
The deterioration of the reception remain off frames?
If you stay out of frame, then upset the control + data pairs.
Since there is no handshake, such debris should be discarded.
We could simplify the framework and thus speed up the transfer.
ex.:
Control1 = start of low half byte (ex: 1900 ms)
Control2 = start of high half byte (ex: 2000ms)
End= end of frame (1800ms)
data=
1000 logic 0000
1050 logic 0001
1100 logic 0010
1150 logic 0011
1200 logic 0100
1250 logic 0101
1300 logic 0110
1350 logic 0111
1400 logic 1000
1450 logic 1001
1500 logic 1010
1550 logic 1011
1600 logic 1100
1650 logic 1101
1700 logic 1110
1750 logic 1111
Frame:
Control1 + Low_data + End + Control2 + High_data + End
If not received Controlx or End, then drop frame.
The deterioration of the reception remain off frames?
If you stay out of frame, then upset the control + data pairs.
Since there is no handshake, such debris should be discarded.
We could simplify the framework and thus speed up the transfer.
ex.:
Control1 = start of low half byte (ex: 1900 ms)
Control2 = start of high half byte (ex: 2000ms)
End= end of frame (1800ms)
data=
1000 logic 0000
1050 logic 0001
1100 logic 0010
1150 logic 0011
1200 logic 0100
1250 logic 0101
1300 logic 0110
1350 logic 0111
1400 logic 1000
1450 logic 1001
1500 logic 1010
1550 logic 1011
1600 logic 1100
1650 logic 1101
1700 logic 1110
1750 logic 1111
Frame:
Control1 + Low_data + End + Control2 + High_data + End
If not received Controlx or End, then drop frame.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
Code: Select all
Not sure how you get 16 on/off devices from 4 bits, that is only 4 on/off bits.
But your idea is well thought out so it is a very good path to follow.
- Thomas
Re: Up-Link for ER9X [Magi(C)] a vision...
This is not 10 "channels" but 10 "intervals" or "combinations" of which you can extract up to 4 independent on/off channels.Bill wrote:I think you would easily be able to get ten channels at 100 microsecond intervals out of the pulse as it is, if you want confirmation of the command just compare a number of samples, before execution.
To me:
One big question is if this should support any RF link, of if we target it only at "decent" ones (digital).
- In the first case on analog links timing is always respected, but pulse length can be altered so we may get totally wrong data and potentially lower precision on the signal, which would be a pain.
- In the 2nd case we will either get something or get a duplicate of the previous frame, but with great precision and never with wrong data.
If using only digital links, then IMO we can easily get 7-8 bits of data per frame. BUT we have absolutely no temporal information, timing will have a lot of jitter and we may lose frames without being aware of it.
So what I'd do is encode 4 bits of payload data per frame, plus a 2 or 3 bit frame counter. With this we'd get the 2 missing bits of info, i.e. when we have a new frame and not a repeat, and if anything was missed.
Or maybe even use 8 bits and have 4 bit payload, 2 bit frame counter, 2bit word counter. That way we have sync and loss detection, but also the possiblity of recreating 16-bit packets without needing further protocol or framing eating on the payload bandwidth.
Then optimal framerate can be determined by looking at sequences on a logic analyzer. I'd guess between 50 and 100ms per frame would be the maximum achievable knowing that nothing is synced so there will be several stages of aliasing.
- MikeB
- 9x Developer
- Posts: 17990
- Joined: Tue Dec 27, 2011 1:24 pm
- Country: -
- Location: Poole, Dorset, UK
Re: Up-Link for ER9X [Magi(C)] a vision...
How about, to start with, have 5 bits. On er9x/openTx the pulse width is actually from 988 to 2012 uS, a total of range of 1024 uS. 5 bits would then be steps of 32 uS, actually giving 33 possible pulse widths.
So we send 2 control bits and 3 data bits.
When the control bits are 00, the data bits are bits 0, 1 and 2.
When the control bits are 01, the data bits are bits 3, 4 and 5.
When the control bits are 10, the data bits are bits 6, 7 and 8.
When the control bits are 11, the data bits are bits 9, 10 and 11.
The control bits provide the clocking information as well as which data bits are in the pulse.
Get this working, then there would only be some small changes needed to see if we can get more bits in each pulse.
Mike.
So we send 2 control bits and 3 data bits.
When the control bits are 00, the data bits are bits 0, 1 and 2.
When the control bits are 01, the data bits are bits 3, 4 and 5.
When the control bits are 10, the data bits are bits 6, 7 and 8.
When the control bits are 11, the data bits are bits 9, 10 and 11.
The control bits provide the clocking information as well as which data bits are in the pulse.
Get this working, then there would only be some small changes needed to see if we can get more bits in each pulse.
Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
The difficult we do immediately,
The impossible takes a little longer!
Re: Up-Link for ER9X [Magi(C)] a vision...
There is a theoretical problem! The "PWM" conversion speed. How fast (sharp) can be switched to the PWM timer? The timer MUST be prepared to hold for a while to be valid. Time to be the correct interpretation and there must also indicate the end of the half byte (end signal)!
Start command + half byte + End command.
Command/half byte = minimum X ms (exp. If 10 read × PWM line = constans, then valid read (command/half byte = PWM time)).
Start command + half byte + End command.
Command/half byte = minimum X ms (exp. If 10 read × PWM line = constans, then valid read (command/half byte = PWM time)).
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
As per the above there is no more start/end command, the sequence is encoded in the control bits (or those would be used for a higher level transaction control).
Finding how often the pulse value can be changed and keep a reliable transmission will have to be determined by testing.
Finding how often the pulse value can be changed and keep a reliable transmission will have to be determined by testing.
Re: Up-Link for ER9X [Magi(C)] a vision...
Ok, control bit = shift bit.
Now it can be tested from the outside?
It is possible to traner input connected to a PWM generator (eg PIC) and measured at the receiver / decode?
Measurements and experiments that would be great!
You do not need to modify the Er9X.
Now it can be tested from the outside?
It is possible to traner input connected to a PWM generator (eg PIC) and measured at the receiver / decode?
Measurements and experiments that would be great!
You do not need to modify the Er9X.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
From an external device can be developed, and to which many switch is connected to the radio's trainer port. The radio only gives the PWM signal on (eg. Mixes) 7. CH and the receiver bound of decoder operating the on-board circuitry.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
The decoder program should be put into a digital filter.
It is practically not take into account the packet took until 3 ×, 4 ×, 5 ×, etc.. would one after another continuously without failure the same commands.
If of the packages many times incorrect, the program will automatically could increase the value of the filter. This slow down, but the communication can be stable.
It is practically not take into account the packet took until 3 ×, 4 ×, 5 ×, etc.. would one after another continuously without failure the same commands.
If of the packages many times incorrect, the program will automatically could increase the value of the filter. This slow down, but the communication can be stable.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
Kilrah, we know you want it only on taranis.. But then most of the people couldn't have some fun?? ;
Guys what a brilliant idea.. Now could someone please use an atmega as well?? I'm allergic to pics and also everybody already has a usbasp programmer
João
Guys what a brilliant idea.. Now could someone please use an atmega as well?? I'm allergic to pics and also everybody already has a usbasp programmer
João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9
Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9
Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
Re: Up-Link for ER9X [Magi(C)] a vision...
I'll do it from the PIC, I know, but you could use AVR too!
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
ha ha, no offense meant
João
João
My er9x/Ersky9x/eepskye Video Tutorials
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9
Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
https://www.youtube.com/playlist?list=PL5uJhoD7sAKidZmkhMpYpp_qcuIqJXhb9
Donate to Er9x/Ersky9x:
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=YHX43JR3J7XGW
Re: Up-Link for ER9X [Magi(C)] a vision...
I know!
But I really just can program the PIC!
But I really just can program the PIC!
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
Now that I think about it more, it's no different from a simple analog transmission, (elsewhere discussed the use of many gradually switch, it is also the same)!
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
If you reject (don't output) when changes occurThis is not 10 "channels" but 10 "intervals" or "combinations" of which you can extract up to 4 independent on/off channels.
I think you'll find that you will be able to get more than 4, someone build some hardware and lets see!
My point exactly.Now that I think about it more, it's no different from a simple analog transmission
“A good politician is quite as unthinkable as an honest banker”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
Re: Up-Link for ER9X [Magi(C)] a vision...
You might complicate things! Why the shift register?
Normally there are 33 different states, you may be responsible for 11 switch.
Normally there are 33 different states, you may be responsible for 11 switch.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
Hopppsss!
I i have such a device!
Bat this is only 8 ch.
See:
http://rc-miskolc.emiter.hu/rc-miskolc/ ... Itemid=120
Funcions:
http://file.emiter.hu/Modellezes/RCS1/RCS1_Manual.pdf
He should better support (more options) only on the transmitter side.
I i have such a device!
Bat this is only 8 ch.
See:
http://rc-miskolc.emiter.hu/rc-miskolc/ ... Itemid=120
Funcions:
http://file.emiter.hu/Modellezes/RCS1/RCS1_Manual.pdf
He should better support (more options) only on the transmitter side.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
See demo:
[BBvideo 425,350]http://www.youtube.com/watch?v=y7p5ZG4y ... e=youtu.be[/BBvideo]
[BBvideo 425,350]http://www.youtube.com/watch?v=y7p5ZG4y ... e=youtu.be[/BBvideo]
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
What's really required is the ability to switch them on and off independently of each other.
I would advocate sending a pulse of the length required for one function followed by a full length 2ms pulse to lock that channel on or a 1 ms off pulse to turn it off.
I would advocate sending a pulse of the length required for one function followed by a full length 2ms pulse to lock that channel on or a 1 ms off pulse to turn it off.
“A good politician is quite as unthinkable as an honest banker”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
They used to say "if you don’t want to work at McDonald’s, go to college." Now they say "if you want to work at McDonald’s, go to college.”
Re: Up-Link for ER9X [Magi(C)] a vision...
Now those currently in the program (this is not yet been written).
I can easily change to binary and so each output is independently switched on and off.
I can easily change to binary and so each output is independently switched on and off.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
Dear Mike!
Did a great job changes would be made at the ER9X, which would allow a smooth reception PWM (1ms - 2ms) signal in the traner port and this could be taken into the mixes (and anything to do with it)?
This would provide an opportunity to expand external PWM devices (not to get to produce the composite PPM signal).
For example: a servo tester.
Did a great job changes would be made at the ER9X, which would allow a smooth reception PWM (1ms - 2ms) signal in the traner port and this could be taken into the mixes (and anything to do with it)?
This would provide an opportunity to expand external PWM devices (not to get to produce the composite PPM signal).
For example: a servo tester.
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
Re: Up-Link for ER9X [Magi(C)] a vision...
hmmm....
It is the trainer port could be capable of receiving serial data (although this is more programming, memory and CPU time)....
It is the trainer port could be capable of receiving serial data (although this is more programming, memory and CPU time)....
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
- MikeB
- 9x Developer
- Posts: 17990
- Joined: Tue Dec 27, 2011 1:24 pm
- Country: -
- Location: Poole, Dorset, UK
Re: Up-Link for ER9X [Magi(C)] a vision...
The trainer input pulses are measured, by hardware, to an accuracy of 0.5 uS.HC1969 wrote:Did a great job changes would be made at the ER9X, which would allow a smooth reception PWM (1ms - 2ms) signal in the traner port and this could be taken into the mixes (and anything to do with it)?
You can use the PPMx as a source to any mix, this is the corresponding trainer input pulse.
Serial data would need a lot more processing and code. This may be possible if you have a '128 or '2561, but the standard '64 may not have the flash space.
Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
The difficult we do immediately,
The impossible takes a little longer!
Re: Up-Link for ER9X [Magi(C)] a vision...
The current state of the trainer port capable of receiving ordinary PWM signal?
For example, a servo testers?
For example, a servo testers?
http://rc.emiter.hu/ (MegaSound 9X, GCL-2, FrSky-RSSI-DAC, etc.) Keress fel!
- MikeB
- 9x Developer
- Posts: 17990
- Joined: Tue Dec 27, 2011 1:24 pm
- Country: -
- Location: Poole, Dorset, UK
Re: Up-Link for ER9X [Magi(C)] a vision...
It expects a composite PPM, so needs a sync pulse as well as a channel pulse.
Mike.
Mike.
erskyTx/er9x developer
The difficult we do immediately,
The impossible takes a little longer!
The difficult we do immediately,
The impossible takes a little longer!