Remote control system
Moderator: Benj
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Remote control system
HI all
Remote control system
Receiver type FS-R9B Have tried all weekend to try to read the signal flowcode V7, but without success
Is there anyone here who will be assisting with reading signal into the flowcode V7.
Create a small program code for Flowcode V7
Info user:
Arduino Mega 2560 R3
Remote control system
Receiver type FS-R9B Have tried all weekend to try to read the signal flowcode V7, but without success
Is there anyone here who will be assisting with reading signal into the flowcode V7.
Create a small program code for Flowcode V7
Info user:
Arduino Mega 2560 R3
Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hi Monie,
I might do something like this.
Wait for signal to go high. Start timer counting. Wait for signal to go low. Stop Timer Counting. Record timer count value to collect the length of pulse.
If you post what you have so far then we may be able to help point you in the right direction.
I might do something like this.
Wait for signal to go high. Start timer counting. Wait for signal to go low. Stop Timer Counting. Record timer count value to collect the length of pulse.
If you post what you have so far then we may be able to help point you in the right direction.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
Thank Benj
Can not read signal in Flow Code V7...
The Arduino Mega 2560 R3 works following code.
Look here!
Can not read signal in Flow Code V7...
The Arduino Mega 2560 R3 works following code.
Look here!
Code: Select all
byte CH1 = 10; //Bytes raw data
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x20, 20, 4);
float Channel1; // CutterSpeed
void setup() {
// put your setup code here, to run once:
pinMode(CH1, INPUT);
Serial.begin(9600);
lcd.begin(20, 4);
lcd.init();
lcd.backlight(); // backlight on
}
void loop() {
Channel1 = pulseIn(CH1, HIGH);
Channel1 = map(Channel1, 1450, 1950, 0, 255); //Laver inputet om til 0 - 255 Bytes
Serial.println(Channel1);
lcd.setCursor(0, 0);
lcd.print("Mower Cutter...!");// Projekt
lcd.setCursor(0, 1);
lcd.print("CutterSpeed: ");// Channel 1
lcd.print(Channel1);
}Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hello Monie,
I've not tested it but hopefully this should work and includes a Flowchart version of the Arduino Map function.
I've not tested it but hopefully this should work and includes a Flowchart version of the Arduino Map function.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
Hi Benj
Thank you very much for your codes.
By simulation codes think work.
But in practice the codes not works!
User:
Mega 2560 R3
I2C
I have attached the codes to use the devices.
Look here!
Thank you very much for your codes.
By simulation codes think work.
But in practice the codes not works!
User:
Mega 2560 R3
I2C
I have attached the codes to use the devices.
Look here!
Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hi Monie,
By "not works" what are you getting on the hardware? always 0, always 255?
Maybe print out the number before and after the map to make sure it is not the map macro at fault.
Not getting anything at all? Then check the pulse is correctly going into pin RA0 otherwise you will get stuck in the while loops.
By "not works" what are you getting on the hardware? always 0, always 255?
Maybe print out the number before and after the map to make sure it is not the map macro at fault.
Not getting anything at all? Then check the pulse is correctly going into pin RA0 otherwise you will get stuck in the while loops.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
HI Benj
In display getting on the hardware? always 0, always 255?
Gets no signal in practice value in display
In display getting on the hardware? always 0, always 255?
Gets no signal in practice value in display
Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hi Monie,
Really not sure what you mean by the last message. I take it the display shows nothing.
Really not sure what you mean by the last message. I take it the display shows nothing.
Note Pin RA0 is not the same as Arduino Analog0 which is actually RF0 on the Arduino Mega 2560.Not getting anything at all? Then check the pulse is correctly going into pin RA0 otherwise you will get stuck in the while loops.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
HI Benj
RA0 OK - from oscilloscope can seen a signal when the remote control system is activated!
The display shows nothing.
RA0 OK - from oscilloscope can seen a signal when the remote control system is activated!
The display shows nothing.
Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hi Monie,
Have you tried a simple program to print something out to the display. Is the display's address property correct?
Have you tried a simple program to print something out to the display. Is the display's address property correct?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
HI Benj
You must excuse me, that I did not answer you now!
I have been sick.
I will now drave your suggestion.
Coming back with the answer;-)
You must excuse me, that I did not answer you now!
I have been sick.
I will now drave your suggestion.
Coming back with the answer;-)
Best Regard
Monie
Monie
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
Hi Benj
Have test Remote control system.
With signal in the A0. I see not result in display.
User Mega 2560 and I2C display.
And use flow code v7
Has attach my version:
Have test Remote control system.
With signal in the A0. I see not result in display.
User Mega 2560 and I2C display.
And use flow code v7
Has attach my version:
Best Regard
Monie
Monie
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
Hi Benj
Very fine codes you have created.
The Arduino Mega 2560 works by reading from A0.
Attached se here![/code]
And here's version of Flowcode V7 which does not work by reading from A0. Where does it go wrong?
Very fine codes you have created.
The Arduino Mega 2560 works by reading from A0.
Attached se here!
Code: Select all
[code]byte CH2 = A0; //Bytes raw data
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x20, 20, 4);
float Channel2; // CutterSpeed
void setup() {
// put your setup code here, to run once:
pinMode(CH2, INPUT);
Serial.begin(9600);
lcd.begin(20, 4);
lcd.init();
lcd.backlight(); // backlight on
}
void loop() {
Channel2 = pulseIn(CH2, HIGH);
Channel2 = map(Channel2, 970, 1970, 0, 255); //Laver inputet om til 0 - 255 Bytes
Serial.println(Channel2);
lcd.setCursor(0, 0);
lcd.print("CH2 Speed: ");// Projekt
lcd.print(Channel2);
}And here's version of Flowcode V7 which does not work by reading from A0. Where does it go wrong?
Best Regard
Monie
Monie
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Remote control system
Hi Monie,
First of all is the display working at all? Can you display anything on it? e.g. a fixed string.
If the display is working then is there a point in the program where the code stops running and hangs? If so then where does this happen, use the display to test.
If the display is not working then do you have the I2C address correct? Maybe also worth doing a 1 second flash test to confirm the configuration settings are right etc.
First of all is the display working at all? Can you display anything on it? e.g. a fixed string.
If the display is working then is there a point in the program where the code stops running and hangs? If so then where does this happen, use the display to test.
If the display is not working then do you have the I2C address correct? Maybe also worth doing a 1 second flash test to confirm the configuration settings are right etc.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
Monie Jacobsen
- Posts: 484
- Joined: Mon Jul 30, 2012 3:39 pm
- Has thanked: 17 times
- Been thanked: 46 times
Re: Remote control system
HI Benj
I had failed the A0 and for Mega 2560 F0
Very sorry the failed was my...
Many thanks for you help;-)
I had failed the A0 and for Mega 2560 F0
Very sorry the failed was my...
Many thanks for you help;-)
Best Regard
Monie
Monie