• Hallo Zusammen, Aufgrund der aktuellen Situation setzten wir die Möglichkeit aus, sich mit Gmail zu registrieren. Wir bitten um Verständnis Das RCMP Team

Projekt ESP32 Arduino RC Sound und Licht Controller

FrikkieBester

Mitglied
Hello Martin,

I am trying to change the LCD pins around so I can still have my Sidelights for the wireless trailer.

I went to the Setup43_ST7735_ESP32_80x160.h file and changed from the original #define TFT_SCLK 18 to: #define TFT_SCLK 22 //changed from Sidelights pin 18 to Cabin pin 22

When I load the code, the display still works with the wire connected to Pin 18, when I move the wire to Pin 22, the display stops working. Is there anywhere else I need to change the pin allocation?

I have been using Arduino IDE, so I wanted to try VSCode again, but now get compile errors.

ompiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\bitswap.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\colorpalettes.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\colorutils.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\hsv2rgb.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\lib8tion.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\noise.cpp.o
Compiling .pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\platforms.cpp.o
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\FastLED.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\bitswap.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\colorpalettes.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\colorutils.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\hsv2rgb.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\lib8tion.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\noise.cpp.o] Error 127
unknown OSError exception code 22 - 'C:\Windows\System32\cmd.exe': Invalid argument
*** [.pio\build\esp32dev\libec8\FastLED@src-c631485613052522e49521b814fa7687\platforms.cpp.o] Error 127
=================================== [FAILED] Took 9.10 seconds ==========

Thank you,

Frikkie
 
Zuletzt bearbeitet:

Onkel_Tom

Mitglied
Meine neueste Schöpfung
Was mir noch nicht ganz gefällt ist der Motorsound. Liegt aber auch zum Großteil an der Hardware.
Ich musste bei den Einstellungen den Wert für max Geschwindigkeit auf 250 ändern, sonst hätte ich einen schneckenschnellen Crawler. Liegt wohl an der Kombination des MN90 Chassis und den Portalachsen, die ja auch noch einmal untersetzen. Evtl finde ich noch einen passenden Motor mit etwas höherer Drehzahl.

Virtuelles 3 Gang Getriebe, im 3. Gang passt der Sound zum Fahrbild, da drunter kommt das Motorengeräusch "verspätet". Heißt der Mog fährt schon und Motorgeräusch ist gerade eben über Standgas.
 
Is there anywhere else I need to change the pin allocation?
Hi Frikkie, it depends on which display is selected in
Bildschirmfoto 2022-02-03 um 19.49.36.png
The LCD pins are then selected here:
Bildschirmfoto 2022-02-03 um 19.50.48.png
In general, I'm recommending to use VS Code. It is way easier to make your adjustments this way. The display is adjusted in platform.ini:
Bildschirmfoto 2022-02-03 um 19.53.28.png

Unfortunately I don't really know what your error message means. Did you update your windows recently?
 

Onkel_Tom

Mitglied
Ist mir soweit klar. Nur bei 500 fährt der Unimog wesentlich langsamer im Vergleich zum Direktanschluss am Empfänger. Bei 250 hab ich ziemlich genau die gleiche Geschwindigkeit.
Wie gesagt ich werde den Getriebemotor selbst noch tauschen. Einen zum Vergleich hab ich hier noch liegen.
Leider sind bei den 370er Getriebemotoren die Getriebeübersetzungen meist nicht angegeben.
 

FrikkieBester

Mitglied
Unfortunately I don't really know what your error message means. Did you update your windows recently?
Thank you, I will try my wife's laptop the weekend. Mine is a work laptop with continues updates and security upgrades. Everything worked in the past, now if I load V8.8 I cannot get the wireless trailer to work at all, tried V8.5 again that I previously used, same result. Must be a software update on my laptop that is causing it, as nothing else has changed. Same hardware and code.

Just a question, if I change the pin selection for the Dash, should this section in the main code also change? I have tried to "change" it below to show what I mean. I want to use pin 22 cabLight instead of pin 18 sideLight, to ensure that I still have the sideLight working on the trailer.

1643950332623.png
 

Nolethai

Mitglied
Hallo Emanuel,
ich habe die FSi6-S, ist so ähnlich wie die FSi6-X.
Danke für deine Erkärung, den Servo habe ich an Ch4 angeschlossen. Nur mit dem Schalter SWA komme ich nicht zurecht. Was muß ich da einstellen bzw. im Code ändern oder nicht? Mit welchem Kanal wird der SWA Sendermäßig verbunden oder wird er nicht verbunden? Ich stehe da vor einem großen Berg und brauche Hilfe um über den Berg zu kommen.
Viele Grüße
Norbert
 

Onkel_Tom

Mitglied
Wenn man schon ein virtuelles Getriebe "einbaut", dann sollte man auch die Gänge mal durchschalten...
Ja, im Modus "virtuelles Schaltgetriebe" ist die Höchstgeschwindigkeit begrenzt, je nachdem in welchem "Gang" man sich befindet. Im 3. Gang läuft der Motor auf voller Leistung, je nachdem was man bei "escPulseSpan" eingestellt hat. Das Anfahrverhalten kannst du mit "escTakeoffPunch" einstellen. Höherer Wert = früheres Losfahren.

Frikkie, change the PIN numbers here:
Bildschirmfoto 2022-02-05 um 07.32.52.png
 
Zuletzt bearbeitet:

FrikkieBester

Mitglied
Thank you, I will try my wife's laptop the weekend. Mine is a work laptop with continues updates and security upgrades. Everything worked in the past, now if I load V8.8 I cannot get the wireless trailer to work at all, tried V8.5 again that I previously used, same result. Must be a software update on my laptop that is causing it, as nothing else has changed. Same hardware and code.
I have now successfully loaded VSCode onto my wife's laptop, everything compiles and uploads...but I cannot get the wireless trailer card to work. I got it working so easily the last time on both cards for the linked cattle trailer.

I load the trailer code, get the MAC address, put it in the trailer header file and the // is removed, upload and all that happens on the trailer card is the indicators flash...

Have downloaded a new copy of V8.8 from GITHUB and did everything again...still no luck. Have tried from Arduino IDE also, exact same result...anyone else have similar problem...or advise....
 

B33lz3bub

Mitglied
Hallo Norbert!
Nur mit dem Schalter SWA komme ich nicht zurecht. Was muß ich da einstellen bzw. im Code ändern oder nicht?
Damit hatte ich zu Beginn auch meine Probleme ;).
Ich habe mir kurz die Anleitung für deine Fernbedienung durchgeschaut und du kannst im Menüpunkt Rate/Exp.switch den Schalter SWA zuweisen. Siehe auch in diesem Video auf youtube: Set up Rate/Expo.switch.
Danach die Rate bei CH2 und CH4 nach Anleitung von Martin bei "Normal" auf 100 und bei "Sport" auf 75 einstellen.

Das wars! Dann kannst du zwischen den unterschiedlichen Funktionen hin und her schalten.

LG Emanuel
 

Nolethai

Mitglied
Hallo Emanuel,
danke für deine Erklärung. Ich habe jetzt den Sender laut dem Video eingestellt. Im code für den ESP32 habe ich in adjustment.Servo die für den Actros ausgewählt.
Bis jetzt passiert nichts. Der Servo für die Entriegelung der Sattelplatte zeigt keine Funktion.
Was mache ich falsch? Im Code brauche ich doch sonst nicht ändern, oder?
Viele Grüße
Norbert
 
and all that happens on the trailer card is the indicators flash...
so the indicators are working normally? Or is the communication with the tractor not working at all?

Im Code brauche ich doch sonst nicht ändern, oder?
du musst beachten, dass die markierte Option nicht aktiv sein darf. Diese ist nur für meine "Micro RC" Fernbedienung gedacht. Bei dir also // hinzufügen. Dann muss es über CH4 Stick lange nach rechts funktionieren, abhängig von der Stellung von SWA.
Bildschirmfoto 2022-02-06 um 08.08.29.png
 

FrikkieBester

Mitglied
so the indicators are working normally? Or is the communication with the tractor not working at all?

so the indicators are working normally? Or is the communication with the tractor not working at all?
No lights where working as it should on the trailer...I could hear on the sound through the speakers that it was connecting...but nothing was working. I then took the wireless unit from my front cattle trailer, put that MAC address into the code and everything worked.

My cattle unit was still on V0.2 of the trailer SW...I started to compare the new version with the previous...found MY mistake!

#define FIFTH_WHEEL_DETECTION_PIN 32 // This NO switch is closed, if the trailer is coupled to the 5th wheel. Between Pin 32 and GND

I had no switch connected :eek:...so it could/should not work!!!!!! Very sorry...another ID 10 T (idiot) error on my side...so sorry.

I am still using Arduino IDE on my laptop (due to some security upgrades on the MacAfee anti virus I cannot get VSCode to upload)

To get the sideLights to work I tried changing the pins like you suggested, but still could not get the sideLights to work on the trailer together with the dashboard. I changed the code below and everything is working...

1644231590806.png


Thank you again for all your support!

Frikkie
 

Nolethai

Mitglied
Hallo Martin, Hallo Emanuel,
Ihr habt mir über einen großen Berg geholfen. Mit den richtigen Einstellungen funktioniert das Ver- und Entriegeln der Sattelplatte.
DANKE!
Da die fehlenden Widerstände aus China für das neue PCB von Martin noch länger auf sich warten lassen (die Chinesen haben gerade ausgiebig ihr Neues Jahr gefeiert), habe ich mich entschlossen das alte Board erstmal wieder zu nutzen und meinen Actros wieder zusammen zu bauen. Denn: ich will fahren und sehen und hören.
Viele Grüße
Norbert
 
I had no switch connected :eek:...so it could/should not work!!!!!!
Hi Frikkie, good to hear you figured it out. I should have mentioned, that I added a switch to the new code version...
Ihr habt mir über einen großen Berg geholfen.
Hallo Norbert, schön, dass es nun funktioniert! Wann zeigst du uns Bilder von deinem Truck? Ev. im LWK Thread als Baubericht?
 
Top Bottom